我很新鲜。我尝试在Cygwin下使用CGAL。 CGAL似乎安装成功,但无法编译任何示例, 当我试图'cmake'时。 (成功) - > 'make'(失败) 他们跟我炸弹,
make
Scanning dependencies of target delaunay
[100%] Building CXX object CMakeFiles/delaunay.dir/delaunay.cpp.o
In file included from /home/JIN/CGAL-4.4/examples/Core/../../include/CGAL/CORE/CoreDefs.h:41:0,
from /home/JIN/CGAL-4.4/examples/Core/../../include/CGAL/CORE/CORE.h:39,
from /home/JIN/CGAL-4.4/examples/Core/../../include/CGAL/CORE_coercion_traits.h:33,
from /home/JIN/CGAL-4.4/examples/Core/../../include/CGAL/CORE_Expr.h:29,
from /home/JIN/CGAL-4.4/examples/Core/delaunay.cpp:2:
/home/JIN/CGAL-4.4/examples/Core/../../include/CGAL/CORE/extLong.h:171:8: warning: ‘CORE::extLong::extLong(int)’ redeclared without dllimport attribute after being referenced with dll linkage [enabled by default]
inline extLong::extLong(int i) : val(i), flag(0) {
^
/home/JIN/CGAL-4.4/examples/Core/../../include/CGAL/CORE/extLong.h:292:13: warning: ‘bool CORE::extLong::isNaN() const’ redeclared without dllimport attribute after being referenced with dll linkage [enabled by default]
inline bool extLong::isNaN() const {
^
In file included from /home/JIN/CGAL-4.4/examples/Core/../../include/CGAL/CORE/BigFloat.h:38:0,
from /home/JIN/CGAL-4.4/examples/Core/../../include/CGAL/CORE/RealRep.h:38,
from /home/JIN/CGAL-4.4/examples/Core/../../include/CGAL/CORE/Real.h:40,
from /home/JIN/CGAL-4.4/examples/Core/../../include/CGAL/CORE/ExprRep.h:42,
from /home/JIN/CGAL-4.4/examples/Core/../../include/CGAL/CORE/Expr.h:42,
from /home/JIN/CGAL-4.4/examples/Core/../../include/CGAL/CORE/CORE.h:68,
from /home/JIN/CGAL-4.4/examples/Core/../../include/CGAL/CORE_coercion_traits.h:33,
from /home/JIN/CGAL-4.4/examples/Core/../../include/CGAL/CORE_Expr.h:29,
from /home/JIN/CGAL-4.4/examples/Core/delaunay.cpp:2:
/home/JIN/CGAL-4.4/examples/Core/../../include/CGAL/CORE/BigFloatRep.h:266:8: warning: ‘CORE::BigFloatRep::BigFloatRep(const CORE::BigInt&, long unsigned int, long int)’ redeclared without dllimport attribute after being referenced with dll linkage [enabled by default]
inline BigFloatRep::BigFloatRep(const BigInt& I, unsigned long er, long ex)
^
/home/JIN/CGAL-4.4/examples/Core/../../include/CGAL/CORE/BigFloatRep.h:362:13: warning: ‘bool CORE::BigFloatRep::isZeroIn() const’ redeclared without dllimport attribute after being referenced with dll linkage [enabled by default]
inline bool BigFloatRep::isZeroIn() const {
^
make[2]: *** No rule to make target '/usr/local/lib/cygCGAL_Core-10.dll', needed by 'delaunay.exe'. Stop.
CMakeFiles/Makefile2:63: recipe for target 'CMakeFiles/delaunay.dir/all' failed
make[1]: *** [CMakeFiles/delaunay.dir/all] Error 2
Makefile:75: recipe for target 'all' failed
make: *** [all] Error 2
我根本不知道。 请帮我。非常感谢!!!!
答案 0 :(得分:0)
我不完全确定我的答案,但似乎在使用CMake在/home/JIN/CGAL-4.4/examples/Core/
内配置示例时,您已指定/home/JIN/CGAL-4.4/config
作为{{1}的值变量。该目录包含安装CGAL后要使用的文件CGAL_DIR
。相反,您应该使用CGALConfig.cmake
作为/home/JIN/CGAL-4.4
的值。该目录包含CGAL_DIR
文件,该文件必须用于使用CGAL的就地构建树,而无需安装。