codeblocks處理undefined reference to `pthread_create'
codeblocks處理undefined reference to `pthread_create'
困擾了半天,終於解決
如果使用命令列是 gcc 檔名.c -lpthread -o 生成檔名
首先看命令列是不是有問題,如果沒有,就按照以下步驟操作
首先看是否與我的錯誤相同

如果相同在工程上點選右鍵,選擇構建工程,如果是英文應該是build project
彈出如下頁面

選擇連結器設定(link compli...)
加上libpthread.so檔案,一般的路徑如下

新增後重新編譯工程,問題解決
執行成功頁面如下

困擾了半天,終於解決
如果使用命令列是 gcc 檔名.c -lpthread -o 生成檔名
首先看命令列是不是有問題,如果沒有,就按照以下步驟操作
首先看是否與我的錯誤相同

如果相同在工程上點選右鍵,選擇構建工程,如果是英文應該是build project
彈出如下頁面

選擇連結器設定(link compli...)
加上libpthread.so檔案,一般的路徑如下

新增後重新編譯工程,問題解決
執行成功頁面如下

相關文章
- undefined reference to錯誤的解決方法Undefined
- 處理 JS 中 undefined 的 7 個技巧JSUndefined
- Qt 訊號發射部分 undefined reference to錯誤QTUndefined
- g++連結報錯:undefined reference to typeinfo of xxxUndefined
- "undefined reference to strptime"之自己定義strptime函式Undefined函式
- C++:與C混合程式設計 CMake undefined reference toC++程式設計Undefined
- Citus 分散式 PostgreSQL 叢集 - SQL Reference(查詢處理)分散式SQL
- 【備忘】解決錯誤:undefined reference to `cv::imread(cv::String const&, int)‘Undefined
- codeblocks20.03漢化包|codeblocks20.03安裝教程BloC
- CodeBlocks配置OpenGL的方法BloC
- 從連結器的角度詳細分析g++報錯: (.text+0x24): undefined reference to `main'UndefinedAI
- VS Code/Code-Runner編譯C語言遇到undefined reference to XXX的一種解決辦法編譯C語言Undefined
- 多對一處理 和一對多處理的處理
- JSP 異常處理如何處理?JS
- logseq 隱藏/hide linked reference and unlinked referenceGseIDE
- Java referenceJava
- Python - ReferencePython
- share undefinedUndefined
- codeblocks執行時漢字變亂碼BloC
- Linux下編譯國標GB28181視訊推流元件EasyGBD報錯undefined reference to `xxxxxxxx@GLIBC_xxxxx‘解決Linux編譯元件Undefined
- 模板處理
- 平滑處理
- 字串處理字串
- 事件處理事件
- Event Reference(zt)
- 大創Reference
- GCDAsyncSocket_ReferenceGC
- null 和 undefinedNullUndefined
- 關於 UndefinedUndefined
- 解決codeblocks無法除錯的問題BloC除錯
- Python錯誤處理和異常處理(二)Python
- APM RUEI processor處理程式hang死處理方法
- Python資料處理(二):處理 Excel 資料PythonExcel
- Python影像處理丨5種影像處理特效Python特效
- webgl 影像處理2---影像畫素處理Web
- 【故障處理】ORA-600:[13013],[5001]故障處理
- Apache Beam,批處理和流式處理的融合!Apache
- Python 影像處理 OpenCV (6):影像的閾值處理PythonOpenCV
- Python 影像處理 OpenCV (7):影像平滑(濾波)處理PythonOpenCV