我想在我的qt应用程序中添加两个外部库,并尝试了以下操作:

LIBS += -L/usr/local/lib \
-lopencv_core \
-lopencv_imgproc \
-lopencv_highgui \
-lopencv_ml \
-lopencv_video \
-lopencv_features2d \
-lopencv_calib3d \
-lopencv_objdetect \
-lopencv_contrib \
-lopencv_legacy \
-lopencv_flann

LIBS += -L/opt/intel/composer_xe_2011_sp1.9.293/ipp/lib/intel64 \

-lpthread \
-lippcv \
-lstdc++ \
-lippvc \
-liomp5 \
-lippac \
-lipps \
-lippsc \
-lippi \
-lipps \
-lippm \
-lippr \
-lippj \
-lippvm \
-lippcor


它给了我那个错误:

Parse Error ('-lippvc -liomp5 -lippac -lipps -lippsc -lippi -lipps -lippm -lippr -lippj -lippvm -lippcor')


我在网上看到一些示例,但是大多数示例仅针对一个库执行,或者使用完全不同的window进行。

谢谢

最佳答案

这与我合作:

 LIBS += -L/usr/local/lib -L/opt/intel/composer_xe_2011_sp1.9.293/ipp/lib/intel64
-lopencv_core \
-lopencv_imgproc \
-lopencv_highgui \
-lopencv_ml \
-lopencv_video \
-lopencv_features2d \
-lopencv_calib3d \
-lopencv_objdetect \
-lopencv_contrib \
-lopencv_legacy \
-lopencv_flann
-lpthread \
-lippcv \
-lstdc++ \
-lippvc \
-liomp5 \
-lippac \
-lipps \
-lippsc \
-lippi \
-lipps \
-lippm \
-lippr \
-lippj \
-lippvm \
-lippcor

关于qt - 如何将多个外部库添加到Qt creator .pro(ubuntu),我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/9563747/

10-11 16:23