Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix nimble install: Link to dependencies dynamically on Linux #76

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions rocksdb.nimble
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ description =
license = "Apache License 2.0 or GPLv2"
skipDirs = @["examples", "tests"]
mode = ScriptMode.Verbose
installDirs = @["build"]

### Dependencies
requires "nim >= 2.0", "results", "tempfile", "unittest2"
Expand Down
4 changes: 3 additions & 1 deletion scripts/build_shared_deps_linux.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ set -e
cd "$(dirname "${BASH_SOURCE[0]}")"/..

REPO_DIR="${PWD}"
BUILD_DEST="${REPO_DIR}/build/"

BUILD_DEST="${REPO_DIR}/build/"

git submodule update --init

Expand All @@ -25,4 +25,6 @@ ${REPO_DIR}/vendor/vcpkg/vcpkg install rocksdb[lz4,zstd]:x64-linux-rocksdb --rec

mkdir -p "${BUILD_DEST}"

cp "${REPO_DIR}/vendor/vcpkg/installed/x64-linux-rocksdb/lib/liblz4.so" "${BUILD_DEST}/"
cp "${REPO_DIR}/vendor/vcpkg/installed/x64-linux-rocksdb/lib/libzstd.so" "${BUILD_DEST}/"
cp "${REPO_DIR}/vendor/vcpkg/installed/x64-linux-rocksdb/lib/librocksdb.so" "${BUILD_DEST}/"
9 changes: 2 additions & 7 deletions triplets/x64-linux-rocksdb.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,5 @@ set(VCPKG_BUILD_TYPE release)
set(VCPKG_CMAKE_SYSTEM_NAME Linux)
set(VCPKG_FIXUP_ELF_RPATH ON)

if(${PORT} MATCHES "snappy|zlib|lz4|zstd")
set(VCPKG_CRT_LINKAGE static)
set(VCPKG_LIBRARY_LINKAGE static)
else()
set(VCPKG_CRT_LINKAGE dynamic)
set(VCPKG_LIBRARY_LINKAGE dynamic)
endif()
set(VCPKG_CRT_LINKAGE dynamic)
set(VCPKG_LIBRARY_LINKAGE dynamic)
Loading