Pkg-config is a tool to help you insert the correct compiler options on the command line when compiling applications and libraries.
Prepare Pkg-config for compilation:
GLIB_CFLAGS="-I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include" \
GLIB_LIBS="-lglib-2.0" \
CC="gcc ${BUILD64}" \
./configure --prefix=/usr \
--with-pc-path=/usr/share/pkgconfig
The meaning of the new configure option:
GLIB_CFLAGS="-I/usr/include/glib-2.0
-I/usr/libi64/glib-2.0/include",
GLIB_LIBS="-lglib-2.0"
Pkg-config no longer comes with Glib and because Pkg-config has not been installed itself it needs to be told where Glib is.
Compile the package:
make
To test the results, issue: make
check.
Install the package:
make install
On multilib builds the library direcory has been removed from the default search path of pkg-config. Set some environment variables to help set the path correctly in the future:
export PKG_CONFIG_PATH32="/usr/lib/pkgconfig" export PKG_CONFIG_PATH64="/usr/lib64/pkgconfig"
Export these variables to prevent any issues in the future.
cat >> /root/.bash_profile << EOF
export PKG_CONFIG_PATH32="${PKG_CONFIG_PATH32}"
export PKG_CONFIG_PATH64="${PKG_CONFIG_PATH64}"
EOF