linux 安裝報錯:pkg-config not found


linux 安裝報錯:pkg-config not found


 

使用編譯安裝時,在執行./configure時報如下錯誤:

...
...
checking for pkg-config... no
pkg-config not found
configure: error: Please reinstall the pkg-config distribution

提示,配置錯誤,請重新安裝pkg配置分發。

解決方法,根據提示,安裝pkg-config:

sudo apt-get install pkg-config

擴展知識:

關於pkg-config的簡介:

pkg-config is a helper tool used when compiling applications and libraries. It helps you insert the correct compiler options on the command line so an application can use gcc -o test test.c `pkg-config --libs --cflags glib-2.0` for instance, rather than hard-coding values on where to find glib (or other libraries). It is language-agnostic, so it can be used for defining the location of documentation tools, for instance.

翻譯:

PKG CONFIG是編譯應用程序和庫時使用的輔助工具。它幫助您在命令行中插入正確的編譯器選項,以便應用程序可以使用gcc-o test test.c'pkg-config--libs--cflags glib-2.0',例如,而不是硬編碼在哪里找到glib(或其他庫)的值。它是語言不可知的,因此它可以用來定義文檔工具的位置。


 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM