diff options
-rw-r--r-- | CMakeLists.txt | 15 | ||||
-rw-r--r-- | debian/changelog | 34 | ||||
-rw-r--r-- | debian/libept1.4.12.install | 2 | ||||
-rw-r--r-- | debian/libept1.4.12.links | 1 | ||||
-rwxr-xr-x | debian/rules | 2 | ||||
-rw-r--r-- | ept/CMakeLists.txt | 4 | ||||
-rw-r--r-- | ept/apt/apt.cc | 7 | ||||
-rw-r--r-- | ept/apt/apt.h | 8 | ||||
-rw-r--r-- | ept/popcon/maint/popconindexer.cc | 1 |
9 files changed, 68 insertions, 6 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 1154891..d18a2f4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -3,8 +3,19 @@ include( FindDoxygen ) add_custom_target( unit ) -set( LIBAPT_ABI_VERSION "4.12" ) -set( EPT_VERSION "1.0.5.${LIBAPT_ABI_VERSION}" ) +set( EPT_VERSION "1.0.9" ) + +# Get the soversion from libapt-pkg to include in our own +execute_process( + COMMAND "cc" "-xc" "-shared" "-Wl,--no-as-needed" "/dev/null" "-lapt-pkg" + ) +execute_process( + COMMAND "objdump" "-p" "a.out" + COMMAND "awk" "/NEEDED.*libapt-pkg/ { sub(\".*\\\\.so\\\\.\", \"\"); print }" + OUTPUT_VARIABLE LIBAPT_ABI_VERSION + OUTPUT_STRIP_TRAILING_WHITESPACE + ) +set( LIBEPT_SOVERSION "1.aptpkg${LIBAPT_ABI_VERSION}" ) set( APT_INCLUDES "/usr/include/" CACHE STRING "apt include path" ) set( APT_LINKDIRS "/usr/lib/" CACHE STRING "apt library path" ) set( OPT_FLAGS "-O0 -g" CACHE STRING "optimization level" ) diff --git a/debian/changelog b/debian/changelog index a0b6c24..d153a59 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,37 @@ +libept (1.0.9) unstable; urgency=low + + [ Adam Conrad ] + * Add -Wl,--no-as-needed to the -lapt-pkg linking trick, as it + fails to link anything if the toolchain defaults to as-neeed. + + -- Enrico Zini <enrico@debian.org> Thu, 21 Jun 2012 10:11:57 +0200 + +libept (1.0.8) unstable; urgency=low + + * Applied Julien Cristau's patch to avoid unnecessary soname bumps. + Closes: #677532, #677535, #677536 + + -- Enrico Zini <enrico@debian.org> Thu, 14 Jun 2012 20:32:47 +0200 + +libept (1.0.7) unstable; urgency=low + + * Expose the underlying libapt-pkg + + -- Enrico Zini <enrico@debian.org> Thu, 14 Jun 2012 13:58:48 +0200 + +libept (1.0.6.1) unstable; urgency=low + + * Non maintainer upload. + * Fix build failure with GCC 4.7. Closes: #667243. + + -- Matthias Klose <doko@debian.org> Tue, 17 Apr 2012 12:43:33 +0200 + +libept (1.0.6) unstable; urgency=low + + * upload to unstable + + -- Michael Vogt <mvo@debian.org> Mon, 16 Apr 2012 19:25:41 +0200 + libept (1.0.6~exp1) experimental; urgency=low * build against libapt in experimental diff --git a/debian/libept1.4.12.install b/debian/libept1.4.12.install index c45ebcf..389d6db 100644 --- a/debian/libept1.4.12.install +++ b/debian/libept1.4.12.install @@ -1 +1 @@ -debian/tmp/usr/lib/lib*.so.* +debian/tmp/usr/lib/libept.so.1.aptpkg4.12 diff --git a/debian/libept1.4.12.links b/debian/libept1.4.12.links new file mode 100644 index 0000000..133c3b6 --- /dev/null +++ b/debian/libept1.4.12.links @@ -0,0 +1 @@ +usr/lib/libept.so.1.aptpkg4.12 usr/lib/libept.so.1.0.5.4.12 diff --git a/debian/rules b/debian/rules index 65e693c..d47988e 100755 --- a/debian/rules +++ b/debian/rules @@ -10,7 +10,7 @@ DEB_HOST_ARCH := $(shell dpkg-architecture -qDEB_HOST_ARCH) DEB_MAKE_CHECK_TARGET := unit -DEB_DH_MAKESHLIBS_ARGS_libept0 = -V +DEB_DH_MAKESHLIBS_ARGS_libept1.4.12 = -V # comment out CONFIGURE and uncomment CMAKE flags to use cmake #DEB_CONFIGURE_EXTRA_FLAGS += --disable-shared --with-pic diff --git a/ept/CMakeLists.txt b/ept/CMakeLists.txt index a9b5fa8..19e9edf 100644 --- a/ept/CMakeLists.txt +++ b/ept/CMakeLists.txt @@ -30,8 +30,8 @@ add_definitions( -fexceptions -fPIC -fvisibility=default ) add_library( ept SHARED ${src} ) add_library( ept-static STATIC ${src} ) -set_target_properties( ept PROPERTIES VERSION ${EPT_VERSION} CLEAN_DIRECT_OUTPUT 1) -set_target_properties( ept-static PROPERTIES VERSION ${EPT_VERSION} OUTPUT_NAME "ept" CLEAN_DIRECT_OUTPUT 1) +set_target_properties( ept PROPERTIES SOVERSION ${LIBEPT_SOVERSION} CLEAN_DIRECT_OUTPUT 1) +set_target_properties( ept-static PROPERTIES SOVERSION ${LIBEPT_SOVERSION} OUTPUT_NAME "ept" CLEAN_DIRECT_OUTPUT 1) set( TEST_ENV_DIR ${ept_BINARY_DIR}/test-env/ ) diff --git a/ept/apt/apt.cc b/ept/apt/apt.cc index 76c34f0..2d625fb 100644 --- a/ept/apt/apt.cc +++ b/ept/apt/apt.cc @@ -633,6 +633,13 @@ std::string Apt::rawRecord(const Version& ver) const return std::string(); } + +const pkgCache* Apt::aptPkgCache() const +{ + return impl->m_cache; +} + + void Apt::checkCacheUpdates() { if (impl->m_open_timestamp < timestamp()) diff --git a/ept/apt/apt.h b/ept/apt/apt.h index 0cfff60..6e6ce74 100644 --- a/ept/apt/apt.h +++ b/ept/apt/apt.h @@ -29,6 +29,8 @@ #include <iterator> +class pkgCache; + namespace ept { namespace apt { @@ -198,6 +200,7 @@ public: Apt(); ~Apt(); + iterator begin() const; iterator end() const; @@ -257,6 +260,11 @@ public: /// Get the raw package record for the given Version std::string rawRecord(const Version& ver) const; + /// Returns the pointer to the internal libapt pkgCache object used. + const pkgCache* aptPkgCache() const; + + + /// Timestamp of when the apt index was last modified time_t timestamp(); diff --git a/ept/popcon/maint/popconindexer.cc b/ept/popcon/maint/popconindexer.cc index 6c04453..9787fca 100644 --- a/ept/popcon/maint/popconindexer.cc +++ b/ept/popcon/maint/popconindexer.cc @@ -8,6 +8,7 @@ #include <tagcoll/diskindex/mmap.h> +#include <unistd.h> #include <set> #include <string> #include <cstdio> |