摘要: #include #include #include #include #include #include typedef struct{ int wrok;//线程间通信 标志位 信号灯 int data;//数据 int num; pthread_t rd;//读线程 pthread_t wr;//写线程 sem_t sem;//控制信号量 ... 阅读全文
posted @ 2019-02-25 18:08 ForMeDream 阅读(1296) 评论(0) 推荐(0) 编辑
摘要: gcc -c 只编译不连接 -o *.o(生成.o文件) ar crv name.a *.o *.o (ar 命令把 .o文件打包成 name.a 静态库) 测试 name.a -L 紧跟链接库的路径 -l 库名 -l 库名 阅读全文
posted @ 2019-02-25 17:47 ForMeDream 阅读(390) 评论(0) 推荐(0) 编辑