codeblocks编译pthread多线程问题
默认的编译选项是没有pthread的,所以要自己添加:
参考:http://hi.baidu.com/u_soa/item/9d6cc40b7e9d76eb3499024d
错误:
undefined reference to 'pthread_create'
解决:
Project -> Build options -> Linker settings -> Link libraries 里加上pthread
大悲无泪--大悟无言--大笑无声