原始碼編譯rrdtool提示找不到xxx.pc類問題處理
1. 問題現象
在Centos原始碼編譯rrdtool 出現一系列錯誤資訊,使用命令及報錯如下圖:
./configure --prefix=/usr/local/rrdtool
checking dbi/dbi.h usability... no
checking dbi/dbi.h presence... no
checking for dbi/dbi.h... no
checking rados/librados.h usability... no
checking rados/librados.h presence... no
checking for rados/librados.h... no
checking tcpd.h usability... no
checking tcpd.h presence... no
checking for tcpd.h... no
checking for glib_check_version in -lglib-2.0... no
checking for pkg-config... pkg-config
configure: WARNING:
----------------------------------------------------------------------------
* I found a copy of pkgconfig, but there is no glib-2.0.pc file around.
You may want to set the PKG_CONFIG_PATH variable to point to its
location.
----------------------------------------------------------------------------
configure: WARNING:
----------------------------------------------------------------------------
* I could not find a working copy of glib-2.0. Check config.log for hints on why
this is the case. Maybe you need to set LDFLAGS and CPPFLAGS appropriately
so that compiler and the linker can find libglib-2.0 and its header files. If
you have not installed glib-2.0, you can get it either from its original home on
ftp://ftp.gtk.org/pub/glib/2.28/
You can find also find an archive copy on
http://oss.oetiker.ch/rrdtool/pub/libs
The last tested version of glib-2.0 is 2.28.7.
LIBS=-lm
LDFLAGS=-Wl,--rpath -Wl,/usr/local/rrdtool/lib
CPPFLAGS=
----------------------------------------------------------------------------
checking for g_regex_new... no
checking if pcre is available to supply the missing regex support in glib... checking now ...
checking for pcre_compile in -lpcre... no
checking for pkg-config... (cached) pkg-config
configure: WARNING:
----------------------------------------------------------------------------
* I found a copy of pkgconfig, but there is no pcre.pc file around.
You may want to set the PKG_CONFIG_PATH variable to point to its
location.
----------------------------------------------------------------------------
configure: WARNING:
----------------------------------------------------------------------------
* I could not find a working copy of pcre. Check config.log for hints on why
this is the case. Maybe you need to set LDFLAGS and CPPFLAGS appropriately
so that compiler and the linker can find libpcre and its header files. If
you have not installed pcre, you can get it either from its original home on
get a newer glib and you will not need pcre at all
You can find also find an archive copy on
http://oss.oetiker.ch/rrdtool/pub/libs
The last tested version of pcre is x.x.x.
LIBS=-lm
LDFLAGS=-Wl,--rpath -Wl,/usr/local/rrdtool/lib
CPPFLAGS=
----------------------------------------------------------------------------
checking for pcre_compile... no
configure: error: you need either glib with g_regex support or libpcre to compile rrdtool.
2. 原因分析
編譯時從pkg-config目錄中沒有找到xxx.pc檔案,應該是相應xxx-devel 包沒有安裝
3. 處理辦法
使用yum命令安裝好相應devel包即可
yum install glib2-devel pcre-devel libpng-devel pango-devel cairo-devel libxml2-devel
相關文章
- lombok編譯遇到“找不到符號的問題”Lombok編譯符號
- lxml處理xml時的字元編碼問題XML字元
- JavaScript 如何正確處理 Unicode 編碼問題!JavaScriptUnicode
- JavaScript如何正確處理Unicode編碼問題!JavaScriptUnicode
- Python編解碼問題與文字檔案處理Python
- 用javac編譯servlet類出現問題Java編譯Servlet
- 軟體編碼階段遇到問題的處理辦法
- 編譯Spring原始碼的步驟及一些問題編譯Spring原始碼
- 轉(解決GLIBC_2.x找不到的編譯問題)編譯
- c++模板類的使用,編譯的問題C++編譯
- RRD起步3——用指令碼包裝RRDtool(譯)指令碼
- MySQL:亂碼問題處理流程MySql
- java處理中文亂碼問題Java
- Gradle 編譯警告亂碼問題Gradle編譯
- GCC編譯過程(預處理->編譯->彙編->連結)GC編譯
- SPI編譯問題編譯
- perl 編譯問題!編譯
- jive編譯問題編譯
- .net reflector 反編譯失敗 索引超出了陣列界限問題處理方法編譯索引陣列
- 原始碼編譯Vim 8原始碼編譯
- MongoDB(0)- 原始碼編譯MongoDB原始碼編譯
- 編譯Android原始碼編譯Android原始碼
- 編譯hibernate原始碼編譯原始碼
- Docker編譯Azerothcore原始碼Docker編譯原始碼
- Spring原始碼編譯Spring原始碼編譯
- ORACLE問題處理十個指令碼Oracle指令碼
- Linux 和 Windows 下編碼問題處理 codestyle 解決方法LinuxWindows
- 從原始檔到可執行檔案:原始檔的預處理、編譯、彙編、連結編譯
- 編譯總提示找不到符號,搞了一週多,快瘋了編譯符號
- Visual Studio 編譯專案失敗,提示找不到檔案編譯
- 【scikit-learn基礎】--『預處理』之 分類編碼
- codecs 編碼處理
- 【問題處理】MySQL忘記root密碼的處理辦法MySql密碼
- libmemcached編譯問題IBM編譯
- EBS form編譯問題ORM編譯
- 編譯FFMPEG原始碼的指令碼編寫案例編譯原始碼指令碼
- WebRTC研究 (一) 編譯原始碼Web編譯原始碼
- 原始碼編譯 apache2.4原始碼編譯Apache