编译我的C ++代码时出现了一个非常奇怪的错误。
情况:我有一个使用PCL,OpenCV,VTK,ANN ......的大项目,实际上是在Linux上工作。
现在,我试图在MAC OSX中设置项目,但是存在一些问题。我安装了所有需要的库,似乎所有依赖项都是链接的,但是当我尝试编译项目时会出现一些奇怪的错误:
/bin/sh: -c: line 0: syntax error near unexpected token `('
/bin/sh: -c: line 0: `/Library/Developer/CommandLineTools/usr/bin/c++ -DDISABLE_OPENNI -DEIGEN_USE_NEW_STDVECTOR -DEIGEN_YES_I_KNOW_SPARSE_MODULE_IS_NOT_STABLE_YET -DFLANN_STATIC -DvtkDomainsChemistry_AUTOINIT="1(vtkDomainsChemistryOpenGL2)" -DvtkRenderingContext2D_AUTOINIT="1(vtkRenderingContextOpenGL2)" -DvtkRenderingCore_AUTOINIT="3(vtkInteractionStyle,vtkRenderingFreeType,vtkRenderingOpenGL2)" -DvtkRenderingVolume_AUTOINIT="1(vtkRenderingVolumeOpenGL2)" -pg -g -I/usr/local/include/vtk-6.3 -I/usr/local/lib/ann_1.1.2/include -I/usr/local/include/pcl-1.6 -I/usr/local/include/eigen3 -I/usr/local/include -I/usr/local/Cellar/flann/1.8.4_1/include -I/usr/local/include/opencv vtkDomainsChemistry_AUTOINIT=1(vtkDomainsChemistryOpenGL2) vtkRenderingContext2D_AUTOINIT=1(vtkRenderingContextOpenGL2) vtkRenderingCore_AUTOINIT=3(vtkInteractionStyle,vtkRenderingFreeType,vtkRenderingOpenGL2) vtkRenderingVolume_AUTOINIT=1(vtkRenderingVolumeOpenGL2) -msse4.1 -mfpmath=sse -o CMakeFiles/Pipeline.dir/main.cpp.o -c /Users/ferran/ViCOROB/PROJECTS/Pipeline/main.cpp'
make[3]: /bin/sh: -c: line 0: syntax error near unexpected token `('
/bin/sh: -c: line 0: `/Library/Developer/CommandLineTools/usr/bin/c++ -DDISABLE_OPENNI -DEIGEN_USE_NEW_STDVECTOR -DEIGEN_YES_I_KNOW_SPARSE_MODULE_IS_NOT_STABLE_YET -DFLANN_STATIC -DvtkDomainsChemistry_AUTOINIT="1(vtkDomainsChemistryOpenGL2)" -DvtkRenderingContext2D_AUTOINIT="1(vtkRenderingContextOpenGL2)" -DvtkRenderingCore_AUTOINIT="3(vtkInteractionStyle,vtkRenderingFreeType,vtkRenderingOpenGL2)" -DvtkRenderingVolume_AUTOINIT="1(vtkRenderingVolumeOpenGL2)" -pg -g -I/usr/local/include/vtk-6.3 -I/usr/local/lib/ann_1.1.2/include -I/usr/local/include/pcl-1.6 -I/usr/local/include/eigen3 -I/usr/local/include -I/usr/local/Cellar/flann/1.8.4_1/include -I/usr/local/include/opencv vtkDomainsChemistry_AUTOINIT=1(vtkDomainsChemistryOpenGL2) vtkRenderingContext2D_AUTOINIT=1(vtkRenderingContextOpenGL2) vtkRenderingCore_AUTOINIT=3(vtkInteractionStyle,vtkRenderingFreeType,vtkRenderingOpenGL2) vtkRenderingVolume_AUTOINIT=1(vtkRenderingVolumeOpenGL2) -msse4.1 -mfpmath=sse -o CMakeFiles/Pipeline.dir/data.cpp.o -c /Users/ferran/ViCOROB/PROJECTS/Pipeline/data.cpp'
*** [CMakeFiles/Pipeline.dir/main.cpp.o] Error 2
make[3]: *** Waiting for unfinished jobs....
make[3]: *** [CMakeFiles/Pipeline.dir/data.cpp.o] Error 2
make[2]: *** [CMakeFiles/Pipeline.dir/all] Error 2
make[1]: *** [CMakeFiles/Pipeline.dir/rule] Error 2
我在互联网上搜索过,但我找不到任何针对此特定问题的参考资料。
有什么建议吗?