rocksdb: fix cross build

Signed-off-by: Jürgen Buchmüller <pullmoll@t-online.de>
This commit is contained in:
Jürgen Buchmüller 2019-05-27 12:29:33 +02:00
parent 9db325e0d1
commit d174eeee66
No known key found for this signature in database
GPG key ID: DE55AD8DBEBB4EE8

View file

@ -1,7 +1,7 @@
# Template file for 'rocksdb' # Template file for 'rocksdb'
pkgname=rocksdb pkgname=rocksdb
version=5.18.3 version=5.18.3
revision=1 revision=2
build_style=cmake build_style=cmake
configure_args="-DCMAKE_BUILD_TYPE=Release -DPORTABLE=1 -DWITH_TESTS=0 configure_args="-DCMAKE_BUILD_TYPE=Release -DPORTABLE=1 -DWITH_TESTS=0
-DUSE_RTTI=0 -DWITH_LZ4=1" -DUSE_RTTI=0 -DWITH_LZ4=1"
@ -14,8 +14,19 @@ distfiles="${homepage}/archive/v${version}.tar.gz"
checksum=7fb6738263d3f2b360d7468cf2ebe333f3109f3ba1ff80115abd145d75287254 checksum=7fb6738263d3f2b360d7468cf2ebe333f3109f3ba1ff80115abd145d75287254
case "$XBPS_TARGET_MACHINE" in case "$XBPS_TARGET_MACHINE" in
armv[56]l*) broken="Requires libatomic workaround" ;; armv[56]*|mips*|ppc|ppc-musl) makedepends+=" libatomic-devel";;
esac esac
# Use the C++17 feature to align new
CXXFLAGS="-faligned-new"
pre_configure() {
case "$XBPS_TARGET_MACHINE" in
armv[56]*|mips*|ppc|ppc-musl)
vsed -i CMakeLists.txt \
-e 's;target_link_libraries(${ROCKSDB_SHARED_LIB};& atomic;'
;;
esac
}
post_install() { post_install() {
vcopy "include/rocksdb/*" usr/include/rocksdb vcopy "include/rocksdb/*" usr/include/rocksdb