]> git.ipfire.org Git - pakfire.git/commitdiff
Remove libpakfire as a shared object
authorMichael Tremer <michael.tremer@ipfire.org>
Fri, 3 Jan 2025 06:38:31 +0000 (06:38 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Fri, 3 Jan 2025 06:41:38 +0000 (06:41 +0000)
There seems to very little point in having a shared library with a
stable API. Most stuff is opaque anyways and there won't be any
third-party programs that can take advantage of this. Therefore we can
save ourselves the extra work that it takes to make this all exported
and stable for now.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
121 files changed:
Makefile.am
debian/control
debian/libpakfire-dev.install [deleted file]
debian/libpakfire0.install [deleted file]
debian/not-installed
src/libpakfire/include/pakfire/private.h [deleted file]
src/libpakfire/libpakfire.sym [deleted file]
src/pakfire/arch.c [moved from src/libpakfire/arch.c with 96% similarity]
src/pakfire/arch.h [moved from src/libpakfire/include/pakfire/arch.h with 100% similarity]
src/pakfire/archive.c [moved from src/libpakfire/archive.c with 97% similarity]
src/pakfire/archive.h [moved from src/libpakfire/include/pakfire/archive.h with 100% similarity]
src/pakfire/base64.c [moved from src/libpakfire/base64.c with 100% similarity]
src/pakfire/base64.h [moved from src/libpakfire/include/pakfire/base64.h with 100% similarity]
src/pakfire/build.c [moved from src/libpakfire/build.c with 98% similarity]
src/pakfire/build.h [moved from src/libpakfire/include/pakfire/build.h with 100% similarity]
src/pakfire/buildservice.c [moved from src/libpakfire/buildservice.c with 94% similarity]
src/pakfire/buildservice.h [moved from src/libpakfire/include/pakfire/buildservice.h with 100% similarity]
src/pakfire/cgroup.c [moved from src/libpakfire/cgroup.c with 100% similarity]
src/pakfire/cgroup.h [moved from src/libpakfire/include/pakfire/cgroup.h with 100% similarity]
src/pakfire/compress.c [moved from src/libpakfire/compress.c with 100% similarity]
src/pakfire/compress.h [moved from src/libpakfire/include/pakfire/compress.h with 100% similarity]
src/pakfire/config.c [moved from src/libpakfire/config.c with 100% similarity]
src/pakfire/config.h [moved from src/libpakfire/include/pakfire/config.h with 100% similarity]
src/pakfire/constants.h [moved from src/libpakfire/include/pakfire/constants.h with 100% similarity]
src/pakfire/ctx.c [moved from src/libpakfire/ctx.c with 89% similarity]
src/pakfire/ctx.h [moved from src/libpakfire/include/pakfire/ctx.h with 100% similarity]
src/pakfire/daemon.c [moved from src/libpakfire/daemon.c with 100% similarity]
src/pakfire/daemon.h [moved from src/libpakfire/include/pakfire/daemon.h with 100% similarity]
src/pakfire/db.c [moved from src/libpakfire/db.c with 100% similarity]
src/pakfire/db.h [moved from src/libpakfire/include/pakfire/db.h with 100% similarity]
src/pakfire/deps.c [moved from src/libpakfire/deps.c with 98% similarity]
src/pakfire/deps.h [moved from src/libpakfire/include/pakfire/deps.h with 100% similarity]
src/pakfire/digest.c [moved from src/libpakfire/digest.c with 98% similarity]
src/pakfire/digest.h [moved from src/libpakfire/include/pakfire/digest.h with 100% similarity]
src/pakfire/dist.c [moved from src/libpakfire/dist.c with 99% similarity]
src/pakfire/dist.h [moved from src/libpakfire/include/pakfire/dist.h with 100% similarity]
src/pakfire/elf.c [moved from src/libpakfire/elf.c with 100% similarity]
src/pakfire/elf.h [moved from src/libpakfire/include/pakfire/elf.h with 100% similarity]
src/pakfire/env.c [moved from src/libpakfire/env.c with 100% similarity]
src/pakfire/env.h [moved from src/libpakfire/include/pakfire/env.h with 100% similarity]
src/pakfire/fhs.c [moved from src/libpakfire/fhs.c with 100% similarity]
src/pakfire/fhs.h [moved from src/libpakfire/include/pakfire/fhs.h with 100% similarity]
src/pakfire/file.c [moved from src/libpakfire/file.c with 93% similarity]
src/pakfire/file.h [moved from src/libpakfire/include/pakfire/file.h with 100% similarity]
src/pakfire/filelist.c [moved from src/libpakfire/filelist.c with 95% similarity]
src/pakfire/filelist.h [moved from src/libpakfire/include/pakfire/filelist.h with 100% similarity]
src/pakfire/hex.c [moved from src/libpakfire/hex.c with 100% similarity]
src/pakfire/hex.h [moved from src/libpakfire/include/pakfire/hex.h with 100% similarity]
src/pakfire/httpclient.c [moved from src/libpakfire/httpclient.c with 100% similarity]
src/pakfire/httpclient.h [moved from src/libpakfire/include/pakfire/httpclient.h with 100% similarity]
src/pakfire/i18n.h [moved from src/libpakfire/include/pakfire/i18n.h with 100% similarity]
src/pakfire/jail.c [moved from src/libpakfire/jail.c with 100% similarity]
src/pakfire/jail.h [moved from src/libpakfire/include/pakfire/jail.h with 100% similarity]
src/pakfire/job.c [moved from src/libpakfire/job.c with 100% similarity]
src/pakfire/job.h [moved from src/libpakfire/include/pakfire/job.h with 100% similarity]
src/pakfire/key.c [moved from src/libpakfire/key.c with 96% similarity]
src/pakfire/key.h [moved from src/libpakfire/include/pakfire/key.h with 100% similarity]
src/pakfire/linter-file.c [moved from src/libpakfire/linter-file.c with 100% similarity]
src/pakfire/linter-file.h [moved from src/libpakfire/include/pakfire/linter-file.h with 100% similarity]
src/pakfire/linter.c [moved from src/libpakfire/linter.c with 100% similarity]
src/pakfire/linter.h [moved from src/libpakfire/include/pakfire/linter.h with 100% similarity]
src/pakfire/log_buffer.c [moved from src/libpakfire/log_buffer.c with 100% similarity]
src/pakfire/log_buffer.h [moved from src/libpakfire/include/pakfire/log_buffer.h with 100% similarity]
src/pakfire/log_stream.c [moved from src/libpakfire/log_stream.c with 100% similarity]
src/pakfire/log_stream.h [moved from src/libpakfire/include/pakfire/log_stream.h with 100% similarity]
src/pakfire/logging.c [moved from src/libpakfire/logging.c with 92% similarity]
src/pakfire/logging.h [moved from src/libpakfire/include/pakfire/logging.h with 100% similarity]
src/pakfire/mirror.c [moved from src/libpakfire/mirror.c with 100% similarity]
src/pakfire/mirror.h [moved from src/libpakfire/include/pakfire/mirror.h with 100% similarity]
src/pakfire/mirrorlist.c [moved from src/libpakfire/mirrorlist.c with 100% similarity]
src/pakfire/mirrorlist.h [moved from src/libpakfire/include/pakfire/mirrorlist.h with 100% similarity]
src/pakfire/mount.c [moved from src/libpakfire/mount.c with 100% similarity]
src/pakfire/mount.h [moved from src/libpakfire/include/pakfire/mount.h with 100% similarity]
src/pakfire/os.c [moved from src/libpakfire/os.c with 100% similarity]
src/pakfire/os.h [moved from src/libpakfire/include/pakfire/os.h with 100% similarity]
src/pakfire/package.c [moved from src/libpakfire/package.c with 95% similarity]
src/pakfire/package.h [moved from src/libpakfire/include/pakfire/package.h with 100% similarity]
src/pakfire/packagelist.c [moved from src/libpakfire/packagelist.c with 88% similarity]
src/pakfire/packagelist.h [moved from src/libpakfire/include/pakfire/packagelist.h with 100% similarity]
src/pakfire/packager.c [moved from src/libpakfire/packager.c with 100% similarity]
src/pakfire/packager.h [moved from src/libpakfire/include/pakfire/packager.h with 100% similarity]
src/pakfire/pakfire.c [moved from src/libpakfire/pakfire.c with 96% similarity]
src/pakfire/pakfire.h [moved from src/libpakfire/include/pakfire/pakfire.h with 100% similarity]
src/pakfire/parse.c [moved from src/libpakfire/parse.c with 100% similarity]
src/pakfire/parse.h [moved from src/libpakfire/include/pakfire/parse.h with 100% similarity]
src/pakfire/parser.c [moved from src/libpakfire/parser.c with 100% similarity]
src/pakfire/parser.h [moved from src/libpakfire/include/pakfire/parser.h with 100% similarity]
src/pakfire/parser/.gitignore [moved from src/libpakfire/parser/.gitignore with 100% similarity]
src/pakfire/parser/grammar.y [moved from src/libpakfire/parser/grammar.y with 100% similarity]
src/pakfire/parser/scanner.l [moved from src/libpakfire/parser/scanner.l with 100% similarity]
src/pakfire/path.c [moved from src/libpakfire/path.c with 100% similarity]
src/pakfire/path.h [moved from src/libpakfire/include/pakfire/path.h with 100% similarity]
src/pakfire/problem.c [moved from src/libpakfire/problem.c with 95% similarity]
src/pakfire/problem.h [moved from src/libpakfire/include/pakfire/problem.h with 100% similarity]
src/pakfire/progress.c [moved from src/libpakfire/progress.c with 87% similarity]
src/pakfire/progress.h [moved from src/libpakfire/include/pakfire/progress.h with 100% similarity]
src/pakfire/pty.c [moved from src/libpakfire/pty.c with 100% similarity]
src/pakfire/pty.h [moved from src/libpakfire/include/pakfire/pty.h with 100% similarity]
src/pakfire/pwd.c [moved from src/libpakfire/pwd.c with 100% similarity]
src/pakfire/pwd.h [moved from src/libpakfire/include/pakfire/pwd.h with 100% similarity]
src/pakfire/repo.c [moved from src/libpakfire/repo.c with 95% similarity]
src/pakfire/repo.h [moved from src/libpakfire/include/pakfire/repo.h with 100% similarity]
src/pakfire/repolist.c [moved from src/libpakfire/repolist.c with 82% similarity]
src/pakfire/repolist.h [moved from src/libpakfire/include/pakfire/repolist.h with 100% similarity]
src/pakfire/scriptlet.c [moved from src/libpakfire/scriptlet.c with 100% similarity]
src/pakfire/scriptlet.h [moved from src/libpakfire/include/pakfire/scriptlet.h with 100% similarity]
src/pakfire/snapshot.c [moved from src/libpakfire/snapshot.c with 100% similarity]
src/pakfire/snapshot.h [moved from src/libpakfire/include/pakfire/snapshot.h with 100% similarity]
src/pakfire/solution.c [moved from src/libpakfire/solution.c with 95% similarity]
src/pakfire/solution.h [moved from src/libpakfire/include/pakfire/solution.h with 100% similarity]
src/pakfire/string.c [moved from src/libpakfire/string.c with 100% similarity]
src/pakfire/string.h [moved from src/libpakfire/include/pakfire/string.h with 100% similarity]
src/pakfire/stripper.c [moved from src/libpakfire/stripper.c with 100% similarity]
src/pakfire/stripper.h [moved from src/libpakfire/include/pakfire/stripper.h with 100% similarity]
src/pakfire/syscalls.h [moved from src/libpakfire/include/pakfire/syscalls.h with 100% similarity]
src/pakfire/transaction.c [moved from src/libpakfire/transaction.c with 97% similarity]
src/pakfire/transaction.h [moved from src/libpakfire/include/pakfire/transaction.h with 100% similarity]
src/pakfire/util.c [moved from src/libpakfire/util.c with 100% similarity]
src/pakfire/util.h [moved from src/libpakfire/include/pakfire/util.h with 100% similarity]
src/pakfire/xfer.c [moved from src/libpakfire/xfer.c with 100% similarity]
src/pakfire/xfer.h [moved from src/libpakfire/include/pakfire/xfer.h with 100% similarity]

index 95682a363957a41e6a8d6d721865f7c05e4ff7ff..d8843829ad7caa9b5f8f5fc538b7f4a24454ae50 100644 (file)
@@ -66,9 +66,6 @@ AM_YFLAGS = \
        -d \
        -Wno-yacc
 
-PAKFIRE_CPPFLAGS = -I$(top_srcdir)/src/libpakfire/include
-PAKFIRE_LIBS     = libpakfire.la
-
 bin_PROGRAMS =
 check_PROGRAMS =
 lib_LTLIBRARIES =
@@ -133,7 +130,7 @@ pakfire_la_SOURCES = \
 
 pakfire_la_CPPFLAGS = \
        -include $(top_builddir)/config.h \
-       $(PAKFIRE_CPPFLAGS)
+       -I$(top_srcdir)/src
 
 pakfire_la_CFLAGS = \
        $(AM_CFLAGS) \
@@ -150,22 +147,22 @@ pakfire_la_LDFLAGS = \
 
 pakfire_la_LIBADD = \
        $(PYTHON_DEVEL_LIBS) \
-       $(PAKFIRE_LIBS)
+       libpakfire.la
 
 # ------------------------------------------------------------------------------
 
 CLEANFILES += \
-       src/libpakfire/parser/grammar.c \
-       src/libpakfire/parser/grammar.h \
-       src/libpakfire/parser/scanner.c
+       src/pakfire/parser/grammar.c \
+       src/pakfire/parser/grammar.h \
+       src/pakfire/parser/scanner.c
 
 noinst_LTLIBRARIES += \
        libpakfire-parser.la
 
 libpakfire_parser_la_SOURCES = \
-       src/libpakfire/parser/grammar.h \
-       src/libpakfire/parser/grammar.y \
-       src/libpakfire/parser/scanner.l
+       src/pakfire/parser/grammar.h \
+       src/pakfire/parser/grammar.y \
+       src/pakfire/parser/scanner.l
 
 libpakfire_parser_la_CFLAGS = \
        $(AM_CFLAGS) \
@@ -174,131 +171,127 @@ libpakfire_parser_la_CFLAGS = \
 
 libpakfire_parser_la_CPPFLAGS = \
        $(AM_CPPFLAGS) \
-       -I$(top_srcdir)/src/libpakfire/include \
+       -I$(top_srcdir)/src \
        -include $(top_builddir)/config.h \
        -DPAKFIRE_PRIVATE
 
 BUILT_SOURCES += \
-       src/libpakfire/parser/grammar.h
+       src/pakfire/parser/grammar.h
 
-lib_LTLIBRARIES += \
+noinst_LTLIBRARIES += \
        libpakfire.la
 
 libpakfire_la_SOURCES = \
-       src/libpakfire/arch.c \
-       src/libpakfire/archive.c \
-       src/libpakfire/base64.c \
-       src/libpakfire/build.c \
-       src/libpakfire/buildservice.c \
-       src/libpakfire/cgroup.c \
-       src/libpakfire/compress.c \
-       src/libpakfire/config.c \
-       src/libpakfire/ctx.c \
-       src/libpakfire/daemon.c \
-       src/libpakfire/db.c \
-       src/libpakfire/deps.c \
-       src/libpakfire/digest.c \
-       src/libpakfire/dist.c \
-       src/libpakfire/elf.c \
-       src/libpakfire/env.c \
-       src/libpakfire/fhs.c \
-       src/libpakfire/file.c \
-       src/libpakfire/filelist.c \
-       src/libpakfire/hex.c \
-       src/libpakfire/httpclient.c \
-       src/libpakfire/jail.c \
-       src/libpakfire/job.c \
-       src/libpakfire/key.c \
-       src/libpakfire/linter.c \
-       src/libpakfire/linter-file.c \
-       src/libpakfire/log_buffer.c \
-       src/libpakfire/log_stream.c \
-       src/libpakfire/logging.c \
-       src/libpakfire/mirror.c \
-       src/libpakfire/mirrorlist.c \
-       src/libpakfire/mount.c \
-       src/libpakfire/os.c \
-       src/libpakfire/package.c \
-       src/libpakfire/packager.c \
-       src/libpakfire/packagelist.c \
-       src/libpakfire/pakfire.c \
-       src/libpakfire/parse.c \
-       src/libpakfire/parser.c \
-       src/libpakfire/path.c \
-       src/libpakfire/problem.c \
-       src/libpakfire/progress.c \
-       src/libpakfire/pty.c \
-       src/libpakfire/pwd.c \
-       src/libpakfire/repo.c \
-       src/libpakfire/repolist.c \
-       src/libpakfire/scriptlet.c \
-       src/libpakfire/snapshot.c \
-       src/libpakfire/solution.c \
-       src/libpakfire/string.c \
-       src/libpakfire/stripper.c \
-       src/libpakfire/transaction.c \
-       src/libpakfire/util.c \
-       src/libpakfire/xfer.c
-
-pkginclude_HEADERS += \
-       src/libpakfire/include/pakfire/arch.h \
-       src/libpakfire/include/pakfire/archive.h \
-       src/libpakfire/include/pakfire/base64.h \
-       src/libpakfire/include/pakfire/build.h \
-       src/libpakfire/include/pakfire/buildservice.h \
-       src/libpakfire/include/pakfire/cgroup.h \
-       src/libpakfire/include/pakfire/compress.h \
-       src/libpakfire/include/pakfire/config.h \
-       src/libpakfire/include/pakfire/constants.h \
-       src/libpakfire/include/pakfire/ctx.h \
-       src/libpakfire/include/pakfire/daemon.h \
-       src/libpakfire/include/pakfire/db.h \
-       src/libpakfire/include/pakfire/deps.h \
-       src/libpakfire/include/pakfire/digest.h \
-       src/libpakfire/include/pakfire/dist.h \
-       src/libpakfire/include/pakfire/elf.h \
-       src/libpakfire/include/pakfire/env.h \
-       src/libpakfire/include/pakfire/fhs.h \
-       src/libpakfire/include/pakfire/file.h \
-       src/libpakfire/include/pakfire/filelist.h \
-       src/libpakfire/include/pakfire/hex.h \
-       src/libpakfire/include/pakfire/httpclient.h \
-       src/libpakfire/include/pakfire/i18n.h \
-       src/libpakfire/include/pakfire/jail.h \
-       src/libpakfire/include/pakfire/job.h \
-       src/libpakfire/include/pakfire/key.h \
-       src/libpakfire/include/pakfire/linter.h \
-       src/libpakfire/include/pakfire/linter-file.h \
-       src/libpakfire/include/pakfire/log_buffer.h \
-       src/libpakfire/include/pakfire/log_stream.h \
-       src/libpakfire/include/pakfire/logging.h \
-       src/libpakfire/include/pakfire/mirror.h \
-       src/libpakfire/include/pakfire/mirrorlist.h \
-       src/libpakfire/include/pakfire/mount.h \
-       src/libpakfire/include/pakfire/os.h \
-       src/libpakfire/include/pakfire/package.h \
-       src/libpakfire/include/pakfire/packager.h \
-       src/libpakfire/include/pakfire/packagelist.h \
-       src/libpakfire/include/pakfire/pakfire.h \
-       src/libpakfire/include/pakfire/parse.h \
-       src/libpakfire/include/pakfire/parser.h \
-       src/libpakfire/include/pakfire/path.h \
-       src/libpakfire/include/pakfire/private.h \
-       src/libpakfire/include/pakfire/problem.h \
-       src/libpakfire/include/pakfire/progress.h \
-       src/libpakfire/include/pakfire/pty.h \
-       src/libpakfire/include/pakfire/pwd.h \
-       src/libpakfire/include/pakfire/repo.h \
-       src/libpakfire/include/pakfire/repolist.h \
-       src/libpakfire/include/pakfire/scriptlet.h \
-       src/libpakfire/include/pakfire/snapshot.h \
-       src/libpakfire/include/pakfire/solution.h \
-       src/libpakfire/include/pakfire/string.h \
-       src/libpakfire/include/pakfire/stripper.h \
-       src/libpakfire/include/pakfire/syscalls.h \
-       src/libpakfire/include/pakfire/transaction.h \
-       src/libpakfire/include/pakfire/util.h \
-       src/libpakfire/include/pakfire/xfer.h
+       src/pakfire/arch.c \
+       src/pakfire/arch.h \
+       src/pakfire/archive.c \
+       src/pakfire/archive.h \
+       src/pakfire/base64.c \
+       src/pakfire/base64.h \
+       src/pakfire/build.c \
+       src/pakfire/build.h \
+       src/pakfire/buildservice.c \
+       src/pakfire/buildservice.h \
+       src/pakfire/cgroup.c \
+       src/pakfire/cgroup.h \
+       src/pakfire/compress.c \
+       src/pakfire/compress.h \
+       src/pakfire/config.c \
+       src/pakfire/config.h \
+       src/pakfire/constants.h \
+       src/pakfire/ctx.c \
+       src/pakfire/ctx.h \
+       src/pakfire/daemon.c \
+       src/pakfire/daemon.h \
+       src/pakfire/db.c \
+       src/pakfire/db.h \
+       src/pakfire/deps.c \
+       src/pakfire/deps.h \
+       src/pakfire/digest.c \
+       src/pakfire/digest.h \
+       src/pakfire/dist.c \
+       src/pakfire/dist.h \
+       src/pakfire/elf.c \
+       src/pakfire/elf.h \
+       src/pakfire/env.c \
+       src/pakfire/env.h \
+       src/pakfire/fhs.c \
+       src/pakfire/fhs.h \
+       src/pakfire/file.c \
+       src/pakfire/file.h \
+       src/pakfire/filelist.c \
+       src/pakfire/filelist.h \
+       src/pakfire/hex.c \
+       src/pakfire/hex.h \
+       src/pakfire/httpclient.c \
+       src/pakfire/httpclient.h \
+       src/pakfire/jail.c \
+       src/pakfire/jail.h \
+       src/pakfire/job.c \
+       src/pakfire/job.h \
+       src/pakfire/key.c \
+       src/pakfire/key.h \
+       src/pakfire/linter.c \
+       src/pakfire/linter.h \
+       src/pakfire/linter-file.c \
+       src/pakfire/linter-file.h \
+       src/pakfire/log_buffer.c \
+       src/pakfire/log_buffer.h \
+       src/pakfire/log_stream.c \
+       src/pakfire/log_stream.h \
+       src/pakfire/logging.c \
+       src/pakfire/logging.h \
+       src/pakfire/mirror.c \
+       src/pakfire/mirror.h \
+       src/pakfire/mirrorlist.c \
+       src/pakfire/mirrorlist.h \
+       src/pakfire/mount.c \
+       src/pakfire/mount.h \
+       src/pakfire/os.c \
+       src/pakfire/os.h \
+       src/pakfire/package.c \
+       src/pakfire/package.h \
+       src/pakfire/packager.c \
+       src/pakfire/packager.h \
+       src/pakfire/packagelist.c \
+       src/pakfire/packagelist.h \
+       src/pakfire/pakfire.c \
+       src/pakfire/pakfire.h \
+       src/pakfire/parse.c \
+       src/pakfire/parse.h \
+       src/pakfire/parser.c \
+       src/pakfire/parser.h \
+       src/pakfire/path.c \
+       src/pakfire/path.h \
+       src/pakfire/problem.c \
+       src/pakfire/problem.h \
+       src/pakfire/progress.c \
+       src/pakfire/progress.h \
+       src/pakfire/pty.c \
+       src/pakfire/pty.h \
+       src/pakfire/pwd.c \
+       src/pakfire/pwd.h \
+       src/pakfire/repo.c \
+       src/pakfire/repo.h \
+       src/pakfire/repolist.c \
+       src/pakfire/repolist.h \
+       src/pakfire/scriptlet.c \
+       src/pakfire/scriptlet.h \
+       src/pakfire/snapshot.c \
+       src/pakfire/snapshot.h \
+       src/pakfire/solution.c \
+       src/pakfire/solution.h \
+       src/pakfire/string.c \
+       src/pakfire/string.h \
+       src/pakfire/stripper.c \
+       src/pakfire/stripper.h \
+       src/pakfire/syscalls.h \
+       src/pakfire/transaction.c \
+       src/pakfire/transaction.h \
+       src/pakfire/util.c \
+       src/pakfire/util.h \
+       src/pakfire/xfer.c \
+       src/pakfire/xfer.h
 
 libpakfire_la_CFLAGS = \
        $(AM_CFLAGS) \
@@ -325,15 +318,13 @@ libpakfire_la_CFLAGS = \
 
 libpakfire_la_CPPFLAGS = \
        $(AM_CPPFLAGS) \
-       -I$(top_srcdir)/src/libpakfire/include \
+       -I$(top_srcdir)/src \
        -include $(top_builddir)/config.h \
        -DPAKFIRE_PRIVATE
 
 libpakfire_la_LDFLAGS = \
        $(AM_LDFLAGS) \
-       $(COVERAGE_LDFLAGS) \
-       -version-info $(LIBPAKFIRE_CURRENT):$(LIBPAKFIRE_REVISION):$(LIBPAKFIRE_AGE) \
-       -Wl,--version-script=$(top_srcdir)/src/libpakfire/libpakfire.sym
+       $(COVERAGE_LDFLAGS)
 
 libpakfire_la_LIBADD = \
        libpakfire-parser.la \
@@ -360,37 +351,8 @@ libpakfire_la_LIBADD = \
        $(ZSTD_LIBS)
 
 libpakfire_la_DEPENDENCIES = \
-       src/libpakfire/libpakfire.sym \
        libpakfire-parser.la
 
-EXTRA_DIST += \
-       src/libpakfire/libpakfire.sym
-
-# ------------------------------------------------------------------------------
-
-noinst_LTLIBRARIES += \
-       libpakfire-internal.la
-
-libpakfire_internal_la_SOURCES = \
-       $(libpakfire_la_SOURCES)
-
-libpakfire_internal_la_CPPFLAGS = \
-       $(libpakfire_la_CPPFLAGS)
-
-libpakfire_internal_la_CFLAGS = \
-       $(libpakfire_la_CFLAGS)
-
-libpakfire_internal_la_LDFLAGS = \
-       $(AM_LDFLAGS) \
-       $(COVERAGE_LDFLAGS) \
-       -Wl,--version-script=$(top_srcdir)/src/libpakfire/libpakfire.sym
-
-libpakfire_internal_la_LIBADD = \
-       $(libpakfire_la_LIBADD)
-
-libpakfire_internal_la_DEPENDENCIES = \
-       $(libpakfire_la_DEPENDENCIES)
-
 # ------------------------------------------------------------------------------
 
 bin_PROGRAMS += \
@@ -401,7 +363,7 @@ pakfire_SOURCES = \
 
 pakfire_CPPFLAGS = \
        $(AM_CPPFLAGS) \
-       -I$(top_srcdir)/src/libpakfire/include
+       -I$(top_srcdir)/src
 
 pakfire_CFLAGS = \
        $(AM_CFLAGS) \
@@ -425,7 +387,7 @@ pakfire_builder_SOURCES = \
 
 pakfire_builder_CPPFLAGS = \
        $(AM_CPPFLAGS) \
-       -I$(top_srcdir)/src/libpakfire/include
+       -I$(top_srcdir)/src
 
 pakfire_builder_CFLAGS = \
        $(AM_CFLAGS) \
@@ -449,7 +411,7 @@ pakfire_client_SOURCES = \
 
 pakfire_client_CPPFLAGS = \
        $(AM_CPPFLAGS) \
-       -I$(top_srcdir)/src/libpakfire/include
+       -I$(top_srcdir)/src
 
 pakfire_client_CFLAGS = \
        $(AM_CFLAGS) \
@@ -475,7 +437,7 @@ dist_pakfire_daemon_SOURCES = \
 
 pakfire_daemon_CPPFLAGS = \
        $(AM_CPPFLAGS) \
-       -I$(top_srcdir)/src/libpakfire/include
+       -I$(top_srcdir)/src
 
 pakfire_daemon_CFLAGS = \
        $(AM_CFLAGS) \
@@ -581,7 +543,7 @@ libcli_la_SOURCES = \
 libcli_la_CPPFLAGS = \
        $(AM_CPPFLAGS) \
        -DPAKFIRE_PRIVATE \
-       -I$(top_srcdir)/src/libpakfire/include
+       -I$(top_srcdir)/src
 
 libcli_la_CFLAGS = \
        $(AM_CFLAGS) \
@@ -594,8 +556,7 @@ libcli_la_LDFLAGS = \
        $(JSON_C_LIBS)
 
 libcli_la_LIBADD = \
-       libpakfire.la \
-       libpakfire-internal.la
+       libpakfire.la
 
 # ------------------------------------------------------------------------------
 
@@ -1043,7 +1004,7 @@ dist_tests_parser_test_SOURCES = \
 
 tests_parser_test_CPPFLAGS = \
        $(AM_CPPFLAGS) \
-       $(PAKFIRE_CPPFLAGS) \
+       -I$(top_srcdir)/src \
        -DPAKFIRE_PRIVATE
 
 tests_parser_test_CFLAGS = \
@@ -1053,8 +1014,7 @@ tests_parser_test_LDFLAGS = \
        $(TESTSUITE_LDFLAGS)
 
 tests_parser_test_LDADD = \
-       libpakfire.la \
-       libpakfire-internal.la
+       libpakfire.la
 
 # ------------------------------------------------------------------------------
 
@@ -1209,7 +1169,7 @@ tests_libtestsuite_la_CPPFLAGS = \
 
 TESTSUITE_CPPFLAGS = \
        $(AM_CPPFLAGS) \
-       $(PAKFIRE_CPPFLAGS) \
+       -I$(top_srcdir)/src \
        -DABS_TOP_SRCDIR=\"$(abs_top_srcdir)\" \
        -DTEST_CONFIG_FILE=\"$(abs_top_srcdir)/contrib/config/pakfire.conf\" \
        -DTEST_DATA_DIR=\"$(abs_top_srcdir)/tests/data\" \
@@ -1228,8 +1188,7 @@ TESTSUITE_LDFLAGS = \
 
 TESTSUITE_LDADD = \
        tests/libtestsuite.la \
-       libpakfire.la \
-       libpakfire-internal.la
+       libpakfire.la
 
 TESTS_ENVIRONMENT = \
        TEST_CONFIG_FILE="$(abs_top_srcdir)/tests/pakfire.conf" \
@@ -1244,7 +1203,7 @@ TESTS_ENVIRONMENT += \
 
 # Test the Python modules we just built
 TESTS_ENVIRONMENT += \
-       PYTHONPATH=$(top_srcdir)/.libs:$(PYTHONPATH)
+       PYTHONPATH=$(top_builddir)/.libs:$(PYTHONPATH)
 
 dist_check_SCRIPTS = \
        tests/python/archive.py \
index 960e955d7f8ff93d7a91d4cc48f342f3e7b205a8..6b2412f5d64ebea0b12e3184b59162bae33262aa 100644 (file)
@@ -50,31 +50,6 @@ Depends:
 Description: ${source:Synopsis} (CLI utilities)
  ${source:Extended-Description}
 
-Package: libpakfire0
-Architecture: any
-Section: libs
-Depends:
- ${shlibs:Depends},
- ${misc:Depends},
-Multi-Arch: same
-Description: ${source:Synopsis}
- ${source:Extended-Description}
- .
- This package provides the shared library.
-
-Package: libpakfire-dev
-Architecture: any
-Section: libdevel
-Depends:
- libpakfire0 (= ${binary:Version}),
- ${misc:Depends},
-Multi-Arch: same
-Description: ${source:Synopsis} (development files)
- ${source:Extended-Description}
- .
- This package provides the headers and development files needed to use
- libpakfire in your own programs.
-
 Package: python3-pakfire
 Architecture: any
 Section: python
@@ -86,4 +61,4 @@ Multi-Arch: foreign
 Description: ${source:Synopsis} (Python 3 bindings)
  ${source:Extended-Description}
  .
- This package provides the Python 3 bindings for libpakfire.
+ This package provides the Python 3 bindings for Pakfire.
diff --git a/debian/libpakfire-dev.install b/debian/libpakfire-dev.install
deleted file mode 100644 (file)
index 1175ecb..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-usr/include/pakfire
-usr/lib/*/libpakfire.so
-usr/share/doc/pakfire
-usr/share/man/man5
diff --git a/debian/libpakfire0.install b/debian/libpakfire0.install
deleted file mode 100644 (file)
index 7a709a0..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-usr/lib/*/libpakfire.so.*
-usr/share/locale/*/LC_MESSAGES/pakfire.mo
index ed3a7083ca3005e7f34d92cc0a3cb6a465f083f8..5549f9dd59c9160c30b0061ede782f13551c395a 100644 (file)
@@ -1,2 +1 @@
-usr/lib/*/libpakfire.la
 usr/lib/python3/dist-packages/pakfire/pakfire.la
diff --git a/src/libpakfire/include/pakfire/private.h b/src/libpakfire/include/pakfire/private.h
deleted file mode 100644 (file)
index 76dc04e..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-/*#############################################################################
-#                                                                             #
-# Pakfire - The IPFire package management system                              #
-# Copyright (C) 2013 Pakfire development team                                 #
-#                                                                             #
-# This program is free software: you can redistribute it and/or modify        #
-# it under the terms of the GNU General Public License as published by        #
-# the Free Software Foundation, either version 3 of the License, or           #
-# (at your option) any later version.                                         #
-#                                                                             #
-# This program is distributed in the hope that it will be useful,             #
-# but WITHOUT ANY WARRANTY; without even the implied warranty of              #
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the               #
-# GNU General Public License for more details.                                #
-#                                                                             #
-# You should have received a copy of the GNU General Public License           #
-# along with this program.  If not, see <http://www.gnu.org/licenses/>.       #
-#                                                                             #
-#############################################################################*/
-
-#ifndef PAKFIRE_PRIVATE_H
-#define PAKFIRE_PRIVATE_H
-
-#ifdef PAKFIRE_PRIVATE
-#define PAKFIRE_EXPORT __attribute__ ((visibility("default")))
-#endif
-
-/*
-       Buffer size that is used whenever we read any files into
-       something like a hash function.
-*/
-#define PAKFIRE_BUFFER_SIZE 65536
-
-#endif /* PAKFIRE_PRIVATE_H */
diff --git a/src/libpakfire/libpakfire.sym b/src/libpakfire/libpakfire.sym
deleted file mode 100644 (file)
index df584b1..0000000
+++ /dev/null
@@ -1,303 +0,0 @@
-/*#############################################################################
-#                                                                             #
-# Pakfire - The IPFire package management system                              #
-# Copyright (C) 2013 Pakfire development team                                 #
-#                                                                             #
-# This program is free software: you can redistribute it and/or modify        #
-# it under the terms of the GNU General Public License as published by        #
-# the Free Software Foundation, either version 3 of the License, or           #
-# (at your option) any later version.                                         #
-#                                                                             #
-# This program is distributed in the hope that it will be useful,             #
-# but WITHOUT ANY WARRANTY; without even the implied warranty of              #
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the               #
-# GNU General Public License for more details.                                #
-#                                                                             #
-# You should have received a copy of the GNU General Public License           #
-# along with this program.  If not, see <http://www.gnu.org/licenses/>.       #
-#                                                                             #
-#############################################################################*/
-
-LIBPAKFIRE_0 {
-global:
-       # pakfire ctx
-       pakfire_ctx_create;
-       pakfire_ctx_ref;
-       pakfire_ctx_unref;
-       pakfire_ctx_get_log_level;
-       pakfire_ctx_set_log_level;
-       pakfire_ctx_set_log_callback;
-       pakfire_ctx_set_confirm_callback;
-       pakfire_ctx_set_progress_callback;
-       pakfire_ctx_set_pick_solution_callback;
-       pakfire_ctx_has_flag;
-       pakfire_ctx_set_flag;
-       pakfire_ctx_get_cache_path;
-       pakfire_ctx_set_cache_path;
-
-       # pakfire
-       pakfire_check;
-       pakfire_clean;
-       pakfire_create;
-       pakfire_get_arch;
-       pakfire_get_path;
-       pakfire_get_repo;
-       pakfire_get_repos;
-       pakfire_has_flag;
-       pakfire_ref;
-       pakfire_refresh;
-       pakfire_search;
-       pakfire_set_confirm_callback;
-       pakfire_set_pick_solution_callback;
-       pakfire_set_setup_progress_callback;
-       pakfire_unref;
-       pakfire_update_snapshot;
-       pakfire_version_compare;
-       pakfire_whatprovides;
-       pakfire_whatrequires;
-
-       # arch
-       pakfire_arch_native;
-       pakfire_arch_supported;
-       pakfire_supported_arches;
-       pakfire_arch_is_supported_by_host;
-
-       # archive
-       pakfire_archive_extract;
-       pakfire_archive_get_filelist;
-       pakfire_archive_get_format;
-       pakfire_archive_get_path;
-       pakfire_archive_get_size;
-       pakfire_archive_lint;
-       pakfire_archive_make_package;
-       pakfire_archive_open;
-       pakfire_archive_read;
-       pakfire_archive_ref;
-       pakfire_archive_unref;
-       pakfire_archive_verify;
-
-       # build
-       pakfire_build_create;
-       pakfire_build_exec;
-       pakfire_build_install;
-       pakfire_build_mkimage;
-       pakfire_build_ref;
-       pakfire_build_shell;
-       pakfire_build_set_ccache_path;
-       pakfire_build_set_target;
-       pakfire_build_unref;
-
-       # buildservice
-       pakfire_buildservice_create;
-       pakfire_buildservice_ref;
-       pakfire_buildservice_unref;
-       pakfire_buildservice_list_uploads;
-       pakfire_buildservice_upload;
-       pakfire_buildservice_delete_upload;
-       pakfire_buildservice_list_repos;
-       pakfire_buildservice_get_repo;
-       pakfire_buildservice_create_repo;
-       pakfire_buildservice_delete_repo;
-       pakfire_buildservice_get_url;
-       pakfire_buildservice_job_finished;
-
-       # dependencies
-       pakfire_static_version_compare;
-
-       # digest
-       pakfire_digest_get_by_name;
-       pakfire_digest_name;
-
-       # dist
-       pakfire_dist;
-
-       # file
-       pakfire_file_cmp;
-       pakfire_file_create;
-       pakfire_file_get_caps;
-       pakfire_file_get_ctime;
-       pakfire_file_get_dev;
-       pakfire_file_get_digest;
-       pakfire_file_get_gname;
-       pakfire_file_get_inode;
-       pakfire_file_get_mimetype;
-       pakfire_file_get_mode;
-       pakfire_file_get_mtime;
-       pakfire_file_get_nlink;
-       pakfire_file_get_path;
-       pakfire_file_get_perms;
-       pakfire_file_get_size;
-       pakfire_file_get_time;
-       pakfire_file_get_type;
-       pakfire_file_get_uname;
-       pakfire_file_has_caps;
-       pakfire_file_matches;
-       pakfire_file_set_ctime;
-       pakfire_file_set_dev;
-       pakfire_file_set_digest;
-       pakfire_file_set_gname;
-       pakfire_file_set_inode;
-       pakfire_file_set_mimetype;
-       pakfire_file_set_mode;
-       pakfire_file_set_mtime;
-       pakfire_file_set_nlink;
-       pakfire_file_set_path;
-       pakfire_file_set_perms;
-       pakfire_file_set_size;
-       pakfire_file_set_time;
-       pakfire_file_set_uname;
-       pakfire_file_ref;
-       pakfire_file_unref;
-
-       # filelist
-       pakfire_filelist_add;
-       pakfire_filelist_clear;
-       pakfire_filelist_create;
-       pakfire_filelist_get;
-       pakfire_filelist_is_empty;
-       pakfire_filelist_length;
-       pakfire_filelist_ref;
-       pakfire_filelist_unref;
-
-       # key
-       pakfire_key_dump;
-       pakfire_key_export;
-       pakfire_key_generate;
-       pakfire_key_get;
-       pakfire_key_get_algo;
-       pakfire_key_get_comment;
-       pakfire_key_get_id;
-       pakfire_key_import;
-       pakfire_key_ref;
-       pakfire_key_sign;
-       pakfire_key_unref;
-       pakfire_key_verify;
-
-       # log
-       pakfire_log_stderr;
-       pakfire_log_syslog;
-
-       # package
-       pakfire_package_cmp;
-       pakfire_package_create;
-       pakfire_package_dump;
-       pakfire_package_eq;
-       pakfire_package_get_cache_path;
-       pakfire_package_get_deps;
-       pakfire_package_get_digest;
-       pakfire_package_get_filelist;
-       pakfire_package_get_num;
-       pakfire_package_get_pakfire;
-       pakfire_package_get_path;
-       pakfire_package_get_repo;
-       pakfire_package_get_reverse_requires;
-       pakfire_package_get_size;
-       pakfire_package_get_string;
-       pakfire_package_get_strings;
-       pakfire_package_get_uuid;
-       pakfire_package_id;
-       pakfire_package_installcheck;
-       pakfire_package_ref;
-       pakfire_package_set_checksum;
-       pakfire_package_set_filelist;
-       pakfire_package_set_num;
-       pakfire_package_set_path;
-       pakfire_package_set_string;
-       pakfire_package_set_strings;
-       pakfire_package_set_uuid;
-       pakfire_package_unref;
-
-       # packagelist
-       pakfire_packagelist_create;
-       pakfire_packagelist_get;
-       pakfire_packagelist_length;
-       pakfire_packagelist_push;
-       pakfire_packagelist_ref;
-       pakfire_packagelist_sort;
-       pakfire_packagelist_unref;
-       pakfire_packagelist_walk;
-
-       # problem
-       pakfire_problem_get_solutions;
-       pakfire_problem_ref;
-       pakfire_problem_to_string;
-       pakfire_problem_unref;
-
-       # progress
-       pakfire_progress_get_elapsed_time;
-       pakfire_progress_get_eta;
-       pakfire_progress_get_max_value;
-       pakfire_progress_get_percentage;
-       pakfire_progress_get_title;
-       pakfire_progress_get_transfer_speed;
-       pakfire_progress_get_value;
-       pakfire_progress_has_flag;
-       pakfire_progress_set_callback_data;
-       pakfire_progress_set_finish_callback;
-       pakfire_progress_set_free_callback;
-       pakfire_progress_set_start_callback;
-       pakfire_progress_set_update_callback;
-
-       # repo
-       pakfire_repo_cmp;
-       pakfire_repo_compose;
-       pakfire_repo_count;
-       pakfire_repo_clean;
-       pakfire_repo_create;
-       pakfire_repo_get_baseurl;
-       pakfire_repo_get_description;
-       pakfire_repo_get_name;
-       pakfire_repo_get_enabled;
-       pakfire_repo_get_key;
-       pakfire_repo_get_mirrorlist_url;
-       pakfire_repo_get_pakfire;
-       pakfire_repo_get_pool;
-       pakfire_repo_get_priority;
-       pakfire_repo_identical;
-       pakfire_repo_is_installed_repo;
-       pakfire_repo_read_solv;
-       pakfire_repo_ref;
-       pakfire_repo_refresh;
-       pakfire_repo_scan;
-       pakfire_repo_set_baseurl;
-       pakfire_repo_set_description;
-       pakfire_repo_set_enabled;
-       pakfire_repo_set_mirrorlist_url;
-       pakfire_repo_set_priority;
-       pakfire_repo_write_config;
-       pakfire_repo_write_solv;
-       pakfire_repo_unref;
-
-       # repolist
-       pakfire_repolist_append;
-       pakfire_repolist_clear;
-       pakfire_repolist_create;
-       pakfire_repolist_empty;
-       pakfire_repolist_get;
-       pakfire_repolist_size;
-       pakfire_repolist_ref;
-       pakfire_repolist_unref;
-
-       # solution
-       pakfire_solution_ref;
-       pakfire_solution_to_string;
-       pakfire_solution_unref;
-
-       # transaction
-       pakfire_transaction_count;
-       pakfire_transaction_create;
-       pakfire_transaction_download;
-       pakfire_transaction_dump;
-       pakfire_transaction_get_problems;
-       pakfire_transaction_ref;
-       pakfire_transaction_request;
-       pakfire_transaction_request_package;
-       pakfire_transaction_run;
-       pakfire_transaction_set_pick_solution_callback;
-       pakfire_transaction_solve;
-       pakfire_transaction_take_solution;
-       pakfire_transaction_unref;
-
-local:
-       *;
-};
similarity index 96%
rename from src/libpakfire/arch.c
rename to src/pakfire/arch.c
index 064e27ba1625107980db732c9bab846e2a6efe55..e81ae2d227642f3133ffbe7331af40b554baf3e7 100644 (file)
@@ -32,7 +32,6 @@
 
 #include <pakfire/arch.h>
 #include <pakfire/constants.h>
-#include <pakfire/private.h>
 #include <pakfire/string.h>
 #include <pakfire/util.h>
 
@@ -82,7 +81,7 @@ static const struct pakfire_arch* pakfire_arch_find(const char* name) {
        return NULL;
 }
 
-PAKFIRE_EXPORT int pakfire_arch_supported(const char* name) {
+int pakfire_arch_supported(const char* name) {
        const struct pakfire_arch* arch = pakfire_arch_find(name);
 
        if (arch)
@@ -100,7 +99,7 @@ static size_t pakfire_num_arches(void) {
        return i;
 }
 
-PAKFIRE_EXPORT const char** pakfire_supported_arches(void) {
+const char** pakfire_supported_arches(void) {
        const struct pakfire_arch* arch = NULL;
        static const char** arches = NULL;
 
@@ -177,7 +176,7 @@ int __pakfire_arch_buildtarget(char* buffer, size_t length, const char* arch, co
        return 0;
 }
 
-PAKFIRE_EXPORT const char* pakfire_arch_native(void) {
+const char* pakfire_arch_native(void) {
        struct utsname buf;
 
        static __thread const char* arch_native = NULL;
@@ -236,7 +235,7 @@ static const char* pakfire_arch_is_natively_supported_by_host(const char* name)
        return NULL;
 }
 
-PAKFIRE_EXPORT const char* pakfire_arch_is_supported_by_host(const char* name) {
+const char* pakfire_arch_is_supported_by_host(const char* name) {
        const char* arch = NULL;
 
        // Check if we natively support this architecture
similarity index 97%
rename from src/libpakfire/archive.c
rename to src/pakfire/archive.c
index 28c2a92d0942380e85259153c8f1f1f2f5e8be10..33a0fbc2b788992cecfcc78c56f5b05057f51c31 100644 (file)
@@ -48,7 +48,6 @@
 #include <pakfire/package.h>
 #include <pakfire/pakfire.h>
 #include <pakfire/path.h>
-#include <pakfire/private.h>
 #include <pakfire/repo.h>
 #include <pakfire/scriptlet.h>
 #include <pakfire/string.h>
@@ -415,13 +414,13 @@ static void pakfire_archive_free(struct pakfire_archive* archive) {
        free(archive);
 }
 
-PAKFIRE_EXPORT struct pakfire_archive* pakfire_archive_ref(struct pakfire_archive* archive) {
+struct pakfire_archive* pakfire_archive_ref(struct pakfire_archive* archive) {
        ++archive->nrefs;
 
        return archive;
 }
 
-PAKFIRE_EXPORT struct pakfire_archive* pakfire_archive_unref(struct pakfire_archive* archive) {
+struct pakfire_archive* pakfire_archive_unref(struct pakfire_archive* archive) {
        if (--archive->nrefs > 0)
                return archive;
 
@@ -678,7 +677,7 @@ static int pakfire_archive_read_metadata(struct pakfire_archive* archive) {
        return 0;
 }
 
-PAKFIRE_EXPORT int pakfire_archive_open(struct pakfire_archive** archive,
+int pakfire_archive_open(struct pakfire_archive** archive,
                struct pakfire* pakfire, const char* path) {
        struct pakfire_archive* a = NULL;
        int r;
@@ -923,7 +922,7 @@ static int __pakfire_archive_read(struct pakfire_archive* archive,
        return PAKFIRE_WALK_DONE;
 }
 
-PAKFIRE_EXPORT FILE* pakfire_archive_read(struct pakfire_archive* archive, const char* path, int flags) {
+FILE* pakfire_archive_read(struct pakfire_archive* archive, const char* path, int flags) {
        struct pakfire_archive_read_cookie* cookie = NULL;
        int r;
 
@@ -1371,16 +1370,16 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_archive_extract(struct pakfire_archive* archive,
+int pakfire_archive_extract(struct pakfire_archive* archive,
                const char* path, const int flags) {
        return __pakfire_archive_extract(archive, path, flags);
 }
 
-PAKFIRE_EXPORT const char* pakfire_archive_get_path(struct pakfire_archive* archive) {
+const char* pakfire_archive_get_path(struct pakfire_archive* archive) {
        return archive->path;
 }
 
-PAKFIRE_EXPORT unsigned int pakfire_archive_get_format(struct pakfire_archive* archive) {
+unsigned int pakfire_archive_get_format(struct pakfire_archive* archive) {
        return archive->format;
 }
 
@@ -1390,7 +1389,7 @@ static int pakfire_archive_load_filelist(struct pakfire_archive* archive) {
                PAKFIRE_EXTRACT_DRY_RUN|PAKFIRE_EXTRACT_NO_PROGRESS);
 }
 
-PAKFIRE_EXPORT struct pakfire_filelist* pakfire_archive_get_filelist(struct pakfire_archive* archive) {
+struct pakfire_filelist* pakfire_archive_get_filelist(struct pakfire_archive* archive) {
        if (!archive->filelist) {
                int r = pakfire_archive_load_filelist(archive);
                if (r)
@@ -1403,12 +1402,12 @@ PAKFIRE_EXPORT struct pakfire_filelist* pakfire_archive_get_filelist(struct pakf
        return pakfire_filelist_ref(archive->filelist);
 }
 
-PAKFIRE_EXPORT int pakfire_archive_verify(struct pakfire_archive* archive, int* status) {
+int pakfire_archive_verify(struct pakfire_archive* archive, int* status) {
        // XXX currently not implemented
        return 0;
 }
 
-PAKFIRE_EXPORT ssize_t pakfire_archive_get_size(struct pakfire_archive* archive) {
+ssize_t pakfire_archive_get_size(struct pakfire_archive* archive) {
        return archive->stat.st_size;
 }
 
@@ -1744,7 +1743,7 @@ ERROR:
 /*
        Copy all metadata from this archive to the package object
 */
-PAKFIRE_EXPORT int pakfire_archive_make_package(struct pakfire_archive* archive,
+int pakfire_archive_make_package(struct pakfire_archive* archive,
                struct pakfire_repo* repo, struct pakfire_package** package) {
        struct pakfire_repo* dummy = NULL;
        int r;
@@ -1851,7 +1850,7 @@ int pakfire_archive_apply_systemd_sysusers(struct pakfire_archive* archive) {
        return 0;
 }
 
-PAKFIRE_EXPORT int pakfire_archive_lint(struct pakfire_archive* archive,
+int pakfire_archive_lint(struct pakfire_archive* archive,
                pakfire_linter_result_callback callback, void* data) {
        struct pakfire_linter* linter = NULL;
        int r;
similarity index 100%
rename from src/libpakfire/base64.c
rename to src/pakfire/base64.c
similarity index 98%
rename from src/libpakfire/build.c
rename to src/pakfire/build.c
index 59a65763933c74eddc90f807aae76544f791254f..76cc08fcd53ae6d6b1baa8ba1c4dcad72965564f 100644 (file)
@@ -44,7 +44,6 @@
 #include <pakfire/packager.h>
 #include <pakfire/parser.h>
 #include <pakfire/path.h>
-#include <pakfire/private.h>
 #include <pakfire/problem.h>
 #include <pakfire/repo.h>
 #include <pakfire/scriptlet.h>
@@ -1635,7 +1634,7 @@ static int pakfire_build_set_time_start(struct pakfire_build* build) {
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_build_create(struct pakfire_build** build,
+int pakfire_build_create(struct pakfire_build** build,
                struct pakfire* pakfire, const char* id, int flags) {
        int r;
 
@@ -1699,13 +1698,13 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT struct pakfire_build* pakfire_build_ref(struct pakfire_build* build) {
+struct pakfire_build* pakfire_build_ref(struct pakfire_build* build) {
        ++build->nrefs;
 
        return build;
 }
 
-PAKFIRE_EXPORT struct pakfire_build* pakfire_build_unref(struct pakfire_build* build) {
+struct pakfire_build* pakfire_build_unref(struct pakfire_build* build) {
        if (--build->nrefs > 0)
                return build;
 
@@ -1713,7 +1712,7 @@ PAKFIRE_EXPORT struct pakfire_build* pakfire_build_unref(struct pakfire_build* b
        return NULL;
 }
 
-PAKFIRE_EXPORT int pakfire_build_set_ccache_path(
+int pakfire_build_set_ccache_path(
                struct pakfire_build* build, const char* path) {
        // Check if this can be called
        if (pakfire_build_has_flag(build, PAKFIRE_BUILD_DISABLE_CCACHE))
@@ -1727,7 +1726,7 @@ PAKFIRE_EXPORT int pakfire_build_set_ccache_path(
        return pakfire_string_set(build->ccache_path, path);
 }
 
-PAKFIRE_EXPORT int pakfire_build_set_target(
+int pakfire_build_set_target(
                struct pakfire_build* build, const char* target) {
        return pakfire_string_set(build->target, target);
 }
@@ -2174,7 +2173,7 @@ static int pakfire_build_lint(struct pakfire_build* build) {
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_build_exec(struct pakfire_build* build, const char* path) {
+int pakfire_build_exec(struct pakfire_build* build, const char* path) {
        struct pakfire_package* package = NULL;
        struct pakfire_parser* makefile = NULL;
        char* buildroot = NULL;
@@ -2417,7 +2416,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_build_mkimage(struct pakfire_build* build,
+int pakfire_build_mkimage(struct pakfire_build* build,
                const char* type, FILE* f) {
        FILE* t = NULL;
        char packagesdir[PATH_MAX];
@@ -2526,7 +2525,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_build_install(struct pakfire_build* build, const char** packages) {
+int pakfire_build_install(struct pakfire_build* build, const char** packages) {
        struct pakfire_transaction* transaction = NULL;
        char* problems = NULL;
        int r;
@@ -2567,7 +2566,7 @@ ERROR:
 /*
        Drops the user into a shell
 */
-PAKFIRE_EXPORT int pakfire_build_shell(struct pakfire_build* build, const char* argv[]) {
+int pakfire_build_shell(struct pakfire_build* build, const char* argv[]) {
        int r;
 
        // Initialize the build environment
similarity index 94%
rename from src/libpakfire/buildservice.c
rename to src/pakfire/buildservice.c
index fc8f84e74465d2da9572f634288954372f612769..05b71b48df9244f680eb85b919533924fb33b1b7 100644 (file)
@@ -31,7 +31,6 @@
 #include <pakfire/logging.h>
 #include <pakfire/os.h>
 #include <pakfire/path.h>
-#include <pakfire/private.h>
 #include <pakfire/string.h>
 #include <pakfire/xfer.h>
 
@@ -159,7 +158,7 @@ static void pakfire_buildservice_free(struct pakfire_buildservice* service) {
        free(service);
 }
 
-PAKFIRE_EXPORT int pakfire_buildservice_create(
+int pakfire_buildservice_create(
                struct pakfire_buildservice** service, struct pakfire_ctx* ctx) {
        struct pakfire_buildservice* s = NULL;
        int r;
@@ -194,14 +193,14 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT struct pakfire_buildservice* pakfire_buildservice_ref(
+struct pakfire_buildservice* pakfire_buildservice_ref(
                struct pakfire_buildservice* service) {
        ++service->nrefs;
 
        return service;
 }
 
-PAKFIRE_EXPORT struct pakfire_buildservice* pakfire_buildservice_unref(
+struct pakfire_buildservice* pakfire_buildservice_unref(
                struct pakfire_buildservice* service) {
        if (--service->nrefs > 0)
                return service;
@@ -210,7 +209,7 @@ PAKFIRE_EXPORT struct pakfire_buildservice* pakfire_buildservice_unref(
        return NULL;
 }
 
-PAKFIRE_EXPORT const char* pakfire_buildservice_get_url(struct pakfire_buildservice* service) {
+const char* pakfire_buildservice_get_url(struct pakfire_buildservice* service) {
        return service->url;
 }
 
@@ -413,7 +412,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_buildservice_upload(struct pakfire_buildservice* service,
+int pakfire_buildservice_upload(struct pakfire_buildservice* service,
                const char* path, const char* filename, char** uuid) {
        char basename[NAME_MAX];
        FILE* f = NULL;
@@ -460,7 +459,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_buildservice_list_uploads(
+int pakfire_buildservice_list_uploads(
                struct pakfire_buildservice* service, struct json_object** p) {
        struct pakfire_xfer* xfer = NULL;
        struct json_object* response = NULL;
@@ -502,7 +501,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_buildservice_delete_upload(
+int pakfire_buildservice_delete_upload(
                struct pakfire_buildservice* service, const char* uuid) {
        struct pakfire_xfer* xfer = NULL;
        struct json_object* response = NULL;
@@ -539,7 +538,7 @@ ERROR:
 
 // Repositories
 
-PAKFIRE_EXPORT int pakfire_buildservice_list_repos(struct pakfire_buildservice* service,
+int pakfire_buildservice_list_repos(struct pakfire_buildservice* service,
                const char* distro, struct json_object** p) {
        struct pakfire_xfer* xfer = NULL;
        struct json_object* response = NULL;
@@ -584,7 +583,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_buildservice_get_repo(struct pakfire_buildservice* service,
+int pakfire_buildservice_get_repo(struct pakfire_buildservice* service,
                const char* distro, const char* name, struct json_object** p) {
        struct pakfire_xfer* xfer = NULL;
        struct json_object* response = NULL;
@@ -621,7 +620,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_buildservice_create_repo(struct pakfire_buildservice* service,
+int pakfire_buildservice_create_repo(struct pakfire_buildservice* service,
                const char* distro, const char* name, const char* description, struct json_object** p) {
        struct pakfire_xfer* xfer = NULL;
        struct json_object* response = NULL;
@@ -671,7 +670,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_buildservice_delete_repo(struct pakfire_buildservice* service,
+int pakfire_buildservice_delete_repo(struct pakfire_buildservice* service,
                const char* distro, const char* name) {
        struct pakfire_xfer* xfer = NULL;
        int r;
@@ -703,7 +702,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_buildservice_job_finished(struct pakfire_buildservice* service,
+int pakfire_buildservice_job_finished(struct pakfire_buildservice* service,
                const char* uuid, int success, const char* logfile, const char** packages) {
        struct pakfire_xfer* xfer = NULL;
        int r;
similarity index 100%
rename from src/libpakfire/cgroup.c
rename to src/pakfire/cgroup.c
similarity index 100%
rename from src/libpakfire/config.c
rename to src/pakfire/config.c
similarity index 89%
rename from src/libpakfire/ctx.c
rename to src/pakfire/ctx.c
index 859384d205eb8b3f0f292bf3a7e153e10e5ca390..8159766d4f86c9e8cf96a877437704ccc16b64b4 100644 (file)
@@ -34,7 +34,6 @@
 #include <pakfire/ctx.h>
 #include <pakfire/logging.h>
 #include <pakfire/os.h>
-#include <pakfire/private.h>
 #include <pakfire/string.h>
 
 struct pakfire_ctx {
@@ -186,7 +185,7 @@ static void pakfire_ctx_free(struct pakfire_ctx* ctx) {
        free(ctx);
 }
 
-PAKFIRE_EXPORT int pakfire_ctx_create(struct pakfire_ctx** ctx, const char* path) {
+int pakfire_ctx_create(struct pakfire_ctx** ctx, const char* path) {
        struct pakfire_ctx* c = NULL;
        int r;
 
@@ -238,13 +237,13 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT struct pakfire_ctx* pakfire_ctx_ref(struct pakfire_ctx* ctx) {
+struct pakfire_ctx* pakfire_ctx_ref(struct pakfire_ctx* ctx) {
        ctx->nrefs++;
 
        return ctx;
 }
 
-PAKFIRE_EXPORT struct pakfire_ctx* pakfire_ctx_unref(struct pakfire_ctx* ctx) {
+struct pakfire_ctx* pakfire_ctx_unref(struct pakfire_ctx* ctx) {
        if (--ctx->nrefs > 0)
                return ctx;
 
@@ -254,11 +253,11 @@ PAKFIRE_EXPORT struct pakfire_ctx* pakfire_ctx_unref(struct pakfire_ctx* ctx) {
 
 // Flags
 
-PAKFIRE_EXPORT int pakfire_ctx_has_flag(struct pakfire_ctx* ctx, int flag) {
+int pakfire_ctx_has_flag(struct pakfire_ctx* ctx, int flag) {
        return ctx->flags & flag;
 }
 
-PAKFIRE_EXPORT int pakfire_ctx_set_flag(struct pakfire_ctx* ctx, int flag) {
+int pakfire_ctx_set_flag(struct pakfire_ctx* ctx, int flag) {
        ctx->flags |= flag;
 
        return 0;
@@ -281,15 +280,15 @@ const struct pakfire_distro* pakfire_ctx_get_distro(struct pakfire_ctx* ctx) {
 
 // Logging
 
-PAKFIRE_EXPORT int pakfire_ctx_get_log_level(struct pakfire_ctx* ctx) {
+int pakfire_ctx_get_log_level(struct pakfire_ctx* ctx) {
        return ctx->log.level;
 }
 
-PAKFIRE_EXPORT void pakfire_ctx_set_log_level(struct pakfire_ctx* ctx, int level) {
+void pakfire_ctx_set_log_level(struct pakfire_ctx* ctx, int level) {
        ctx->log.level = level;
 }
 
-PAKFIRE_EXPORT void pakfire_ctx_set_log_callback(struct pakfire_ctx* ctx,
+void pakfire_ctx_set_log_callback(struct pakfire_ctx* ctx,
                pakfire_log_callback callback, void* data) {
        ctx->log.callback = callback;
        ctx->log.data     = data;
@@ -310,11 +309,11 @@ void pakfire_ctx_log(struct pakfire_ctx* ctx, int level, const char* file, int l
 
 // Paths
 
-PAKFIRE_EXPORT const char* pakfire_ctx_get_cache_path(struct pakfire_ctx* ctx) {
+const char* pakfire_ctx_get_cache_path(struct pakfire_ctx* ctx) {
        return ctx->paths.cache;
 }
 
-PAKFIRE_EXPORT int pakfire_ctx_set_cache_path(struct pakfire_ctx* ctx, const char* path) {
+int pakfire_ctx_set_cache_path(struct pakfire_ctx* ctx, const char* path) {
        wordexp_t result = {};
        int r;
 
@@ -344,7 +343,7 @@ ERROR:
 
 // Confirm
 
-PAKFIRE_EXPORT void pakfire_ctx_set_confirm_callback(struct pakfire_ctx* ctx,
+void pakfire_ctx_set_confirm_callback(struct pakfire_ctx* ctx,
                pakfire_confirm_callback callback, void* data) {
        ctx->confirm.callback = callback;
        ctx->confirm.data     = data;
@@ -361,7 +360,7 @@ int pakfire_ctx_confirm(struct pakfire_ctx* ctx, struct pakfire* pakfire,
 
 // Progress
 
-PAKFIRE_EXPORT void pakfire_ctx_set_progress_callback(struct pakfire_ctx* ctx,
+void pakfire_ctx_set_progress_callback(struct pakfire_ctx* ctx,
                pakfire_progress_callback callback, void* data) {
        ctx->progress.callback = callback;
        ctx->progress.data     = data;
@@ -376,7 +375,7 @@ int pakfire_ctx_setup_progress(struct pakfire_ctx* ctx, struct pakfire_progress*
 
 // Pick Solution
 
-PAKFIRE_EXPORT void pakfire_ctx_set_pick_solution_callback(struct pakfire_ctx* ctx,
+void pakfire_ctx_set_pick_solution_callback(struct pakfire_ctx* ctx,
                pakfire_pick_solution_callback callback, void* data) {
        ctx->pick_solution.callback = callback;
        ctx->pick_solution.data     = data;
similarity index 100%
rename from src/libpakfire/daemon.c
rename to src/pakfire/daemon.c
similarity index 100%
rename from src/libpakfire/db.c
rename to src/pakfire/db.c
similarity index 98%
rename from src/libpakfire/deps.c
rename to src/pakfire/deps.c
index b06493bae7d5232402403f36a3f129b4e5ac9b05..a682333f89bf016e44d398ca2ed9a6c5777392c9 100644 (file)
@@ -30,7 +30,6 @@
 #include <pakfire/logging.h>
 #include <pakfire/package.h>
 #include <pakfire/pakfire.h>
-#include <pakfire/private.h>
 #include <pakfire/string.h>
 #include <pakfire/util.h>
 
@@ -64,7 +63,7 @@ static const struct pakfire_rich_operation {
 /*
        This function can compare package versions without a Pakfire instance initialized.
 */
-PAKFIRE_EXPORT int pakfire_static_version_compare(const char* evr1, const char* evr2) {
+int pakfire_static_version_compare(const char* evr1, const char* evr2) {
        Pool* pool = NULL;
        int r;
 
similarity index 98%
rename from src/libpakfire/digest.c
rename to src/pakfire/digest.c
index 55ae58ed1be2838a923aba2a65d3c71a1f0dc718..acbe87eecad864c8f8d289cc4a834bb467e344a6 100644 (file)
@@ -30,7 +30,6 @@
 #include <pakfire/hex.h>
 #include <pakfire/logging.h>
 #include <pakfire/pakfire.h>
-#include <pakfire/private.h>
 #include <pakfire/util.h>
 
 static const struct _pakfire_digest_name {
@@ -52,7 +51,7 @@ static const struct _pakfire_digest_name {
        { NULL, PAKFIRE_DIGEST_UNDEFINED, },
 };
 
-PAKFIRE_EXPORT const char* pakfire_digest_name(const enum pakfire_digest_types type) {
+const char* pakfire_digest_name(const enum pakfire_digest_types type) {
        for (const struct _pakfire_digest_name* n = PAKFIRE_DIGEST_NAMES; n->name; n++) {
                if (n->type == type)
                        return n->name;
@@ -61,7 +60,7 @@ PAKFIRE_EXPORT const char* pakfire_digest_name(const enum pakfire_digest_types t
        return NULL;
 }
 
-PAKFIRE_EXPORT int pakfire_digest_get_by_name(const char* name) {
+int pakfire_digest_get_by_name(const char* name) {
        // Check that name is not NULL
        if (!name) {
                errno = EINVAL;
@@ -326,7 +325,7 @@ int pakfire_digests_compute_from_file(struct pakfire_ctx* ctx,
        EVP_MD_CTX* blake2s256_ctx = NULL;
        EVP_MD_CTX* sha2_512_ctx = NULL;
        EVP_MD_CTX* sha2_256_ctx = NULL;
-       char buffer[PAKFIRE_BUFFER_SIZE];
+       char buffer[65536];
        int r = 1;
 
        // Check if any digests have been computed before and select only those that we need
similarity index 99%
rename from src/libpakfire/dist.c
rename to src/pakfire/dist.c
index 1dbbcd9a113e82f34cdabee59e277bb7b791e93f..e390ab3f9587fc9cfe98609b5686576f7a3ef174 100644 (file)
@@ -36,7 +36,6 @@
 #include <pakfire/pakfire.h>
 #include <pakfire/parser.h>
 #include <pakfire/path.h>
-#include <pakfire/private.h>
 #include <pakfire/repo.h>
 #include <pakfire/string.h>
 #include <pakfire/util.h>
@@ -448,7 +447,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_dist(struct pakfire* pakfire, const char* path,
+int pakfire_dist(struct pakfire* pakfire, const char* path,
                const char* target, char** result) {
        struct pakfire_parser* makefile;
        struct pakfire_parser_error* error = NULL;
similarity index 100%
rename from src/libpakfire/elf.c
rename to src/pakfire/elf.c
similarity index 100%
rename from src/libpakfire/env.c
rename to src/pakfire/env.c
similarity index 100%
rename from src/libpakfire/fhs.c
rename to src/pakfire/fhs.c
similarity index 93%
rename from src/libpakfire/file.c
rename to src/pakfire/file.c
index 525b1ada631cd3c59e914bb120322eea98b57a2d..d2e7e8048db5635d8d9e906d6ed454bdbe193a6e 100644 (file)
@@ -43,7 +43,6 @@
 #include <pakfire/logging.h>
 #include <pakfire/pakfire.h>
 #include <pakfire/path.h>
-#include <pakfire/private.h>
 #include <pakfire/string.h>
 #include <pakfire/util.h>
 
@@ -377,7 +376,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_file_create(struct pakfire_file** file,
+int pakfire_file_create(struct pakfire_file** file,
                struct pakfire* pakfire, const char* path) {
        struct pakfire_file* f = NULL;
        int r = 0;
@@ -545,13 +544,13 @@ static void pakfire_file_free(struct pakfire_file* file) {
        free(file);
 }
 
-PAKFIRE_EXPORT struct pakfire_file* pakfire_file_ref(struct pakfire_file* file) {
+struct pakfire_file* pakfire_file_ref(struct pakfire_file* file) {
        file->nrefs++;
 
        return file;
 }
 
-PAKFIRE_EXPORT struct pakfire_file* pakfire_file_unref(struct pakfire_file* file) {
+struct pakfire_file* pakfire_file_unref(struct pakfire_file* file) {
        if (--file->nrefs > 0)
                return file;
 
@@ -756,7 +755,7 @@ ERROR:
        return NULL;
 }
 
-PAKFIRE_EXPORT int pakfire_file_cmp(struct pakfire_file* file1, struct pakfire_file* file2) {
+int pakfire_file_cmp(struct pakfire_file* file1, struct pakfire_file* file2) {
        const char* path1 = pakfire_file_get_path(file1);
        const char* path2 = pakfire_file_get_path(file2);
 
@@ -767,11 +766,11 @@ const char* pakfire_file_get_abspath(struct pakfire_file* file) {
        return archive_entry_sourcepath(file->entry);
 }
 
-PAKFIRE_EXPORT const char* pakfire_file_get_path(struct pakfire_file* file) {
+const char* pakfire_file_get_path(struct pakfire_file* file) {
        return archive_entry_pathname(file->entry);
 }
 
-PAKFIRE_EXPORT int pakfire_file_set_path(struct pakfire_file* file, const char* path) {
+int pakfire_file_set_path(struct pakfire_file* file, const char* path) {
        char buffer[PATH_MAX];
        int r = 0;
 
@@ -802,91 +801,91 @@ PAKFIRE_EXPORT int pakfire_file_set_path(struct pakfire_file* file, const char*
        return 0;
 }
 
-PAKFIRE_EXPORT const char* pakfire_file_get_hardlink(struct pakfire_file* file) {
+const char* pakfire_file_get_hardlink(struct pakfire_file* file) {
        return archive_entry_hardlink(file->entry);
 }
 
-PAKFIRE_EXPORT void pakfire_file_set_hardlink(struct pakfire_file* file, const char* link) {
+void pakfire_file_set_hardlink(struct pakfire_file* file, const char* link) {
        archive_entry_set_hardlink(file->entry, link);
 }
 
-PAKFIRE_EXPORT const char* pakfire_file_get_symlink(struct pakfire_file* file) {
+const char* pakfire_file_get_symlink(struct pakfire_file* file) {
        return archive_entry_symlink(file->entry);
 }
 
-PAKFIRE_EXPORT void pakfire_file_set_symlink(struct pakfire_file* file, const char* link) {
+void pakfire_file_set_symlink(struct pakfire_file* file, const char* link) {
        archive_entry_set_symlink(file->entry, link);
 }
 
-PAKFIRE_EXPORT nlink_t pakfire_file_get_nlink(struct pakfire_file* file) {
+nlink_t pakfire_file_get_nlink(struct pakfire_file* file) {
        return archive_entry_nlink(file->entry);
 }
 
-PAKFIRE_EXPORT void pakfire_file_set_nlink(struct pakfire_file* file, const nlink_t nlink) {
+void pakfire_file_set_nlink(struct pakfire_file* file, const nlink_t nlink) {
        archive_entry_set_nlink(file->entry, nlink);
 }
 
-PAKFIRE_EXPORT ino_t pakfire_file_get_inode(struct pakfire_file* file) {
+ino_t pakfire_file_get_inode(struct pakfire_file* file) {
        return archive_entry_ino64(file->entry);
 }
 
-PAKFIRE_EXPORT void pakfire_file_set_inode(struct pakfire_file* file, const ino_t ino) {
+void pakfire_file_set_inode(struct pakfire_file* file, const ino_t ino) {
        archive_entry_set_ino64(file->entry, ino);
 }
 
-PAKFIRE_EXPORT dev_t pakfire_file_get_dev(struct pakfire_file* file) {
+dev_t pakfire_file_get_dev(struct pakfire_file* file) {
        return archive_entry_dev(file->entry);
 }
 
-PAKFIRE_EXPORT void pakfire_file_set_dev(struct pakfire_file* file, const dev_t dev) {
+void pakfire_file_set_dev(struct pakfire_file* file, const dev_t dev) {
        archive_entry_set_dev(file->entry, dev);
 }
 
-PAKFIRE_EXPORT int pakfire_file_get_type(struct pakfire_file* file) {
+int pakfire_file_get_type(struct pakfire_file* file) {
        return archive_entry_filetype(file->entry);
 }
 
-PAKFIRE_EXPORT off_t pakfire_file_get_size(struct pakfire_file* file) {
+off_t pakfire_file_get_size(struct pakfire_file* file) {
        return archive_entry_size(file->entry);
 }
 
-PAKFIRE_EXPORT void pakfire_file_set_size(struct pakfire_file* file, off_t size) {
+void pakfire_file_set_size(struct pakfire_file* file, off_t size) {
        archive_entry_set_size(file->entry, size);
 }
 
-PAKFIRE_EXPORT const char* pakfire_file_get_uname(struct pakfire_file* file) {
+const char* pakfire_file_get_uname(struct pakfire_file* file) {
        return archive_entry_uname(file->entry);
 }
 
-PAKFIRE_EXPORT int pakfire_file_set_uname(struct pakfire_file* file, const char* uname) {
+int pakfire_file_set_uname(struct pakfire_file* file, const char* uname) {
        archive_entry_set_uname(file->entry, uname);
 
        return 0;
 }
 
-PAKFIRE_EXPORT const char* pakfire_file_get_gname(struct pakfire_file* file) {
+const char* pakfire_file_get_gname(struct pakfire_file* file) {
        return archive_entry_gname(file->entry);
 }
 
-PAKFIRE_EXPORT int pakfire_file_set_gname(struct pakfire_file* file, const char* gname) {
+int pakfire_file_set_gname(struct pakfire_file* file, const char* gname) {
        archive_entry_set_gname(file->entry, gname);
 
        return 0;
 }
 
-PAKFIRE_EXPORT mode_t pakfire_file_get_mode(struct pakfire_file* file) {
+mode_t pakfire_file_get_mode(struct pakfire_file* file) {
        return archive_entry_mode(file->entry);
 }
 
-PAKFIRE_EXPORT void pakfire_file_set_mode(struct pakfire_file* file, mode_t mode) {
+void pakfire_file_set_mode(struct pakfire_file* file, mode_t mode) {
        archive_entry_set_mode(file->entry, mode);
 }
 
-PAKFIRE_EXPORT mode_t pakfire_file_get_perms(struct pakfire_file* file) {
+mode_t pakfire_file_get_perms(struct pakfire_file* file) {
        return archive_entry_perm(file->entry);
 }
 
-PAKFIRE_EXPORT void pakfire_file_set_perms(struct pakfire_file* file, const mode_t perms) {
+void pakfire_file_set_perms(struct pakfire_file* file, const mode_t perms) {
        archive_entry_set_mode(file->entry, pakfire_file_get_type(file) | perms);
 }
 
@@ -894,19 +893,19 @@ int pakfire_file_is_executable(struct pakfire_file* file) {
        return pakfire_file_get_mode(file) & (S_IXUSR|S_IXGRP|S_IXOTH);
 }
 
-PAKFIRE_EXPORT time_t pakfire_file_get_ctime(struct pakfire_file* file) {
+time_t pakfire_file_get_ctime(struct pakfire_file* file) {
        return archive_entry_ctime(file->entry);
 }
 
-PAKFIRE_EXPORT void pakfire_file_set_ctime(struct pakfire_file* file, time_t time) {
+void pakfire_file_set_ctime(struct pakfire_file* file, time_t time) {
        archive_entry_set_ctime(file->entry, time, 0);
 }
 
-PAKFIRE_EXPORT time_t pakfire_file_get_mtime(struct pakfire_file* file) {
+time_t pakfire_file_get_mtime(struct pakfire_file* file) {
        return archive_entry_mtime(file->entry);
 }
 
-PAKFIRE_EXPORT void pakfire_file_set_mtime(struct pakfire_file* file, time_t time) {
+void pakfire_file_set_mtime(struct pakfire_file* file, time_t time) {
        archive_entry_set_mtime(file->entry, time, 0);
 }
 
@@ -924,7 +923,7 @@ int pakfire_file_has_payload(struct pakfire_file* file) {
        return pakfire_file_get_size(file) > 0;
 }
 
-PAKFIRE_EXPORT const unsigned char* pakfire_file_get_digest(
+const unsigned char* pakfire_file_get_digest(
                struct pakfire_file* file, const enum pakfire_digest_types type, size_t* length) {
 
        switch (type) {
@@ -989,7 +988,7 @@ PAKFIRE_EXPORT const unsigned char* pakfire_file_get_digest(
        return NULL;
 }
 
-PAKFIRE_EXPORT int pakfire_file_set_digest(struct pakfire_file* file,
+int pakfire_file_set_digest(struct pakfire_file* file,
                const enum pakfire_digest_types type, const unsigned char* digest, const size_t length) {
        if (!digest)
                return -EINVAL;
@@ -1034,14 +1033,14 @@ PAKFIRE_EXPORT int pakfire_file_set_digest(struct pakfire_file* file,
        return 0;
 }
 
-PAKFIRE_EXPORT int pakfire_file_has_caps(struct pakfire_file* file) {
+int pakfire_file_has_caps(struct pakfire_file* file) {
        if (file->caps)
                return 1;
 
        return 0;
 }
 
-PAKFIRE_EXPORT char* pakfire_file_get_caps(struct pakfire_file* file) {
+char* pakfire_file_get_caps(struct pakfire_file* file) {
        char* copy = NULL;
        char* text = NULL;
        ssize_t length = 0;
@@ -1327,7 +1326,7 @@ int pakfire_file_detect_mimetype(struct pakfire_file* file) {
        return pakfire_file_set_mimetype(file, mimetype);
 }
 
-PAKFIRE_EXPORT const char* pakfire_file_get_mimetype(struct pakfire_file* file) {
+const char* pakfire_file_get_mimetype(struct pakfire_file* file) {
        // Return nothing on an empty mimetype
        if (!*file->mimetype)
                return NULL;
@@ -1335,7 +1334,7 @@ PAKFIRE_EXPORT const char* pakfire_file_get_mimetype(struct pakfire_file* file)
        return file->mimetype;
 }
 
-PAKFIRE_EXPORT int pakfire_file_set_mimetype(
+int pakfire_file_set_mimetype(
                struct pakfire_file* file, const char* mimetype) {
        // Store the value
        return pakfire_string_set(file->mimetype, mimetype);
@@ -1754,7 +1753,7 @@ int pakfire_file_verify(struct pakfire_file* file, int* status) {
        return 0;
 }
 
-PAKFIRE_EXPORT int pakfire_file_matches(struct pakfire_file* file, const char* pattern) {
+int pakfire_file_matches(struct pakfire_file* file, const char* pattern) {
        // Don't match on no pattern
        if (!pattern)
                return 0;
similarity index 95%
rename from src/libpakfire/filelist.c
rename to src/pakfire/filelist.c
index b4f93ebd88e9f862cd2928b9f8df08cac57de2e2..ccbfeb82f9f18cfbe972ed766e2d3cbbd3d982d8 100644 (file)
@@ -31,7 +31,6 @@
 #include <pakfire/logging.h>
 #include <pakfire/pakfire.h>
 #include <pakfire/path.h>
-#include <pakfire/private.h>
 #include <pakfire/progress.h>
 #include <pakfire/string.h>
 #include <pakfire/util.h>
@@ -45,7 +44,7 @@ struct pakfire_filelist {
        unsigned int num_files;
 };
 
-PAKFIRE_EXPORT int pakfire_filelist_create(struct pakfire_filelist** list, struct pakfire* pakfire) {
+int pakfire_filelist_create(struct pakfire_filelist** list, struct pakfire* pakfire) {
        struct pakfire_filelist* l = NULL;
 
        // Allocate a new object
@@ -77,13 +76,13 @@ static void pakfire_filelist_free(struct pakfire_filelist* list) {
        free(list);
 }
 
-PAKFIRE_EXPORT struct pakfire_filelist* pakfire_filelist_ref(struct pakfire_filelist* list) {
+struct pakfire_filelist* pakfire_filelist_ref(struct pakfire_filelist* list) {
        list->nrefs++;
 
        return list;
 }
 
-PAKFIRE_EXPORT struct pakfire_filelist* pakfire_filelist_unref(struct pakfire_filelist* list) {
+struct pakfire_filelist* pakfire_filelist_unref(struct pakfire_filelist* list) {
        if (--list->nrefs > 0)
                return list;
 
@@ -91,7 +90,7 @@ PAKFIRE_EXPORT struct pakfire_filelist* pakfire_filelist_unref(struct pakfire_fi
        return NULL;
 }
 
-PAKFIRE_EXPORT size_t pakfire_filelist_length(struct pakfire_filelist* list) {
+size_t pakfire_filelist_length(struct pakfire_filelist* list) {
        return list->num_files;
 }
 
@@ -104,11 +103,11 @@ size_t pakfire_filelist_total_size(struct pakfire_filelist* list) {
        return size;
 }
 
-PAKFIRE_EXPORT int pakfire_filelist_is_empty(struct pakfire_filelist* list) {
+int pakfire_filelist_is_empty(struct pakfire_filelist* list) {
        return list->num_files == 0;
 }
 
-PAKFIRE_EXPORT void pakfire_filelist_clear(struct pakfire_filelist* list) {
+void pakfire_filelist_clear(struct pakfire_filelist* list) {
        if (list->files) {
                for (unsigned int i = 0; i < list->num_files; i++)
                        pakfire_file_unref(list->files[i]);
@@ -122,7 +121,7 @@ PAKFIRE_EXPORT void pakfire_filelist_clear(struct pakfire_filelist* list) {
        }
 }
 
-PAKFIRE_EXPORT struct pakfire_file* pakfire_filelist_get(struct pakfire_filelist* list, size_t index) {
+struct pakfire_file* pakfire_filelist_get(struct pakfire_filelist* list, size_t index) {
        // Check that index is in range
        if (index >= list->num_files) {
                errno = ERANGE;
@@ -172,7 +171,7 @@ static int pakfire_filelist_search(struct pakfire_filelist* list, struct pakfire
        return lo;
 }
 
-PAKFIRE_EXPORT int pakfire_filelist_add(struct pakfire_filelist* list, struct pakfire_file* file) {
+int pakfire_filelist_add(struct pakfire_filelist* list, struct pakfire_file* file) {
        // Do not do anything if the file is already on the list
        if (pakfire_filelist_has_file(list, file) >= 0)
                return 0;
similarity index 100%
rename from src/libpakfire/hex.c
rename to src/pakfire/hex.c
similarity index 100%
rename from src/libpakfire/jail.c
rename to src/pakfire/jail.c
similarity index 100%
rename from src/libpakfire/job.c
rename to src/pakfire/job.c
similarity index 96%
rename from src/libpakfire/key.c
rename to src/pakfire/key.c
index 3bd6625ff88466eb1fd331ff4944d867e3ccfe05..003fca56c51f3c6fe7191ae8779c3e8267ddc77d 100644 (file)
@@ -39,7 +39,6 @@
 #include <pakfire/key.h>
 #include <pakfire/logging.h>
 #include <pakfire/pakfire.h>
-#include <pakfire/private.h>
 #include <pakfire/string.h>
 #include <pakfire/util.h>
 
@@ -162,13 +161,13 @@ static void pakfire_key_free(struct pakfire_key* key) {
        free(key);
 }
 
-PAKFIRE_EXPORT struct pakfire_key* pakfire_key_ref(struct pakfire_key* key) {
+struct pakfire_key* pakfire_key_ref(struct pakfire_key* key) {
        ++key->nrefs;
 
        return key;
 }
 
-PAKFIRE_EXPORT struct pakfire_key* pakfire_key_unref(struct pakfire_key* key) {
+struct pakfire_key* pakfire_key_unref(struct pakfire_key* key) {
        if (--key->nrefs > 0)
                return key;
 
@@ -176,11 +175,11 @@ PAKFIRE_EXPORT struct pakfire_key* pakfire_key_unref(struct pakfire_key* key) {
        return NULL;
 }
 
-PAKFIRE_EXPORT pakfire_key_id* pakfire_key_get_id(struct pakfire_key* key) {
+pakfire_key_id* pakfire_key_get_id(struct pakfire_key* key) {
        return &key->id;
 }
 
-PAKFIRE_EXPORT const char* pakfire_key_get_algo(struct pakfire_key* key) {
+const char* pakfire_key_get_algo(struct pakfire_key* key) {
        switch (key->algo) {
                case PAKFIRE_KEY_ALGO_ED25519:
                        return "Ed255919";
@@ -192,11 +191,11 @@ PAKFIRE_EXPORT const char* pakfire_key_get_algo(struct pakfire_key* key) {
        return NULL;
 }
 
-PAKFIRE_EXPORT const char* pakfire_key_get_comment(struct pakfire_key* key) {
+const char* pakfire_key_get_comment(struct pakfire_key* key) {
        return key->comment;
 }
 
-PAKFIRE_EXPORT int pakfire_key_generate(struct pakfire_key** key, struct pakfire_ctx* ctx,
+int pakfire_key_generate(struct pakfire_key** key, struct pakfire_ctx* ctx,
                const pakfire_key_algo_t algo, const char* comment) {
        EVP_PKEY* pkey = NULL;
        EVP_PKEY_CTX* pctx = NULL;
@@ -389,7 +388,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_key_import(struct pakfire_key** key,
+int pakfire_key_import(struct pakfire_key** key,
                struct pakfire_ctx* ctx, FILE* f) {
        void* buffer = NULL;
        size_t buffer_length = 0;
@@ -650,7 +649,7 @@ static int pakfire_key_export_public_key(struct pakfire_key* key,
        return 0;
 }
 
-PAKFIRE_EXPORT int pakfire_key_export(struct pakfire_key* key, FILE* f,
+int pakfire_key_export(struct pakfire_key* key, FILE* f,
                const pakfire_key_export_mode_t mode) {
        struct pakfire_key_public_key public_key = { 0 };
        struct pakfire_key_private_key private_key = { 0 };
@@ -740,7 +739,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT char* pakfire_key_dump(struct pakfire_key* key) {
+char* pakfire_key_dump(struct pakfire_key* key) {
        char* buffer = NULL;
        FILE* f = NULL;
        int fd = -EBADF;
@@ -872,7 +871,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_key_sign(struct pakfire_key* key,
+int pakfire_key_sign(struct pakfire_key* key,
                FILE* f, const void* data, const size_t length, const char* comment) {
        struct pakfire_key_signature signature = { 0 };
        char* s = NULL;
@@ -1072,7 +1071,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_key_verify(struct pakfire_key* key, FILE* f,
+int pakfire_key_verify(struct pakfire_key* key, FILE* f,
                const void* data, const size_t length) {
        struct pakfire_key_signature signature = { 0 };
        int r;
similarity index 100%
rename from src/libpakfire/linter.c
rename to src/pakfire/linter.c
similarity index 92%
rename from src/libpakfire/logging.c
rename to src/pakfire/logging.c
index f6bb7856debbb517ac9a0e3f8073830ed0585150..b989bf4602fd169f659b9ceb2829b4155e53eacb 100644 (file)
@@ -26,9 +26,8 @@
 #include <systemd/sd-journal.h>
 
 #include <pakfire/logging.h>
-#include <pakfire/private.h>
 
-PAKFIRE_EXPORT void pakfire_log_stderr(void* data, int priority, const char* file,
+void pakfire_log_stderr(void* data, int priority, const char* file,
                int line, const char* fn, const char* format, va_list args) {
        fprintf(stderr, "pakfire: ");
 
@@ -39,7 +38,7 @@ PAKFIRE_EXPORT void pakfire_log_stderr(void* data, int priority, const char* fil
        vfprintf(stderr, format, args);
 }
 
-PAKFIRE_EXPORT void pakfire_log_syslog(void* data, int priority, const char* file,
+void pakfire_log_syslog(void* data, int priority, const char* file,
                int line, const char* fn, const char* format, va_list args) {
        char* buffer = NULL;
        int r;
similarity index 100%
rename from src/libpakfire/mirror.c
rename to src/pakfire/mirror.c
similarity index 100%
rename from src/libpakfire/mount.c
rename to src/pakfire/mount.c
similarity index 100%
rename from src/libpakfire/os.c
rename to src/pakfire/os.c
similarity index 95%
rename from src/libpakfire/package.c
rename to src/pakfire/package.c
index 432892e04a1effe863b323fbb80de1085eb9d038..4d5916a9224d96523b78a974b6b37f8256ee8a9b 100644 (file)
@@ -45,7 +45,6 @@
 #include <pakfire/package.h>
 #include <pakfire/pakfire.h>
 #include <pakfire/path.h>
-#include <pakfire/private.h>
 #include <pakfire/repo.h>
 #include <pakfire/string.h>
 #include <pakfire/transaction.h>
@@ -184,7 +183,7 @@ int pakfire_package_create_from_solvable(struct pakfire_package** package,
        return 0;
 }
 
-PAKFIRE_EXPORT int pakfire_package_create(struct pakfire_package** package,
+int pakfire_package_create(struct pakfire_package** package,
                struct pakfire* pakfire, struct pakfire_repo* repo,
                const char* name, const char* evr, const char* arch) {
        struct pakfire_repo* dummy = NULL;
@@ -273,13 +272,13 @@ static void pakfire_package_free(struct pakfire_package* pkg) {
        free(pkg);
 }
 
-PAKFIRE_EXPORT struct pakfire_package* pakfire_package_ref(struct pakfire_package* pkg) {
+struct pakfire_package* pakfire_package_ref(struct pakfire_package* pkg) {
        pkg->nrefs++;
 
        return pkg;
 }
 
-PAKFIRE_EXPORT struct pakfire_package* pakfire_package_unref(struct pakfire_package* pkg) {
+struct pakfire_package* pakfire_package_unref(struct pakfire_package* pkg) {
        if (--pkg->nrefs > 0)
                return pkg;
 
@@ -287,15 +286,15 @@ PAKFIRE_EXPORT struct pakfire_package* pakfire_package_unref(struct pakfire_pack
        return NULL;
 }
 
-PAKFIRE_EXPORT struct pakfire* pakfire_package_get_pakfire(struct pakfire_package* pkg) {
+struct pakfire* pakfire_package_get_pakfire(struct pakfire_package* pkg) {
        return pakfire_ref(pkg->pakfire);
 }
 
-PAKFIRE_EXPORT int pakfire_package_eq(struct pakfire_package* pkg1, struct pakfire_package* pkg2) {
+int pakfire_package_eq(struct pakfire_package* pkg1, struct pakfire_package* pkg2) {
        return pkg1->id == pkg2->id;
 }
 
-PAKFIRE_EXPORT int pakfire_package_cmp(struct pakfire_package* pkg1, struct pakfire_package* pkg2) {
+int pakfire_package_cmp(struct pakfire_package* pkg1, struct pakfire_package* pkg2) {
        Pool* pool = pakfire_get_solv_pool(pkg1->pakfire);
 
        Solvable* s1 = get_solvable(pkg1);
@@ -335,7 +334,7 @@ PAKFIRE_EXPORT int pakfire_package_cmp(struct pakfire_package* pkg1, struct pakf
        return strcmp(str1, str2);
 }
 
-PAKFIRE_EXPORT int pakfire_package_evr_cmp(struct pakfire_package* pkg1, struct pakfire_package* pkg2) {
+int pakfire_package_evr_cmp(struct pakfire_package* pkg1, struct pakfire_package* pkg2) {
        Pool* pool = pakfire_get_solv_pool(pkg1->pakfire);
 
        Solvable* s1 = get_solvable(pkg1);
@@ -344,7 +343,7 @@ PAKFIRE_EXPORT int pakfire_package_evr_cmp(struct pakfire_package* pkg1, struct
        return pool_evrcmp(pool, s1->evr, s2->evr, EVRCMP_COMPARE);
 }
 
-PAKFIRE_EXPORT unsigned int pakfire_package_id(struct pakfire_package* pkg) {
+unsigned int pakfire_package_id(struct pakfire_package* pkg) {
        return pkg->id;
 }
 
@@ -456,7 +455,7 @@ static int pakfire_package_make_cache_path(struct pakfire_package* pkg) {
        return pakfire_cache_path(pkg->pakfire, pkg->cache_path, "%s/%s", uuid, filename);
 }
 
-PAKFIRE_EXPORT void pakfire_package_unset(struct pakfire_package* pkg,
+void pakfire_package_unset(struct pakfire_package* pkg,
                const enum pakfire_package_key key) {
        Id id = ID_NULL;
 
@@ -595,7 +594,7 @@ PAKFIRE_EXPORT void pakfire_package_unset(struct pakfire_package* pkg,
        solvable_unset(s, id);
 }
 
-PAKFIRE_EXPORT char** pakfire_package_get_strings(
+char** pakfire_package_get_strings(
                struct pakfire_package* pkg, const enum pakfire_package_key key) {
        char** ret = NULL;
        const char* str = NULL;
@@ -651,7 +650,7 @@ ERROR:
        return ret;
 }
 
-PAKFIRE_EXPORT int pakfire_package_set_strings(struct pakfire_package* pkg,
+int pakfire_package_set_strings(struct pakfire_package* pkg,
                const enum pakfire_package_key key, const char** values) {
        int r;
 
@@ -712,7 +711,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT const char* pakfire_package_get_string(
+const char* pakfire_package_get_string(
                struct pakfire_package* pkg, const enum pakfire_package_key key) {
        const char* ret = NULL;
        int r;
@@ -864,7 +863,7 @@ PAKFIRE_EXPORT const char* pakfire_package_get_string(
        return ret;
 }
 
-PAKFIRE_EXPORT int pakfire_package_set_string(
+int pakfire_package_set_string(
                struct pakfire_package* pkg, const enum pakfire_package_key key, const char* value) {
        char basename[PATH_MAX];
        char dirname[PATH_MAX];
@@ -1035,7 +1034,7 @@ PAKFIRE_EXPORT int pakfire_package_set_string(
        return 0;
 }
 
-PAKFIRE_EXPORT int pakfire_package_add_string(struct pakfire_package* pkg,
+int pakfire_package_add_string(struct pakfire_package* pkg,
                const enum pakfire_package_key key, const char* value) {
        Id key_id = ID_NULL;
        Id value_id = ID_NULL;
@@ -1069,7 +1068,7 @@ PAKFIRE_EXPORT int pakfire_package_add_string(struct pakfire_package* pkg,
        return 0;
 }
 
-PAKFIRE_EXPORT int pakfire_package_get_uuid(struct pakfire_package* pkg,
+int pakfire_package_get_uuid(struct pakfire_package* pkg,
                const enum pakfire_package_key key, uuid_t uuid) {
        const char* buffer = NULL;
        int r;
@@ -1098,7 +1097,7 @@ PAKFIRE_EXPORT int pakfire_package_get_uuid(struct pakfire_package* pkg,
        }
 }
 
-PAKFIRE_EXPORT int pakfire_package_set_uuid(struct pakfire_package* pkg,
+int pakfire_package_set_uuid(struct pakfire_package* pkg,
                const enum pakfire_package_key key, const uuid_t uuid) {
        char buffer[UUID_STR_LEN];
 
@@ -1117,7 +1116,7 @@ PAKFIRE_EXPORT int pakfire_package_set_uuid(struct pakfire_package* pkg,
        }
 }
 
-PAKFIRE_EXPORT unsigned long long pakfire_package_get_num(struct pakfire_package* pkg,
+unsigned long long pakfire_package_get_num(struct pakfire_package* pkg,
                const enum pakfire_package_key key, unsigned long long notfound) {
        Id id = ID_NULL;
 
@@ -1155,7 +1154,7 @@ PAKFIRE_EXPORT unsigned long long pakfire_package_get_num(struct pakfire_package
        return solvable_lookup_num(s, id, notfound);
 }
 
-PAKFIRE_EXPORT int pakfire_package_set_num(struct pakfire_package* pkg,
+int pakfire_package_set_num(struct pakfire_package* pkg,
                const enum pakfire_package_key key, unsigned long long num) {
        Id id = ID_NULL;
 
@@ -1209,7 +1208,7 @@ static enum pakfire_digest_types pakfire_package_id2digest(Id id) {
        return 0;
 }
 
-PAKFIRE_EXPORT const unsigned char* pakfire_package_get_digest(
+const unsigned char* pakfire_package_get_digest(
                struct pakfire_package* pkg, enum pakfire_digest_types* type, size_t* length) {
        Solvable* s = get_solvable(pkg);
        Id id = 0;
@@ -1230,7 +1229,7 @@ PAKFIRE_EXPORT const unsigned char* pakfire_package_get_digest(
        return checksum;
 }
 
-PAKFIRE_EXPORT int pakfire_package_set_digest(struct pakfire_package* pkg,
+int pakfire_package_set_digest(struct pakfire_package* pkg,
                enum pakfire_digest_types type, const unsigned char* digest, const size_t length) {
        Solvable* s = get_solvable(pkg);
        Pool* pool = s->repo->pool;
@@ -1281,7 +1280,7 @@ int pakfire_package_is_installed(struct pakfire_package* pkg) {
        return pool->installed == s->repo;
 }
 
-PAKFIRE_EXPORT size_t pakfire_package_get_size(struct pakfire_package* pkg) {
+size_t pakfire_package_get_size(struct pakfire_package* pkg) {
        if (pakfire_package_is_installed(pkg))
                return pakfire_package_get_num(pkg, PAKFIRE_PKG_INSTALLSIZE, 0);
 
@@ -1319,7 +1318,7 @@ END:
 
 // Dependencies
 
-PAKFIRE_EXPORT char** pakfire_package_get_deps(struct pakfire_package* pkg,
+char** pakfire_package_get_deps(struct pakfire_package* pkg,
                const enum pakfire_package_key key) {
        Solvable* s = get_solvable(pkg);
        char** ret = NULL;
@@ -1388,7 +1387,7 @@ int pakfire_package_add_dep(struct pakfire_package* pkg,
        return pakfire_package_add_depid(pkg, key, id);
 }
 
-PAKFIRE_EXPORT int pakfire_package_get_reverse_requires(struct pakfire_package* pkg,
+int pakfire_package_get_reverse_requires(struct pakfire_package* pkg,
                struct pakfire_packagelist* list) {
        Queue matches;
        queue_init(&matches);
@@ -1492,7 +1491,7 @@ int pakfire_package_matches_dep(struct pakfire_package* pkg,
        return solvable_matchesdep(s, id, depid, marker);
 }
 
-PAKFIRE_EXPORT struct pakfire_repo* pakfire_package_get_repo(struct pakfire_package* pkg) {
+struct pakfire_repo* pakfire_package_get_repo(struct pakfire_package* pkg) {
        if (!pkg->repo) {
                Solvable* s = get_solvable(pkg);
 
@@ -1577,7 +1576,7 @@ static int pakfire_sort_dependencies(const void* p1, const void* p2) {
        return strcmp(dep1, dep2);
 }
 
-PAKFIRE_EXPORT char* pakfire_package_dump(struct pakfire_package* pkg, int flags) {
+char* pakfire_package_dump(struct pakfire_package* pkg, int flags) {
        char* string = NULL;
 
        // Name
@@ -1816,7 +1815,7 @@ PAKFIRE_EXPORT char* pakfire_package_dump(struct pakfire_package* pkg, int flags
        return string;
 }
 
-PAKFIRE_EXPORT struct pakfire_archive* pakfire_package_get_archive(struct pakfire_package* pkg) {
+struct pakfire_archive* pakfire_package_get_archive(struct pakfire_package* pkg) {
        struct pakfire_archive* archive = NULL;
        struct pakfire_repo* repo = NULL;
        const char* path = NULL;
@@ -1919,7 +1918,7 @@ static int pakfire_package_fetch_filelist(struct pakfire_package* pkg, struct pa
        return search.r;
 }
 
-PAKFIRE_EXPORT struct pakfire_filelist* pakfire_package_get_filelist(struct pakfire_package* pkg) {
+struct pakfire_filelist* pakfire_package_get_filelist(struct pakfire_package* pkg) {
        struct pakfire_filelist* filelist = NULL;
 
        // Create a new filelist
@@ -1993,7 +1992,7 @@ static int __pakfire_package_set_filelist(
        return pakfire_package_append_file(pkg, path);
 }
 
-PAKFIRE_EXPORT int pakfire_package_set_filelist(
+int pakfire_package_set_filelist(
                struct pakfire_package* pkg, struct pakfire_filelist* filelist) {
        return pakfire_filelist_walk(filelist, __pakfire_package_set_filelist, pkg, 0, NULL);
 }
@@ -2496,7 +2495,7 @@ ERROR:
        return md;
 }
 
-PAKFIRE_EXPORT int pakfire_package_installcheck(struct pakfire_package* pkg,
+int pakfire_package_installcheck(struct pakfire_package* pkg,
                char** problem, int flags) {
        struct pakfire_transaction* transaction = NULL;
        char* p = NULL;
similarity index 88%
rename from src/libpakfire/packagelist.c
rename to src/pakfire/packagelist.c
index 7d46968b8d829cb7a05ca49319d283200d4c6b5d..3865c30a85b86687198d505fad57121dd713f0c4 100644 (file)
@@ -28,7 +28,6 @@
 #include <pakfire/package.h>
 #include <pakfire/packagelist.h>
 #include <pakfire/pakfire.h>
-#include <pakfire/private.h>
 
 struct pakfire_packagelist_element {
        TAILQ_ENTRY(pakfire_packagelist_element) nodes;
@@ -68,7 +67,7 @@ static void pakfire_packagelist_free(struct pakfire_packagelist* list) {
        free(list);
 }
 
-PAKFIRE_EXPORT int pakfire_packagelist_create(
+int pakfire_packagelist_create(
                struct pakfire_packagelist** list, struct pakfire_ctx* ctx) {
        struct pakfire_packagelist* l = calloc(1, sizeof(*l));
        if (!l)
@@ -87,13 +86,13 @@ PAKFIRE_EXPORT int pakfire_packagelist_create(
        return 0;
 }
 
-PAKFIRE_EXPORT struct pakfire_packagelist* pakfire_packagelist_ref(struct pakfire_packagelist* list) {
+struct pakfire_packagelist* pakfire_packagelist_ref(struct pakfire_packagelist* list) {
        list->nrefs++;
 
        return list;
 }
 
-PAKFIRE_EXPORT struct pakfire_packagelist* pakfire_packagelist_unref(struct pakfire_packagelist* list) {
+struct pakfire_packagelist* pakfire_packagelist_unref(struct pakfire_packagelist* list) {
        if (--list->nrefs > 0)
                return list;
 
@@ -101,7 +100,7 @@ PAKFIRE_EXPORT struct pakfire_packagelist* pakfire_packagelist_unref(struct pakf
        return NULL;
 }
 
-PAKFIRE_EXPORT size_t pakfire_packagelist_length(struct pakfire_packagelist* list) {
+size_t pakfire_packagelist_length(struct pakfire_packagelist* list) {
        struct pakfire_packagelist_element* element = NULL;
        size_t size = 0;
 
@@ -111,7 +110,7 @@ PAKFIRE_EXPORT size_t pakfire_packagelist_length(struct pakfire_packagelist* lis
        return size;
 }
 
-PAKFIRE_EXPORT struct pakfire_package* pakfire_packagelist_get(struct pakfire_packagelist* list, unsigned int index) {
+struct pakfire_package* pakfire_packagelist_get(struct pakfire_packagelist* list, unsigned int index) {
        struct pakfire_packagelist_element* element = NULL;
 
        // Fetch the first element
@@ -126,7 +125,7 @@ PAKFIRE_EXPORT struct pakfire_package* pakfire_packagelist_get(struct pakfire_pa
        return pakfire_package_ref(element->pkg);
 }
 
-PAKFIRE_EXPORT int pakfire_packagelist_push(struct pakfire_packagelist* list, struct pakfire_package* pkg) {
+int pakfire_packagelist_push(struct pakfire_packagelist* list, struct pakfire_package* pkg) {
        struct pakfire_packagelist_element* element = NULL;
        struct pakfire_packagelist_element* e = NULL;
 
@@ -161,7 +160,7 @@ PAKFIRE_EXPORT int pakfire_packagelist_push(struct pakfire_packagelist* list, st
        return 0;
 }
 
-PAKFIRE_EXPORT int pakfire_packagelist_walk(struct pakfire_packagelist* list,
+int pakfire_packagelist_walk(struct pakfire_packagelist* list,
                pakfire_packagelist_walk_callback callback, void* data, int flags) {
        struct pakfire_packagelist_element* element = NULL;
        int kept_going = 0;
similarity index 96%
rename from src/libpakfire/pakfire.c
rename to src/pakfire/pakfire.c
index b22f34cc74c6c989f8002a13d34a886be959350e..13498ae713b4d617f996904435b39962a23ace33 100644 (file)
@@ -57,7 +57,6 @@
 #include <pakfire/pakfire.h>
 #include <pakfire/parser.h>
 #include <pakfire/path.h>
-#include <pakfire/private.h>
 #include <pakfire/pwd.h>
 #include <pakfire/repo.h>
 #include <pakfire/snapshot.h>
@@ -799,7 +798,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_create(struct pakfire** pakfire, struct pakfire_ctx* ctx,
+int pakfire_create(struct pakfire** pakfire, struct pakfire_ctx* ctx,
                const char* path, const char* arch, FILE* conf, int flags) {
        struct pakfire* p = NULL;
        int r;
@@ -1052,13 +1051,13 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT struct pakfire* pakfire_ref(struct pakfire* pakfire) {
+struct pakfire* pakfire_ref(struct pakfire* pakfire) {
        ++pakfire->nrefs;
 
        return pakfire;
 }
 
-PAKFIRE_EXPORT struct pakfire* pakfire_unref(struct pakfire* pakfire) {
+struct pakfire* pakfire_unref(struct pakfire* pakfire) {
        if (--pakfire->nrefs > 0)
                return pakfire;
 
@@ -1070,7 +1069,7 @@ struct pakfire_ctx* pakfire_ctx(struct pakfire* pakfire) {
        return pakfire_ctx_ref(pakfire->ctx);
 }
 
-PAKFIRE_EXPORT int pakfire_has_flag(struct pakfire* pakfire, const int flag) {
+int pakfire_has_flag(struct pakfire* pakfire, const int flag) {
        return pakfire->flags & flag;
 }
 
@@ -1081,7 +1080,7 @@ struct pakfire_config* pakfire_get_config(struct pakfire* pakfire) {
        return pakfire_config_ref(pakfire->config);
 }
 
-PAKFIRE_EXPORT const char* pakfire_get_path(struct pakfire* pakfire) {
+const char* pakfire_get_path(struct pakfire* pakfire) {
        return pakfire->path;
 }
 
@@ -1175,7 +1174,7 @@ static int __pakfire_repo_clean(struct pakfire* pakfire, struct pakfire_repo* re
        return pakfire_repo_clean(repo, flags);
 }
 
-PAKFIRE_EXPORT int pakfire_clean(struct pakfire* pakfire, int flags) {
+int pakfire_clean(struct pakfire* pakfire, int flags) {
        int r;
 
        // Clean all repositories
@@ -1204,11 +1203,11 @@ static int __pakfire_repo_refresh(struct pakfire* pakfire, struct pakfire_repo*
        return pakfire_repo_refresh(repo, flags);
 }
 
-PAKFIRE_EXPORT int pakfire_refresh(struct pakfire* pakfire, int flags) {
+int pakfire_refresh(struct pakfire* pakfire, int flags) {
        return pakfire_repo_walk(pakfire, __pakfire_repo_refresh, &flags);
 }
 
-PAKFIRE_EXPORT const char* pakfire_get_arch(struct pakfire* pakfire) {
+const char* pakfire_get_arch(struct pakfire* pakfire) {
        return pakfire->arches.nominal;
 }
 
@@ -1216,7 +1215,7 @@ const char* pakfire_get_effective_arch(struct pakfire* pakfire) {
        return pakfire->arches.effective;
 }
 
-PAKFIRE_EXPORT int pakfire_version_compare(struct pakfire* pakfire, const char* evr1, const char* evr2) {
+int pakfire_version_compare(struct pakfire* pakfire, const char* evr1, const char* evr2) {
        return pool_evrcmp_str(pakfire->pool, evr1, evr2, EVRCMP_COMPARE);
 }
 
@@ -1255,7 +1254,7 @@ void pakfire_pool_internalize(struct pakfire* pakfire) {
        pakfire->internal_flags |= PAKFIRE_POOL_READY;
 }
 
-PAKFIRE_EXPORT struct pakfire_repolist* pakfire_get_repos(struct pakfire* pakfire) {
+struct pakfire_repolist* pakfire_get_repos(struct pakfire* pakfire) {
        struct pakfire_repo* repo = NULL;
        struct pakfire_repolist* list;
 
@@ -1294,7 +1293,7 @@ ERROR:
        return NULL;
 }
 
-PAKFIRE_EXPORT struct pakfire_repo* pakfire_get_repo(struct pakfire* pakfire, const char* name) {
+struct pakfire_repo* pakfire_get_repo(struct pakfire* pakfire, const char* name) {
        Pool* pool = pakfire_get_solv_pool(pakfire);
        if (!pool)
                return NULL;
@@ -1453,7 +1452,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_whatprovides(struct pakfire* pakfire, const char* what, int flags,
+int pakfire_whatprovides(struct pakfire* pakfire, const char* what, int flags,
                struct pakfire_packagelist* list) {
        int r;
 
@@ -1484,7 +1483,7 @@ static int __pakfire_whatrequires(struct pakfire_ctx* ctx, struct pakfire_packag
        return pakfire_package_get_reverse_requires(pkg, list);
 }
 
-PAKFIRE_EXPORT int pakfire_whatrequires(struct pakfire* pakfire, const char* what, int flags,
+int pakfire_whatrequires(struct pakfire* pakfire, const char* what, int flags,
                struct pakfire_packagelist* list) {
        struct pakfire_packagelist* packages = NULL;
        int r;
@@ -1521,7 +1520,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_search(struct pakfire* pakfire, const char* what, int flags,
+int pakfire_search(struct pakfire* pakfire, const char* what, int flags,
                struct pakfire_packagelist* list) {
        const Id keys[] = {
                SOLVABLE_NAME,
@@ -1741,7 +1740,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_check(struct pakfire* pakfire, struct pakfire_filelist* errors) {
+int pakfire_check(struct pakfire* pakfire, struct pakfire_filelist* errors) {
        struct pakfire_db* db = NULL;
        int r;
 
@@ -1772,7 +1771,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_update_snapshot(struct pakfire* pakfire) {
+int pakfire_update_snapshot(struct pakfire* pakfire) {
        struct pakfire_snapshot* snapshot = NULL;
        int r;
 
similarity index 100%
rename from src/libpakfire/parse.c
rename to src/pakfire/parse.c
similarity index 100%
rename from src/libpakfire/parser.c
rename to src/pakfire/parser.c
similarity index 100%
rename from src/libpakfire/path.c
rename to src/pakfire/path.c
similarity index 95%
rename from src/libpakfire/problem.c
rename to src/pakfire/problem.c
index cc9da1bb18f69670ab7cafb80535c66bd842c04a..b4c44d86cb19bcca41b199f76cab549c2195e0a6 100644 (file)
@@ -27,7 +27,6 @@
 #include <pakfire/i18n.h>
 #include <pakfire/logging.h>
 #include <pakfire/pakfire.h>
-#include <pakfire/private.h>
 #include <pakfire/problem.h>
 #include <pakfire/solution.h>
 #include <pakfire/transaction.h>
@@ -236,13 +235,13 @@ static void pakfire_problem_free(struct pakfire_problem* problem) {
        free(problem);
 }
 
-PAKFIRE_EXPORT struct pakfire_problem* pakfire_problem_ref(struct pakfire_problem* problem) {
+struct pakfire_problem* pakfire_problem_ref(struct pakfire_problem* problem) {
        problem->nrefs++;
 
        return problem;
 }
 
-PAKFIRE_EXPORT struct pakfire_problem* pakfire_problem_unref(struct pakfire_problem* problem) {
+struct pakfire_problem* pakfire_problem_unref(struct pakfire_problem* problem) {
        if (--problem->nrefs > 0)
                return problem;
 
@@ -250,7 +249,7 @@ PAKFIRE_EXPORT struct pakfire_problem* pakfire_problem_unref(struct pakfire_prob
        return NULL;
 }
 
-PAKFIRE_EXPORT const char* pakfire_problem_to_string(struct pakfire_problem* problem) {
+const char* pakfire_problem_to_string(struct pakfire_problem* problem) {
        if (!problem->string)
                problem->string = pakfire_problem_make_string(problem);
 
@@ -265,7 +264,7 @@ struct pakfire_transaction* pakfire_problem_get_transaction(struct pakfire_probl
        return pakfire_transaction_ref(problem->transaction);
 }
 
-PAKFIRE_EXPORT struct pakfire_solution** pakfire_problem_get_solutions(
+struct pakfire_solution** pakfire_problem_get_solutions(
                struct pakfire_problem* problem) {
        struct pakfire_solution** solutions = NULL;
        struct pakfire_solution* solution = NULL;
similarity index 87%
rename from src/libpakfire/progress.c
rename to src/pakfire/progress.c
index 2e3b6883d167cbd040bd248a184c222628910911..f581bea4fbed2e86b5d2f34bf06667b4312e1c6d 100644 (file)
@@ -24,7 +24,6 @@
 
 #include <pakfire/ctx.h>
 #include <pakfire/logging.h>
-#include <pakfire/private.h>
 #include <pakfire/progress.h>
 
 struct pakfire_progress {
@@ -156,7 +155,7 @@ struct pakfire_progress* pakfire_progress_unref(struct pakfire_progress* p) {
        return NULL;
 }
 
-PAKFIRE_EXPORT int pakfire_progress_has_flag(struct pakfire_progress* p, int flag) {
+int pakfire_progress_has_flag(struct pakfire_progress* p, int flag) {
        return p->flags & flag;
 }
 
@@ -164,26 +163,26 @@ PAKFIRE_EXPORT int pakfire_progress_has_flag(struct pakfire_progress* p, int fla
        Callback Configuration
 */
 
-PAKFIRE_EXPORT void pakfire_progress_set_callback_data(struct pakfire_progress* p, void* data) {
+void pakfire_progress_set_callback_data(struct pakfire_progress* p, void* data) {
        p->callbacks.data = data;
 }
 
-PAKFIRE_EXPORT void pakfire_progress_set_start_callback(
+void pakfire_progress_set_start_callback(
                struct pakfire_progress* p, pakfire_progress_start_callback callback) {
        p->callbacks.start = callback;
 }
 
-PAKFIRE_EXPORT void pakfire_progress_set_finish_callback(
+void pakfire_progress_set_finish_callback(
                struct pakfire_progress* p, pakfire_progress_finish_callback callback) {
        p->callbacks.finish = callback;
 }
 
-PAKFIRE_EXPORT void pakfire_progress_set_update_callback(
+void pakfire_progress_set_update_callback(
                struct pakfire_progress* p, pakfire_progress_update_callback callback) {
        p->callbacks.update = callback;
 }
 
-PAKFIRE_EXPORT void pakfire_progress_set_free_callback(
+void pakfire_progress_set_free_callback(
                struct pakfire_progress* p, pakfire_progress_free_callback callback) {
        p->callbacks.free = callback;
 }
@@ -308,18 +307,18 @@ int pakfire_progress_reset(struct pakfire_progress* p) {
        return 0;
 }
 
-PAKFIRE_EXPORT struct pakfire_progress* pakfire_progress_get_parent(struct pakfire_progress* p) {
+struct pakfire_progress* pakfire_progress_get_parent(struct pakfire_progress* p) {
        if (p->parent)
                return pakfire_progress_ref(p->parent);
 
        return NULL;
 }
 
-PAKFIRE_EXPORT unsigned long int pakfire_progress_get_value(struct pakfire_progress* p) {
+unsigned long int pakfire_progress_get_value(struct pakfire_progress* p) {
        return p->value;
 }
 
-PAKFIRE_EXPORT unsigned long int pakfire_progress_get_max_value(struct pakfire_progress* p) {
+unsigned long int pakfire_progress_get_max_value(struct pakfire_progress* p) {
        return p->max_value;
 }
 
@@ -327,7 +326,7 @@ void pakfire_progress_set_max_value(struct pakfire_progress* p, unsigned long in
        p->max_value = value;
 }
 
-PAKFIRE_EXPORT const char* pakfire_progress_get_title(struct pakfire_progress* p) {
+const char* pakfire_progress_get_title(struct pakfire_progress* p) {
        return p->title;
 }
 
@@ -347,14 +346,14 @@ int pakfire_progress_set_title(struct pakfire_progress* p, const char* format, .
        return 0;
 }
 
-PAKFIRE_EXPORT double pakfire_progress_get_percentage(struct pakfire_progress* p) {
+double pakfire_progress_get_percentage(struct pakfire_progress* p) {
        if (!p->max_value)
                return 0;
 
        return p->value * 100.0 / p->max_value;
 }
 
-PAKFIRE_EXPORT time_t pakfire_progress_get_elapsed_time(struct pakfire_progress* p) {
+time_t pakfire_progress_get_elapsed_time(struct pakfire_progress* p) {
        struct timespec now;
        int r;
 
@@ -376,7 +375,7 @@ PAKFIRE_EXPORT time_t pakfire_progress_get_elapsed_time(struct pakfire_progress*
        return -1;
 }
 
-PAKFIRE_EXPORT time_t pakfire_progress_get_eta(struct pakfire_progress* p) {
+time_t pakfire_progress_get_eta(struct pakfire_progress* p) {
        if (!p->value || !p->max_value)
                return 0;
 
@@ -387,7 +386,7 @@ PAKFIRE_EXPORT time_t pakfire_progress_get_eta(struct pakfire_progress* p) {
        return t * p->max_value / p->value - t;
 }
 
-PAKFIRE_EXPORT double pakfire_progress_get_transfer_speed(struct pakfire_progress* p) {
+double pakfire_progress_get_transfer_speed(struct pakfire_progress* p) {
        const time_t t = pakfire_progress_get_elapsed_time(p);
        if (t <= 0)
                return t;
similarity index 100%
rename from src/libpakfire/pty.c
rename to src/pakfire/pty.c
similarity index 100%
rename from src/libpakfire/pwd.c
rename to src/pakfire/pwd.c
similarity index 95%
rename from src/libpakfire/repo.c
rename to src/pakfire/repo.c
index 2af6ea74cf755d8e156143c358148e9c0fb3653f..9f9d35581a2aff884f9bc9d29fe69c8091f38ba7 100644 (file)
@@ -43,7 +43,6 @@
 #include <pakfire/package.h>
 #include <pakfire/pakfire.h>
 #include <pakfire/path.h>
-#include <pakfire/private.h>
 #include <pakfire/progress.h>
 #include <pakfire/repo.h>
 #include <pakfire/string.h>
@@ -761,7 +760,7 @@ static struct pakfire_repo_appdata* pakfire_repo_setup_appdata(struct pakfire_re
        return appdata;
 }
 
-PAKFIRE_EXPORT int pakfire_repo_create(struct pakfire_repo** repo,
+int pakfire_repo_create(struct pakfire_repo** repo,
                struct pakfire* pakfire, const char* name) {
        int r = 1;
 
@@ -838,13 +837,13 @@ struct pakfire_repo* pakfire_repo_create_from_repo(struct pakfire* pakfire, Repo
        return repo;
 }
 
-PAKFIRE_EXPORT struct pakfire_repo* pakfire_repo_ref(struct pakfire_repo* repo) {
+struct pakfire_repo* pakfire_repo_ref(struct pakfire_repo* repo) {
        repo->nrefs++;
 
        return repo;
 }
 
-PAKFIRE_EXPORT struct pakfire_repo* pakfire_repo_unref(struct pakfire_repo* repo) {
+struct pakfire_repo* pakfire_repo_unref(struct pakfire_repo* repo) {
        if (--repo->nrefs > 0)
                return repo;
 
@@ -853,7 +852,7 @@ PAKFIRE_EXPORT struct pakfire_repo* pakfire_repo_unref(struct pakfire_repo* repo
        return NULL;
 }
 
-PAKFIRE_EXPORT struct pakfire* pakfire_repo_get_pakfire(struct pakfire_repo* repo) {
+struct pakfire* pakfire_repo_get_pakfire(struct pakfire_repo* repo) {
        return pakfire_ref(repo->pakfire);
 }
 
@@ -871,14 +870,14 @@ Repodata* pakfire_repo_get_repodata(struct pakfire_repo* repo) {
        return repo_last_repodata(repo->repo);
 }
 
-PAKFIRE_EXPORT int pakfire_repo_identical(struct pakfire_repo* repo1, struct pakfire_repo* repo2) {
+int pakfire_repo_identical(struct pakfire_repo* repo1, struct pakfire_repo* repo2) {
        Repo* r1 = repo1->repo;
        Repo* r2 = repo2->repo;
 
        return strcmp(r1->name, r2->name);
 }
 
-PAKFIRE_EXPORT int pakfire_repo_cmp(struct pakfire_repo* repo1, struct pakfire_repo* repo2) {
+int pakfire_repo_cmp(struct pakfire_repo* repo1, struct pakfire_repo* repo2) {
        Repo* r1 = repo1->repo;
        Repo* r2 = repo2->repo;
 
@@ -891,7 +890,7 @@ PAKFIRE_EXPORT int pakfire_repo_cmp(struct pakfire_repo* repo1, struct pakfire_r
        return strcmp(r1->name, r2->name);
 }
 
-PAKFIRE_EXPORT int pakfire_repo_count(struct pakfire_repo* repo) {
+int pakfire_repo_count(struct pakfire_repo* repo) {
        Pool* pool = pakfire_get_solv_pool(repo->pakfire);
        int cnt = 0;
 
@@ -924,37 +923,37 @@ int pakfire_repo_internalize(struct pakfire_repo* repo, int flags) {
        return 0;
 }
 
-PAKFIRE_EXPORT const char* pakfire_repo_get_name(struct pakfire_repo* repo) {
+const char* pakfire_repo_get_name(struct pakfire_repo* repo) {
        return repo->repo->name;
 }
 
-PAKFIRE_EXPORT const char* pakfire_repo_get_description(struct pakfire_repo* repo) {
+const char* pakfire_repo_get_description(struct pakfire_repo* repo) {
        return repo->appdata->description;
 }
 
-PAKFIRE_EXPORT int pakfire_repo_set_description(struct pakfire_repo* repo, const char* description) {
+int pakfire_repo_set_description(struct pakfire_repo* repo, const char* description) {
        return pakfire_string_set(repo->appdata->description, description);
 }
 
-PAKFIRE_EXPORT int pakfire_repo_get_enabled(struct pakfire_repo* repo) {
+int pakfire_repo_get_enabled(struct pakfire_repo* repo) {
        return !repo->repo->disabled;
 }
 
-PAKFIRE_EXPORT void pakfire_repo_set_enabled(struct pakfire_repo* repo, int enabled) {
+void pakfire_repo_set_enabled(struct pakfire_repo* repo, int enabled) {
        repo->repo->disabled = !enabled;
 
        pakfire_repo_has_changed(repo);
 }
 
-PAKFIRE_EXPORT int pakfire_repo_get_priority(struct pakfire_repo* repo) {
+int pakfire_repo_get_priority(struct pakfire_repo* repo) {
        return repo->repo->priority;
 }
 
-PAKFIRE_EXPORT void pakfire_repo_set_priority(struct pakfire_repo* repo, int priority) {
+void pakfire_repo_set_priority(struct pakfire_repo* repo, int priority) {
        repo->repo->priority = priority;
 }
 
-PAKFIRE_EXPORT const char* pakfire_repo_get_baseurl(struct pakfire_repo* repo) {
+const char* pakfire_repo_get_baseurl(struct pakfire_repo* repo) {
        return repo->appdata->baseurl;
 }
 
@@ -984,7 +983,7 @@ ERROR:
        return (*repo->appdata->expanded_baseurl) ? repo->appdata->expanded_baseurl : NULL;
 }
 
-PAKFIRE_EXPORT int pakfire_repo_set_baseurl(struct pakfire_repo* repo, const char* baseurl) {
+int pakfire_repo_set_baseurl(struct pakfire_repo* repo, const char* baseurl) {
        int r;
 
        // Store the URL
@@ -1021,7 +1020,7 @@ const char* pakfire_repo_get_path(struct pakfire_repo* repo) {
        return baseurl + strlen("file://");
 }
 
-PAKFIRE_EXPORT struct pakfire_key* pakfire_repo_get_key(struct pakfire_repo* repo) {
+struct pakfire_key* pakfire_repo_get_key(struct pakfire_repo* repo) {
        int r;
 
        // It looks like no key has been imported
@@ -1039,15 +1038,15 @@ PAKFIRE_EXPORT struct pakfire_key* pakfire_repo_get_key(struct pakfire_repo* rep
        return pakfire_key_ref(repo->key);
 }
 
-PAKFIRE_EXPORT const char* pakfire_repo_get_mirrorlist_url(struct pakfire_repo* repo) {
+const char* pakfire_repo_get_mirrorlist_url(struct pakfire_repo* repo) {
        return repo->appdata->mirrorlist_url;
 }
 
-PAKFIRE_EXPORT int pakfire_repo_set_mirrorlist_url(struct pakfire_repo* repo, const char* url) {
+int pakfire_repo_set_mirrorlist_url(struct pakfire_repo* repo, const char* url) {
        return pakfire_string_set(repo->appdata->mirrorlist_url, url);
 }
 
-PAKFIRE_EXPORT int pakfire_repo_write_config(struct pakfire_repo* repo, FILE* f) {
+int pakfire_repo_write_config(struct pakfire_repo* repo, FILE* f) {
        int r;
 
        // Do nothing for the installed repository
@@ -1168,7 +1167,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_repo_is_installed_repo(struct pakfire_repo* repo) {
+int pakfire_repo_is_installed_repo(struct pakfire_repo* repo) {
        struct pakfire_repo* installed_repo = pakfire_get_installed_repo(repo->pakfire);
        if (!installed_repo)
                return 0;
@@ -1348,7 +1347,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_repo_read_solv(struct pakfire_repo* repo, FILE *f, int flags) {
+int pakfire_repo_read_solv(struct pakfire_repo* repo, FILE *f, int flags) {
        // Automatically detect compression
        f = pakfire_xfopen(f, "r");
        if (!f) {
@@ -1388,7 +1387,7 @@ PAKFIRE_EXPORT int pakfire_repo_read_solv(struct pakfire_repo* repo, FILE *f, in
        return 0;
 }
 
-PAKFIRE_EXPORT int pakfire_repo_write_solv(struct pakfire_repo* repo, FILE *f, int flags) {
+int pakfire_repo_write_solv(struct pakfire_repo* repo, FILE *f, int flags) {
        Repodata* meta = NULL;
        Queue addedfileprovides;
        int r;
@@ -1485,7 +1484,7 @@ NEXT:
        return 0;
 }
 
-PAKFIRE_EXPORT int pakfire_repo_clean(struct pakfire_repo* repo, int flags) {
+int pakfire_repo_clean(struct pakfire_repo* repo, int flags) {
        char cache_path[PATH_MAX];
        int r;
 
@@ -1628,7 +1627,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_repo_scan(struct pakfire_repo* repo, int flags) {
+int pakfire_repo_scan(struct pakfire_repo* repo, int flags) {
        int r;
 
        // Scan context
@@ -1692,7 +1691,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_repo_refresh(struct pakfire_repo* repo, int force) {
+int pakfire_repo_refresh(struct pakfire_repo* repo, int force) {
        const char* name = pakfire_repo_get_name(repo);
        int r;
 
@@ -1947,7 +1946,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_repo_compose(struct pakfire* pakfire, const char* path,
+int pakfire_repo_compose(struct pakfire* pakfire, const char* path,
                struct pakfire_key* key, const char** files) {
        struct pakfire_repo* repo = NULL;
        char realpath[PATH_MAX];
similarity index 82%
rename from src/libpakfire/repolist.c
rename to src/pakfire/repolist.c
index f7b36deca5356aa2cc22b5a257e657f0aeff8e5c..cd9c6012d10d521218582088953fc3f1ee0937ea 100644 (file)
@@ -21,7 +21,6 @@
 #include <errno.h>
 #include <stdlib.h>
 
-#include <pakfire/private.h>
 #include <pakfire/repo.h>
 #include <pakfire/repolist.h>
 
@@ -46,7 +45,7 @@ static int pakfire_repolist_grow(struct pakfire_repolist* list, size_t size) {
        return 0;
 }
 
-PAKFIRE_EXPORT int pakfire_repolist_create(struct pakfire_repolist** list) {
+int pakfire_repolist_create(struct pakfire_repolist** list) {
        struct pakfire_repolist* l = calloc(1, sizeof(*l));
        if (!l)
                return ENOMEM;
@@ -57,7 +56,7 @@ PAKFIRE_EXPORT int pakfire_repolist_create(struct pakfire_repolist** list) {
        return 0;
 }
 
-PAKFIRE_EXPORT struct pakfire_repolist* pakfire_repolist_ref(
+struct pakfire_repolist* pakfire_repolist_ref(
                struct pakfire_repolist* list) {
        list->nrefs++;
 
@@ -69,7 +68,7 @@ static void pakfire_repolist_free(struct pakfire_repolist* list) {
        free(list);
 }
 
-PAKFIRE_EXPORT struct pakfire_repolist* pakfire_repolist_unref(
+struct pakfire_repolist* pakfire_repolist_unref(
                struct pakfire_repolist* list) {
        if (--list->nrefs > 0)
                return list;
@@ -78,7 +77,7 @@ PAKFIRE_EXPORT struct pakfire_repolist* pakfire_repolist_unref(
        return NULL;
 }
 
-PAKFIRE_EXPORT void pakfire_repolist_clear(struct pakfire_repolist* list) {
+void pakfire_repolist_clear(struct pakfire_repolist* list) {
        if (!list->elements)
                return;
 
@@ -92,22 +91,22 @@ PAKFIRE_EXPORT void pakfire_repolist_clear(struct pakfire_repolist* list) {
        list->size = 0;
 }
 
-PAKFIRE_EXPORT size_t pakfire_repolist_size(struct pakfire_repolist* list) {
+size_t pakfire_repolist_size(struct pakfire_repolist* list) {
        return list->size;
 }
 
-PAKFIRE_EXPORT int pakfire_repolist_empty(struct pakfire_repolist* list) {
+int pakfire_repolist_empty(struct pakfire_repolist* list) {
        return list->size == 0;
 }
 
-PAKFIRE_EXPORT struct pakfire_repo* pakfire_repolist_get(struct pakfire_repolist* list, size_t index) {
+struct pakfire_repo* pakfire_repolist_get(struct pakfire_repolist* list, size_t index) {
        if (index >= list->size)
                return NULL;
 
        return pakfire_repo_ref(list->elements[index]);
 }
 
-PAKFIRE_EXPORT int pakfire_repolist_append(struct pakfire_repolist* list, struct pakfire_repo* repo) {
+int pakfire_repolist_append(struct pakfire_repolist* list, struct pakfire_repo* repo) {
        if (!repo)
                return EINVAL;
 
similarity index 95%
rename from src/libpakfire/solution.c
rename to src/pakfire/solution.c
index 1ed93e6e674b0ad6725cf985eca2910b795ad393..c4785b10fdf89729d6344d083cd2862d87b2c32c 100644 (file)
@@ -27,7 +27,6 @@
 #include <pakfire/i18n.h>
 #include <pakfire/logging.h>
 #include <pakfire/pakfire.h>
-#include <pakfire/private.h>
 #include <pakfire/problem.h>
 #include <pakfire/solution.h>
 #include <pakfire/string.h>
@@ -65,7 +64,7 @@ int pakfire_solution_create(struct pakfire_solution** solution,
        return 0;
 }
 
-PAKFIRE_EXPORT struct pakfire_solution* pakfire_solution_ref(struct pakfire_solution* solution) {
+struct pakfire_solution* pakfire_solution_ref(struct pakfire_solution* solution) {
        solution->nrefs++;
 
        return solution;
@@ -81,7 +80,7 @@ static void pakfire_solution_free(struct pakfire_solution* solution) {
        free(solution);
 }
 
-PAKFIRE_EXPORT struct pakfire_solution* pakfire_solution_unref(struct pakfire_solution* solution) {
+struct pakfire_solution* pakfire_solution_unref(struct pakfire_solution* solution) {
        if (!solution)
                return NULL;
 
@@ -209,7 +208,7 @@ ERROR:
        return s;
 }
 
-PAKFIRE_EXPORT const char* pakfire_solution_to_string(struct pakfire_solution* solution) {
+const char* pakfire_solution_to_string(struct pakfire_solution* solution) {
        if (!solution->string)
                solution->string = pakfire_solution_make_string(solution);
 
similarity index 100%
rename from src/libpakfire/string.c
rename to src/pakfire/string.c
similarity index 97%
rename from src/libpakfire/transaction.c
rename to src/pakfire/transaction.c
index 5f37ddd68f52780755006366d6a196106bd96003..4490421dca70b468b2ce396e0ee8212b2f832e34 100644 (file)
@@ -39,7 +39,6 @@
 #include <pakfire/package.h>
 #include <pakfire/pakfire.h>
 #include <pakfire/path.h>
-#include <pakfire/private.h>
 #include <pakfire/repo.h>
 #include <pakfire/string.h>
 #include <pakfire/transaction.h>
@@ -344,7 +343,7 @@ static int pakfire_transaction_setup_solver(struct pakfire_transaction* transact
        return 0;
 }
 
-PAKFIRE_EXPORT int pakfire_transaction_create(struct pakfire_transaction** transaction,
+int pakfire_transaction_create(struct pakfire_transaction** transaction,
                struct pakfire* pakfire, int flags) {
        int r;
 
@@ -415,14 +414,14 @@ static void pakfire_transaction_free(struct pakfire_transaction* transaction) {
        free(transaction);
 }
 
-PAKFIRE_EXPORT struct pakfire_transaction* pakfire_transaction_ref(
+struct pakfire_transaction* pakfire_transaction_ref(
                struct pakfire_transaction* transaction) {
        transaction->nrefs++;
 
        return transaction;
 }
 
-PAKFIRE_EXPORT struct pakfire_transaction* pakfire_transaction_unref(
+struct pakfire_transaction* pakfire_transaction_unref(
                struct pakfire_transaction* transaction) {
        if (--transaction->nrefs > 0)
                return transaction;
@@ -470,7 +469,7 @@ static void pakfire_transaction_status(struct pakfire_transaction* transaction,
                free(buffer);
 }
 
-PAKFIRE_EXPORT struct pakfire_problem** pakfire_transaction_get_problems(
+struct pakfire_problem** pakfire_transaction_get_problems(
                struct pakfire_transaction* transaction) {
        struct pakfire_problem** problems = NULL;
        struct pakfire_problem* problem = NULL;
@@ -614,7 +613,7 @@ Solver* pakfire_transaction_get_solver(struct pakfire_transaction* transaction)
        return transaction->solver;
 }
 
-PAKFIRE_EXPORT int pakfire_transaction_solve(struct pakfire_transaction* transaction,
+int pakfire_transaction_solve(struct pakfire_transaction* transaction,
                int flags, char** problems) {
        clock_t solving_start;
        clock_t solving_end;
@@ -853,7 +852,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_transaction_request(struct pakfire_transaction* transaction,
+int pakfire_transaction_request(struct pakfire_transaction* transaction,
                const enum pakfire_job_action action, const char* what, int flags) {
        struct pakfire_package* package = NULL;
        int r;
@@ -895,7 +894,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_transaction_request_package(struct pakfire_transaction* transaction,
+int pakfire_transaction_request_package(struct pakfire_transaction* transaction,
                const enum pakfire_job_action action, struct pakfire_package* package, int flags) {
        // Get the solvable ID
        Id id = pakfire_package_id(package);
@@ -904,7 +903,7 @@ PAKFIRE_EXPORT int pakfire_transaction_request_package(struct pakfire_transactio
        return __pakfire_transaction_add(transaction, action, SOLVER_SOLVABLE, id, flags);
 }
 
-PAKFIRE_EXPORT int pakfire_transaction_take_solution(struct pakfire_transaction* transaction,
+int pakfire_transaction_take_solution(struct pakfire_transaction* transaction,
                struct pakfire_solution* solution) {
        struct pakfire_problem* problem = pakfire_solution_get_problem(solution);
 
@@ -919,7 +918,7 @@ PAKFIRE_EXPORT int pakfire_transaction_take_solution(struct pakfire_transaction*
        return 0;
 }
 
-PAKFIRE_EXPORT size_t pakfire_transaction_count(struct pakfire_transaction* transaction) {
+size_t pakfire_transaction_count(struct pakfire_transaction* transaction) {
        return transaction->num;
 }
 
@@ -1038,7 +1037,7 @@ static int pakfire_transaction_add_usage_line(char** s, size_t width,
        return pakfire_transaction_append_line(s, "%s%-21s: %s\n", *s, headline, buffer);
 }
 
-PAKFIRE_EXPORT char* pakfire_transaction_dump(struct pakfire_transaction* transaction, size_t width) {
+char* pakfire_transaction_dump(struct pakfire_transaction* transaction, size_t width) {
        char headline[1024];
        char* s = NULL;
        int r;
@@ -1963,7 +1962,7 @@ END:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_transaction_download(struct pakfire_transaction* transaction) {
+int pakfire_transaction_download(struct pakfire_transaction* transaction) {
        struct pakfire_httpclient* httpclient = NULL;
        int r;
 
@@ -2000,7 +1999,7 @@ ERROR:
        return r;
 }
 
-PAKFIRE_EXPORT int pakfire_transaction_run(struct pakfire_transaction* transaction) {
+int pakfire_transaction_run(struct pakfire_transaction* transaction) {
        char* dump = NULL;
        int r;
 
similarity index 100%
rename from src/libpakfire/util.c
rename to src/pakfire/util.c
similarity index 100%
rename from src/libpakfire/xfer.c
rename to src/pakfire/xfer.c