Linux应用编程示例
发布日期:2021-05-10 13:48:10 浏览次数:11 分类:精选文章

本文共 1390 字,大约阅读时间需要 4 分钟。

������������������������������������

������������������

���������������������������������������������-(pthread): Linux ���������������������������- (lrt): Linux ���������- (Wall): ���������������������������������- (string.h): ���������������������- (stdio.h): ���������������������������- (stdlib.h): ���������������- (unistd.h): ���������������������- (error.h): ������������- (errno.h): ���������������- (fcntl.h): ���������������������- (signal.h): ������������- (time.h): ������������������������������- (poll.h): ������I/O������������- (sys/ioctl.h): IOCTL ������- (sys/types.h): ������������������������- (sys/wait.h): ������������- (sys/stat.h): ���������������������- (sys/time.h): ������������

������������������

- ������������: Linux- ���������: GCC- ������������: - ������������: gcc -c -Wall -pthread -lrt - ������������������:gcc -o test test.o - ������������:rm test test.o

Makefile������������

```makefile# ������������������test: test.o gcc -o $@ $^ -pthread -lrt -Wall

���������������������

%.o:gcc -c -Wall -pthread $<

���������������������������������

clean:rm -f test test.o

������������������

���������������������C������������������������Linux���������������������������������������������������- ���������������������������������������������- ���������������������������������������������- ���������������������������������������������- ������������������������������
上一篇:lds链接脚本
下一篇:并发相关问题

发表评论

最新留言

表示我来过!
[***.240.166.169]2025年04月23日 22时07分28秒