move around

main
Ziyang Hu 2 years ago
parent 55be00f413
commit f6772f6a39

3
.gitignore vendored

@ -29,4 +29,5 @@ _deps
_test*
*.db
deps/
cozorocks/deps/
.DS_Store

2
.gitmodules vendored

@ -1,3 +1,3 @@
[submodule "rocksdb"]
path = rocksdb
path = cozorocks/rocksdb
url = https://github.com/facebook/rocksdb

@ -7,6 +7,7 @@ edition = "2021"
[dependencies]
cxx = "1.0.69"
tikv-jemalloc-sys = { "version" = "0.5", "features" = ["unprefixed_malloc_on_supported_platforms"] }
[build-dependencies]
cxx-build = "1.0.69"

@ -1,6 +1,10 @@
use std::env::var;
fn main() {
println!("cargo:rustc-link-search=../deps/lib/");
println!("cargo:rustc-link-search=/opt/homebrew/lib/");
let manifest_dir = var("CARGO_MANIFEST_DIR").unwrap();
// println!("cargo:rustc-link-search=/opt/homebrew/lib/");
println!("cargo:rustc-link-search={}/deps/lib/", manifest_dir);
println!("cargo:rustc-link-lib=rocksdb");
println!("cargo:rustc-link-lib=z");
println!("cargo:rustc-link-lib=bz2");
@ -23,7 +27,7 @@ fn main() {
cxx_build::bridge("src/bridge/mod.rs")
.files(["bridge/status.cpp", "bridge/db.cpp", "bridge/tx.cpp"])
.include("../deps/include")
.include("deps/include")
.include("bridge")
.flag_if_supported("-std=c++17")
.compile("cozorocks");

@ -1 +0,0 @@
Subproject commit 8e0f495253f62904a4ca6d3ec6a03391a12b0a45
Loading…
Cancel
Save