CGAL演示没有运行

时间:2017-03-07 22:05:33

标签: makefile cmake cgal fpic qglviewer

我已经尝试了一段时间让他们工作。安装库(通过tarball)并通过cmake-gui安装我发现需要的每个依赖项后,我设法制作了示例和一些2D演示。

我可以运行三角测量和多边形演示,但是当我尝试制作多面体演示时,它会达到13%并且会抛出以下错误:

Scanning dependencies of target scene_polyhedron_item
[ 13%] Building CXX object CMakeFiles/scene_polyhedron_item.dir/Scene_polyhedron_item.cpp.o
[ 13%] Building CXX object CMakeFiles/scene_polyhedron_item.dir/scene_polyhedron_item_automoc.cpp.o
Linking CXX shared library libscene_polyhedron_item.so
/usr/bin/ld: /usr/local/lib/x86_64-linux-gnu/libCGAL.a(all_files.cpp.o): relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a shared object; recompile with -fPIC
/usr/local/lib/x86_64-linux-gnu/libCGAL.a: error adding symbols: Bad value
collect2: error: ld returned 1 exit status
make[2]: *** [libscene_polyhedron_item.so] Error 1
make[1]: *** [CMakeFiles/scene_polyhedron_item.dir/all] Error 2
make: *** [all] Error 2

我搜索了类似的错误,但我似乎无法将任何答案复制到此。我尝试在CMakeLists.txt上添加-fPIC标志,错误仍然存​​在。

使用cmake-gui(我得到其他所有工作)我注意到只缺少QGLViewer-debug包。我试图找到它无济于事,并且无法理解如何制作包的第二个副本以使其成为调试版本,并且也无法理解如何将包的正常版本转换为debuf版本。而且我也没有看到这与错误本身有什么关系。

作为旁注,AABB树示例启动时出现Seg Faults,cmake / make区域没有错误。

到目前为止,我不知道该怎么做。我真的需要在这台计算机上看到3D演示,以确保我可以使用这个库。

0 个答案:

没有答案
相关问题