在Ubuntu 16.04 VBox上安装SUMO(https://github.com/eclipse/sumo)的过程中,我要构建时遇到错误(当我使用make时出现错误):
[ 80%] Built target _libsumo
[ 80%] Linking CXX shared module ../../../../bin/liblibsumojni.so
/usr/lib/java/bin/javac: 1: /usr/lib/java/bin/javac: Syntax error: word unexpected (expecting ")")
src/libsumo/CMakeFiles/libsumojni.dir/build.make:147: recipe for target '../../bin/liblibsumojni.so' failed
make[2]: *** [../../bin/liblibsumojni.so] Error 2
make[2]: *** Deleting file '../../bin/liblibsumojni.so'
CMakeFiles/Makefile2:1484: recipe for target 'src/libsumo/CMakeFiles/libsumojni.dir/all' failed
make[1]: *** [src/libsumo/CMakeFiles/libsumojni.dir/all] Error 2
Makefile:160: recipe for target 'all' failed
make: *** [all] Error 2
有任何建议吗?谢谢!
您的Java版本可能有问题。除非您确实需要这些Java绑定,否则可以在调用cmake时将其禁用,如下所示:
cmake -DENABLE_JAVA_BINDINGS=OFF ../..
((假设您有一个类似doc的build / cmake-build这样的构建目录)。