Closed heunglee closed 6 years ago
The supported platforms of rocksdb depended by librocksdb-sys 5.7.1 and rust-rocksdb 0.8.2 are listed in the document linked: https://github.com/facebook/rocksdb/blob/acf935e40f9d6f4c3d13c7d310def7064c1f1c95/INSTALL.md
OS: Centos7
error: failed to run custom build command for librocksdb-sys v5.7.1 process didn't exit successfully: /opt/grin/target/debug/build/librocksdb-sys-ff4c942245b58073/build-script-build (exit code: 101) --- stdout cargo:rerun-if-changed=build.rs cargo:rerun-if-changed=rocksdb/ rocksdb/include/rocksdb/c.h:48:9: warning: #pragma once in main file, err: false
--- stderr thread 'main' panicked at 'function not loaded: clang_Type_getNumTemplateArguments', /root/.cargo/registry/src/github.com-1ecc6299db9ec823/clang-sys-0.21.1/src/lib.rs:1456:0 note: Run with RUST_BACKTRACE=1 for a backtrace.
Possible resolution: Need clang 3.8 or 3.9 https://stackoverflow.com/questions/44219158/how-to-install-clang-and-llvm-3-9-on-centos-7
For error: rocksdb/include/rocksdb/c.h:68:10: fatal error: 'stdarg.h' file not found, err: true Resolution: export LIBCLANG_PATH=/[install path]/llvm-3.9.0/lib64 export PATH=$PATH:/[install path]/llvm-3.9.0/bin
For Alpine Linux:
No longer relevant
Please note that this issue is not what grin needs to fix. It is more like informative report on building grin in AWS instances at the time of writing. There seems problem in linker to native library, librocksdb-sys. AMI has dev tools configured for amazon specifics and there seems some conflicts in clang part. EPEL was enabled and clang was installed to fix the build error. But the error was persistent.
Hardware: AWS EC2 m.large OS: AMI
Before upgrading to rocksdb 0.8.0+, compiling grin on the ec2 instance above was passed and grin was operational. After git pull and cargo build for update to rocksdb 0.8.0+ and librocksdb-sys 5.7.1, cargo build failed. It was not successful with cargo clean and cargo build either. The error log is in the link, https://pastebin.com/G9sGLmR5.