我想在GCC C++链接器的杂项部分指定多条路径。
链接标志:
-Wl,-rpath=/home/cri/Libs1, -Wl,-rpath=/home/cri/Libs2
首先,它是工作的,但是当我添加第二个错误时,我会得到以下错误:
/usr/bin/ld: cannot find : No such file or directory
collect2: ld returned 1 exit status
make: *** [libmylib.so] Error 1
能帮我了解一下我做错了什么吗?
发布于 2015-11-04 02:15:41
您必须在两个标志之间删除逗号(我使用它时没有相同的符号):
-Wl,-rpath /home/cri/Libs1 -Wl,-rpath /home/cri/Libs2
那应该管用。
https://stackoverflow.com/questions/33519085
复制相似问题