rust-rocksdb
rust-rocksdb copied to clipboard
error: failed to run custom build command for `librocksdb-sys v5.18.3` Windows
Compiling librocksdb-sys v5.18.3
Compiling cennznet v0.9.25-beta (C:\Users\charingane\Desktop\cennznet-master)
error: failed to run custom build command for librocksdb-sys v5.18.3
Caused by:
process didn't exit successfully: C:\Users\charingane\Desktop\cennznet-master\target\debug\build\librocksdb-sys-b28aaa0ace6f4e98\build-script-build (exit code: 101)
--- stdout
cargo:rerun-if-changed=build.rs
cargo:rerun-if-changed=rocksdb/
cargo:rerun-if-changed=snappy/
cargo:rerun-if-changed=lz4/
cargo:rerun-if-changed=zstd/
cargo:rerun-if-changed=zlib/
cargo:rerun-if-changed=bzip2/
--- stderr
thread 'main' panicked at 'Unable to find libclang: "couldn't find any valid shared libraries matching: ['clang.dll', 'libclang.dll'], set the LIBCLANG_PATH environment variable to a path where one of these files can be found (invalid: [(C:\Program Files\LLVM\bin\libclang.dll: invalid DLL (64-bit))])"', src\libcore\result.rs:1165:5
note: run with RUST_BACKTRACE=1 environment variable to display a backtrace.
warning: build failed, waiting for other jobs to finish...
error: build failed
Please how to fix.
Hello, thank you for creating an issue. Are you depending on a particular rocksdb version?
Latest librocksdb-sys version is 6.2.4, with rocksdb version 0.13.0. It has the same problem though, I'm asking if we need to back-port the fix to the 5.18.3
This issue is a dublicate of #381
I have similar issue with newer version of librocksdb-sys v0.8.0+7.4.4:
error: failed to run custom build command for `librocksdb-sys v0.8.0+7.4.4`
Caused by:
process didn't exit successfully: `/home/tomek/ssd/workspaces/polkadot/target/debug/build/librocksdb-sys-ef257bddcda54e79/build-script-build` (exit status: 101)
--- stderr
thread 'main' panicked at '"enum_(unnamed_at_rocksdb/include/rocksdb/c_h_981_1)" is not a valid Ident', /home/tomek/.cargo/registry/src/github.com-1ecc6299db9ec823/proc-macro2-1.0.43/src/fallback.rs:730:9
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
I'm having a similar issue on ubuntu 22.04
error: failed to run custom build command for `librocksdb-sys v0.8.0+7.4.4`
Caused by:
process didn't exit successfully: `/mnt/work/projects/rust/larks/target/debug/build/librocksdb-sys-4f51bde46f377b21/build-script-build` (exit status: 1)
I am still encountering this problem while compiling solana on open suse tumbleweed wsl. Any one found any fixes ?
Same problem here...
One possible solution is to install the libclang library and add its location to the LIBCLANG_PATH environment variable. You can try installing LLVM on your system and adding its bin directory to your system's PATH environment variable.
Alternatively, you can try specifying the location of the libclang library by setting the LIBCLANG_PATH environment variable to the path where it is installed. For example, you can try running the following command before building the project:
set LIBCLANG_PATH=C:\path\to\libclang.dll
Replace C:\path\to\libclang.dll with the actual path to the library on your system.
If the issue persists, you can try updating your Rust and LLVM installations to the latest versions and try building the project again. You can also check if there are any updates available for the Cennznet project or its dependencies that address this issue.
I hope this helps!
On linux you can do LIBCLANG_PATH=/usr/lib/llvm-10/lib cargo build
Also have same error on windows. Are there any solution?
I have similar issue with newer version of
librocksdb-sys v0.8.0+7.4.4:error: failed to run custom build command for `librocksdb-sys v0.8.0+7.4.4` Caused by: process didn't exit successfully: `/home/tomek/ssd/workspaces/polkadot/target/debug/build/librocksdb-sys-ef257bddcda54e79/build-script-build` (exit status: 101) --- stderr thread 'main' panicked at '"enum_(unnamed_at_rocksdb/include/rocksdb/c_h_981_1)" is not a valid Ident', /home/tomek/.cargo/registry/src/github.com-1ecc6299db9ec823/proc-macro2-1.0.43/src/fallback.rs:730:9 note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
~~this should really be pulled out into its own issue~~ https://github.com/rust-rocksdb/rust-rocksdb/issues/864