编一个程序,需要用到pthread这个库,但是这个库不是c默认的库,所以要编译的时候加上-lpthread这个命令。我用的是netbeans,但是我看里面的makefile不知道写的是什么东东。于是我试图在properties'的c compiler里面添加addition options加上-lpthread但是没用。于是网上查了一下,知道应该在Linker的Libraries的里面的add options的other option加上-lpthread就可以了。
在用netbeans编写程序时-lpthread问题
NetBeans pthread
最新推荐文章于 2020-04-12 22:38:20 发布
本文介绍如何在NetBeans中正确配置pthread库以使用多线程功能。作者最初尝试在ccompiler的additionoptions中添加-lpthread未果,最终在Linker的Libraries的otheroptions中成功配置。
60万+

被折叠的 条评论
为什么被折叠?



