关于linux下多线程编程。我在usr⼀include下找到了pthread.h头文件。但是在编译的时候报错。错误提醒如下

2025-02-24 14:31:14
推荐回答(1个)
回答1:

不需要找到pthread.h头文件
在编译的时候要链上pthread库,即加上-lpthread参数.