glib:
lipl@bogon:opt$ wget http://ftp.gnome.org/pub/gnome/sources/glib/2.52/glib-2.52.0.tar.xz
lipl@bogon:opt$ tar -Jvxf glib-2.52.0.tar.xz
lipl@bogon:glib-2.52.0$ ./configure --enable-libmount=no # 这里可能会遇到一些错误,(依赖其它包),下文中有一些解决方案 ,
一开始是./configure是不带参数的,但是报找不到libmount的错误,centOS6.8找不到对应的解决方案,因而采取规避的方式(目前还不清楚会造成什么影响)
在./configure时遇到以下问题
错误一:libffi
checking for LIBFFI... no
configure: error: Package requirements (libffi >= 3.0.0) were not met:
No package 'libffi' found
lipl@bogon:glib-2.52.0$ sudo yum install libffi-devel
错误二:gettext
configure: error:
*** You must have either have gettext support in your C library,or use the
*** GNU gettext library. (http://www.gnu.org/software/gettext/gettext.html
解决方案:
lipl@bogon:opt$ wget http://ftp.gnu.org/pub/gnu/gettext/gettext-0.19.tar.gz
lipl@bogon:opt$ tar -zvxf gettext-0.19.tar.gz
lipl@bogon:opt$ cd gettext-0.19
lipl@bogon:opt$ ./configure
lipl@bogon:opt$ make
lipl@bogon:opt$ sudo make install
错误三:libmount
checking for libmount/libmount.h... no
configure: error: *** Could not find libmount
解决方案
错误四:libpcre
configure: error: Package requirements (libpcre >= 8.13) were not met:
No package 'libpcre' found
解决方案
lipl@bogon:opt$ wget ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/pcre-8.40.tar.gz
lipl@bogon:opt$ tar -zvxf pcre-8.40.tar.gz
lipl@bogon:opt$ cd pcre-8.40
lipl@bogon:pcre-8.40$ ./configure
lipl@bogon:pcre-8.40$ make
lipl@bogon:pcre-8.40$ sudo make install
安装完执行glib的./configure --enable-libmount=no
,发现还是找不到libpcre. 但是pcre-config和pcretest都显示pcre-8.40版本了
执行
lipl@bogon:glib-2.52.0$ export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig
重新执行glib的./configure --enable-libmount=no
, 报以下错误
checking for Unicode support in PCRE... no
configure: error: *** The system-supplied PCRE does not support Unicode properties or UTF-8.
解决方案
重新对pcre进行configure
./configure --enable-utf8 --enable-unicode-properties
make
sudo make install