成功地为QNX编译了gRPC,现在正在尝试构建这些示例。
构建命令:
cmake -DCMAKE_C_COMPILER=qcc -DCMAKE_CXX_COMPILER=q++ ../..
链接器错误:
[ 90%] Linking CXX executable greeter_client
[ 95%] Linking CXX executable greeter_async_client
[100%] Linking CXX executable greeter_async_server
/home/csa/src/qnx//host/linux/x86_64/usr/bin/x86_64-pc-nto-qnx7.1.0-ld: cannot find -lpthread
/home/csa/src/qnx//host/linux/x86_64/usr/bin/x86_64-pc-nto-qnx7.1.0-ld: cannot find -lpthread
/home/csa/src/qnx//host/linux/x86_64/usr/bin/x86_64-pc-nto-qnx7.1.0-ld: cannot find -lpthread
/home/csa/src/qnx//host/linux/x86_64/usr/bin/x86_64-pc-nto-qnx7.1.0-ld: cannot find -ldl
/home/csa/src/qnx//host/linux/x86_64/usr/bin/x86_64-pc-nto-qnx7.1.0-ld: cannot find -ldl
/home/csa/src/qnx//host/linux/x86_64/usr/bin/x86_64-pc-nto-qnx7.1.0-ld: cannot find -ldl
我找到了下面的链接,看起来这可能是-lpthread的cmake问题,但对于-ldl并不确定。https://gitlab.kitware.com/cmake/cmake/-/issues/21579
发布于 2022-07-21 01:47:06
https://stackoverflow.com/questions/73041617
复制相似问题