Open mianbaozhai opened 7 years ago
Someone else who is also using conda suggested doing the following:
export LD_LIBRARY_PATH=$CONDA_PREFIX/lib/
and also you could try adding -L$CONDA_PREFIX/lib/ to your link command line. E.g. add that directory to the src/CMakeLists.txt file at the link_directories line.
Hi, I tried to install armatus using cmake cmake CMakeLists.txt -DBoost_NO_BOOST_CMAKE=TRUE -DCMAKE_INSTALL_PREFIX=~/software/armatus/ That's OK.
But, I have a problem when make install
Linking CXX executable armatus cd /public/home/liuyanlin/download/armatus-2.2/src && /public/home/liuyanlin/anaconda2/bin/cmake -E cmake_link_script CMakeFiles/armatus.dir/link.txt --verbose=1 /public/home/liuyanlin/anaconda2/bin/c++ -O3 -g -std=c++11 -Wall -Wno-unused-local-typedefs CMakeFiles/armatus.dir/Armatus.cpp.o CMakeFiles/armatus.dir/ArmatusUtil.cpp.o CMakeFiles/armatus.dir/ArmatusParams.cpp.o CMakeFiles/armatus.dir/ArmatusDAG.cpp.o CMakeFiles/armatus.dir/IntervalScheduling.cpp.o -o armatus -rdynamic -lboost_program_options-mt -lboost_iostreams -lboost_graph -lboost_system -lboost_regex -lz -Wl,-rpath,/public/home/liuyanlin/anaconda2/lib: /usr/bin/ld: skipping incompatible /usr/lib/../lib/libm.so when searching for -lm /usr/bin/ld: skipping incompatible /usr/lib/../lib/libc.so when searching for -lc /usr/bin/ld: warning: libicui18n.so.54, needed by /public/home/liuyanlin/anaconda2/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.8.5/../../../../lib/libboost_graph.so, not found (try using -rpath or -rpath-link) /public/home/liuyanlin/anaconda2/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.8.5/crt1.o: In function
_start': (.text+0x12): undefined reference to
libc_csu_fini' /public/home/liuyanlin/anaconda2/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.8.5/crt1.o: In function_start': (.text+0x19): undefined reference to
libc_csu_init' CMakeFiles/armatus.dir/Armatus.cpp.o: In function `boost::program_options::validation_error::validation_error(boost::program_options::validation_error::kind_t, std::string const&, std::string const&, int)': ...I added a parameter “-L/usr/lib/x86_64-redhat-linux5E/lib64” in link.txt and set up "ln /public/home/liuyanlin/anaconda2/lib/libicui18n.so.54.1 /public/home/liuyanlin/anaconda2/lib/libicui18n.so.54"
But still some part of the problem is not resolved
Linking CXX executable armatus cd /public/home/liuyanlin/download/armatus-2.2/src && /public/home/liuyanlin/anaconda2/bin/cmake -E cmake_link_script CMakeFiles/armatus.dir/link.txt --verbose=1 /public/home/liuyanlin/anaconda2/bin/c++ -O3 -g -std=c++11 -Wall -Wno-unused-local-typedefs -L/usr/lib/x86_64-redhat-linux5E/lib64 CMakeFiles/armatus.dir/Armatus.cpp.o CMakeFiles/armatus.dir/ArmatusUtil.cpp.o CMakeFiles/armatus.dir/ArmatusParams.cpp.o CMakeFiles/armatus.dir/ArmatusDAG.cpp.o CMakeFiles/armatus.dir/IntervalScheduling.cpp.o -o armatus -rdynamic -lboost_program_options-mt -lboost_iostreams -lboost_graph -lboost_system -lboost_regex -lz -Wl,-rpath-link,/public/home/liuyanlin/anaconda2/lib: /public/home/liuyanlin/anaconda2/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.8.5/crt1.o: In function
_start': (.text+0x12): undefined reference to
libc_csu_fini' /public/home/liuyanlin/anaconda2/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.8.5/crt1.o: In function_start': (.text+0x19): undefined reference to
libc_csu_init' CMakeFiles/armatus.dir/Armatus.cpp.o: In functionboost::program_options::validation_error::validation_error(boost::program_options::validation_error::kind_t, std::string const&, std::string const&, int)': /public/home/liuyanlin/anaconda2/include/boost/program_options/errors.hpp:373: undefined reference to
boost::program_options::validation_error::get_template(boost::program_options::validation_error::kind_t)' /public/home/liuyanlin/anaconda2/include/boost/program_options/errors.hpp:373: undefined reference toboost::program_options::error_with_option_name::error_with_option_name(std::string const&, std::string const&, std::string const&, int)' CMakeFiles/armatus.dir/Armatus.cpp.o: In function
boost::program_options::error_with_option_name::~error_with_option_name()': /public/home/liuyanlin/anaconda2/include/boost/program_options/errors.hpp:119: undefined reference tovtable for boost::program_options::error_with_option_name' CMakeFiles/armatus.dir/Armatus.cpp.o: In function
boost::program_options::validation_error::~validation_error()': /public/home/liuyanlin/anaconda2/include/boost/program_options/errors.hpp:119: undefined reference tovtable for boost::program_options::error_with_option_name' CMakeFiles/armatus.dir/Armatus.cpp.o: In function
boost::program_options::invalid_option_value::~invalid_option_value()': /public/home/liuyanlin/anaconda2/include/boost/program_options/errors.hpp:119: undefined reference tovtable for boost::program_options::error_with_option_name' CMakeFiles/armatus.dir/Armatus.cpp.o: In function
boost::program_options::error_with_option_name::~error_with_option_name()': /public/home/liuyanlin/anaconda2/include/boost/program_options/errors.hpp:119: undefined reference tovtable for boost::program_options::error_with_option_name' CMakeFiles/armatus.dir/Armatus.cpp.o: In function
boost::program_options::validation_error::~validation_error()': /public/home/liuyanlin/anaconda2/include/boost/program_options/errors.hpp:119: undefined reference tovtable for boost::program_options::error_with_option_name' CMakeFiles/armatus.dir/Armatus.cpp.o:/public/home/liuyanlin/anaconda2/include/boost/program_options/errors.hpp:119: more undefined references to
vtable for boost::program_options::error_with_option_name' follow CMakeFiles/armatus.dir/Armatus.cpp.o: In functionboost::program_options::basic_command_line_parser<char>::run()': /public/home/liuyanlin/anaconda2/include/boost/program_options/detail/parsers.hpp:108: undefined reference to
boost::program_options::detail::cmdline::get_canonical_option_prefix()' CMakeFiles/armatus.dir/Armatus.cpp.o: In functionmain': /public/home/liuyanlin/download/armatus-2.2/src/Armatus.cpp:55: undefined reference to
boost::program_options::options_description::options_description(std::string const&, unsigned int, unsigned int)' CMakeFiles/armatus.dir/Armatus.cpp.o: In functionboost::program_options::error_with_option_name::error_with_option_name(boost::program_options::error_with_option_name const&)': /public/home/liuyanlin/anaconda2/include/boost/program_options/errors.hpp:89: undefined reference to
vtable for boost::program_options::error_with_option_name' CMakeFiles/armatus.dir/Armatus.cpp.o: In functionerror_with_option_name': /public/home/liuyanlin/anaconda2/include/boost/program_options/errors.hpp:89: undefined reference to
vtable for boost::program_options::error_with_option_name' /public/home/liuyanlin/anaconda2/include/boost/program_options/errors.hpp:89: undefined reference tovtable for boost::program_options::error_with_option_name' /public/home/liuyanlin/anaconda2/include/boost/program_options/errors.hpp:89: undefined reference to
vtable for boost::program_options::error_with_option_name' /public/home/liuyanlin/anaconda2/include/boost/program_options/errors.hpp:89: undefined reference tovtable for boost::program_options::error_with_option_name' CMakeFiles/armatus.dir/Armatus.cpp.o:/public/home/liuyanlin/anaconda2/include/boost/program_options/errors.hpp:89: more undefined references to
vtable for boost::program_options::error_with_option_name' follow CMakeFiles/armatus.dir/Armatus.cpp.o:(.rodata._ZTVN5boost16exception_detail19error_info_injectorINS_15program_options20invalid_option_valueEEE[_ZTVN5boost16exception_detail19error_info_injectorINS_15program_options20invalid_option_valueEEE]+0x20): undefined reference toboost::program_options::error_with_option_name::what() const' CMakeFiles/armatus.dir/Armatus.cpp.o:(.rodata._ZTVN5boost16exception_detail19error_info_injectorINS_15program_options20invalid_option_valueEEE[_ZTVN5boost16exception_detail19error_info_injectorINS_15program_options20invalid_option_valueEEE]+0x30): undefined reference to
boost::program_options::error_with_option_name::substitute_placeholders(std::string const&) const' CMakeFiles/armatus.dir/Armatus.cpp.o:(.rodata._ZTVN5boost16exception_detail10clone_implINS0_19error_info_injectorINS_15program_options20invalid_option_valueEEEEE[_ZTVN5boost16exception_detail10clone_implINS0_19error_info_injectorINS_15program_options20invalid_option_valueEEEEE]+0x28): undefined reference toboost::program_options::error_with_option_name::what() const' CMakeFiles/armatus.dir/Armatus.cpp.o:(.rodata._ZTVN5boost16exception_detail10clone_implINS0_19error_info_injectorINS_15program_options20invalid_option_valueEEEEE[_ZTVN5boost16exception_detail10clone_implINS0_19error_info_injectorINS_15program_options20invalid_option_valueEEEEE]+0x38): undefined reference to
boost::program_options::error_with_option_name::substitute_placeholders(std::string const&) const' CMakeFiles/armatus.dir/Armatus.cpp.o:(.rodata._ZTVN5boost16exception_detail19error_info_injectorINS_15program_options16validation_errorEEE[_ZTVN5boost16exception_detail19error_info_injectorINS_15program_options16validation_errorEEE]+0x20): undefined reference toboost::program_options::error_with_option_name::what() const' CMakeFiles/armatus.dir/Armatus.cpp.o:(.rodata._ZTVN5boost16exception_detail19error_info_injectorINS_15program_options16validation_errorEEE[_ZTVN5boost16exception_detail19error_info_injectorINS_15program_options16validation_errorEEE]+0x30): undefined reference to
boost::program_options::error_with_option_name::substitute_placeholders(std::string const&) const' CMakeFiles/armatus.dir/Armatus.cpp.o:(.rodata._ZTVN5boost16exception_detail10clone_implINS0_19error_info_injectorINS_15program_options16validation_errorEEEEE[_ZTVN5boost16exception_detail10clone_implINS0_19error_info_injectorINS_15program_options16validation_errorEEEEE]+0x28): undefined reference toboost::program_options::error_with_option_name::what() const' CMakeFiles/armatus.dir/Armatus.cpp.o:(.rodata._ZTVN5boost16exception_detail10clone_implINS0_19error_info_injectorINS_15program_options16validation_errorEEEEE[_ZTVN5boost16exception_detail10clone_implINS0_19error_info_injectorINS_15program_options16validation_errorEEEEE]+0x38): undefined reference to
boost::program_options::error_with_option_name::substitute_placeholders(std::string const&) const' CMakeFiles/armatus.dir/Armatus.cpp.o:(.rodata._ZTIN5boost15program_options16validation_errorE[_ZTIN5boost15program_options16validation_errorE]+0x10): undefined reference totypeinfo for boost::program_options::error_with_option_name' CMakeFiles/armatus.dir/Armatus.cpp.o:(.rodata._ZTVN5boost15program_options16validation_errorE[_ZTVN5boost15program_options16validation_errorE]+0x20): undefined reference to
boost::program_options::error_with_option_name::what() const' CMakeFiles/armatus.dir/Armatus.cpp.o:(.rodata._ZTVN5boost15program_options16validation_errorE[_ZTVN5boost15program_options16validation_errorE]+0x30): undefined reference toboost::program_options::error_with_option_name::substitute_placeholders(std::string const&) const' CMakeFiles/armatus.dir/Armatus.cpp.o:(.rodata._ZTVN5boost15program_options20invalid_option_valueE[_ZTVN5boost15program_options20invalid_option_valueE]+0x20): undefined reference to
boost::program_options::error_with_option_name::what() const' CMakeFiles/armatus.dir/Armatus.cpp.o:(.rodata._ZTVN5boost15program_options20invalid_option_valueE[_ZTVN5boost15program_options20invalid_option_valueE]+0x30): undefined reference toboost::program_options::error_with_option_name::substitute_placeholders(std::string const&) const' /lib64//librt.so.1: undefined reference to
fortify_fail@GLIBC_PRIVATE' /lib64//libpthread.so.0: undefined reference to `vdso_clock_gettime@GLIBC_PRIVATE' collect2: error: ld returned 1 exit status make[2]: [src/armatus] Error 1 make[2]: Leaving directory `/public/home/liuyanlin/download/armatus-2.2' make[1]: [src/CMakeFiles/armatus.dir/all] Error 2 make[1]: Leaving directory `/public/home/liuyanlin/download/armatus-2.2' make: *** [all] Error 2Do you have any suggestions? Thank you!