diff --git a/system/base/leveldb/actions.py b/system/base/leveldb/actions.py index 7fbc4392..4fb0ced6 100644 --- a/system/base/leveldb/actions.py +++ b/system/base/leveldb/actions.py @@ -6,20 +6,27 @@ from pisi.actionsapi import autotools from pisi.actionsapi import pisitools from pisi.actionsapi import shelltools +from pisi.actionsapi import cmaketools +from pisi.actionsapi import get + +def setup(): + cmaketools.configure("-DBUILD_SHARED_LIBS=ON \ + -DCMAKE_INSTALL_LIBDIR=lib") def build(): - shelltools.chmod("build_detect_platform", 0755) - autotools.make() + #shelltools.chmod("build_detect_platform", 0755) + cmaketools.make() def check(): - autotools.make("check") + cmaketools.make("test") def install(): - pisitools.dolib_so("libleveldb.so.1.18") - pisitools.dosym("libleveldb.so.1.18", "/usr/lib/libleveldb.so.1") - pisitools.dosym("libleveldb.so.1.18", "/usr/lib/libleveldb.so") + autotools.rawInstall("DESTDIR=%s" % get.installDIR()) + #pisitools.dolib_so("libleveldb.so.1.18") + #pisitools.dosym("libleveldb.so.1.18", "/usr/lib/libleveldb.so.1") + #pisitools.dosym("libleveldb.so.1.18", "/usr/lib/libleveldb.so") - pisitools.insinto("/usr/include", "include/*") - pisitools.insinto("/usr/include", "helpers/memenv/memenv.h") + #pisitools.insinto("/usr/include", "include/*") + #pisitools.insinto("/usr/include", "helpers/memenv/memenv.h") - pisitools.dodoc("README", "LICENSE", "NEWS", "AUTHORS") \ No newline at end of file + pisitools.dodoc("README.md", "LICENSE", "NEWS", "AUTHORS") \ No newline at end of file diff --git a/system/base/leveldb/files/0001-Restore-soname-versioning-with-CMake-build.patch b/system/base/leveldb/files/0001-Restore-soname-versioning-with-CMake-build.patch new file mode 100644 index 00000000..01a9e6e0 --- /dev/null +++ b/system/base/leveldb/files/0001-Restore-soname-versioning-with-CMake-build.patch @@ -0,0 +1,39 @@ +From 37300aa54b8256dd2edfd504942eb2bd20823647 Mon Sep 17 00:00:00 2001 +From: leveldb Team +Date: Mon, 1 Apr 2019 08:59:17 -0700 +Subject: [PATCH] Restore soname versioning with CMake build + +Before: + +$ readelf -d build/libleveldb.so | grep soname + 0x000000000000000e (SONAME) Library soname: [libleveldb.so] + +After: +$ readelf -d build/libleveldb.so | grep soname + 0x000000000000000e (SONAME) Library soname: [libleveldb.so.1] + +This matches the soname from v1.20. + +PiperOrigin-RevId: 241334113 +--- + CMakeLists.txt | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index e471a2a..ceb5dd9 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -233,6 +233,10 @@ if(BUILD_SHARED_LIBS) + # Used by include/export.h. + LEVELDB_SHARED_LIBRARY + ) ++ set_target_properties(leveldb ++ PROPERTIES VERSION ${PROJECT_VERSION}) ++ set_target_properties(leveldb ++ PROPERTIES SOVERSION 1) + endif(BUILD_SHARED_LIBS) + + if(HAVE_CLANG_THREAD_SAFETY) +-- +2.21.0 + diff --git a/system/base/leveldb/pspec.xml b/system/base/leveldb/pspec.xml index 2d17cf20..cd5f3c02 100644 --- a/system/base/leveldb/pspec.xml +++ b/system/base/leveldb/pspec.xml @@ -16,7 +16,10 @@ gperftools-devel snappy-devel - https://github.com/google/leveldb/archive/v1.18.tar.gz + https://github.com/google/leveldb/archive/1.22.tar.gz + + 0001-Restore-soname-versioning-with-CMake-build.patch + @@ -38,10 +41,18 @@ /usr/include + /usr/lib/cmake + + 2019-12-27 + 1.22 + Version bump + idris Kalp + idriskalp@gmail.com + 2018-07-15 1.18