2017-10-30 8 views
0

CentOS 7에서 나는 here에서 드라이버를 복제했습니다.건물 몽고 C++ 드라이버

빌드 할 때 libbson에 대한 오류가 발생합니다. 그럼에도 불구하고 libbson 모두는 LD_LIBRARY_PATHlibbson/usr/lib64

[[email protected] build]$ ls /usr/lib64/libbson* 
/usr/lib64/libbson-1.0 /usr/lib64/libbson-1.0.so /usr/lib64/libbson-1.0.so.0 /usr/lib64/libbson-1.0.so.0.0.0 
[[email protected] build]$ 

[[email protected] build]$ cmake .. 
-- The CXX compiler identification is GNU 6.3.1 
-- Check for working CXX compiler: /opt/rh/devtoolset-6/root/usr/bin/c++ 
-- Check for working CXX compiler: /opt/rh/devtoolset-6/root/usr/bin/c++ -- works 
-- Detecting CXX compiler ABI info 
-- Detecting CXX compiler ABI info - done 
-- Detecting CXX compile features 
-- Detecting CXX compile features - done 
-- No build type selected, default is Release 
-- The C compiler identification is GNU 6.3.1 
-- Check for working C compiler: /opt/rh/devtoolset-6/root/usr/bin/cc 
-- Check for working C compiler: /opt/rh/devtoolset-6/root/usr/bin/cc -- works 
-- Detecting C compiler ABI info 
-- Detecting C compiler ABI info - done 
-- Detecting C compile features 
-- Detecting C compile features - done 
CMake Error at src/bsoncxx/CMakeLists.txt:70 (find_package): 
    By not providing "Findlibbson-1.0.cmake" in CMAKE_MODULE_PATH this project 
    has asked CMake to find a package configuration file provided by 
    "libbson-1.0", but CMake did not find one. 

    Could not find a package configuration file provided by "libbson-1.0" 
    (requested version 1.9.0) with any of the following names: 

    libbson-1.0Config.cmake 
    libbson-1.0-config.cmake 

    Add the installation prefix of "libbson-1.0" to CMAKE_PREFIX_PATH or set 
    "libbson-1.0_DIR" to a directory containing one of the above files. If 
    "libbson-1.0" provides a separate development package or SDK, be sure it 
    has been installed. 


-- Configuring incomplete, errors occurred! 
See also "/home/idf/builds/mongo-cxx-driver/build/CMakeFiles/CMakeOutput.log". 
[[email protected] build]$ 
구축을 위해 노력에

[[email protected] build]$ echo $PATH 
/usr/lib64:/opt/rh/devtoolset-6/root/usr/bin:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/home/idf/.local/bin:/home/idf/bin 
[[email protected] build]$ 

증명하는 PATH

[[email protected] build]$ echo $LD_LIBRARY_PATH 
/usr/lib64:/usr/local/lib64:/usr/local/lib:/lib64:/usr/lib64:/usr/local/lib64:/usr/local/lib:/lib64:/opt/rh/devtoolset-6/root/usr/lib64:/opt/rh/devtoolset-6/root/usr/lib:/usr/lib64:/usr/local/lib64:/usr/local/lib:/lib64: 
[[email protected] build]$ 

경로에

왜 이런 일이 발생하는지 잘 모르십니까?

답변

0

나는 손하여 라이브러리 를 컴파일하여 그것을 해결 (냠 아니, APT 등) libbson, libmongo-C 드라이버, 그리고 마지막으로 libmongo-CPP 드라이버