Originally Posted by spiky0011
I have installed pkg-config when I run
it returns nothing. Is this correct?
That's interesting. I also had already installed pkg-config before starting my current BLFS system since pkg-config now is part of the LFS book. My PKG_CONFIG_PATH was probably like yours since it now is this...
$ echo $PKG_CONFIG_PATH
And that gets established by /etc/profile.d/qt.sh which functions to append that path to PKG_CONFIG_PATH. That script was created as part of the installation of Qt-4.8.3...
# Begin /etc/profile.d/qt.sh
pathappend /opt/qt/bin PATH
pathappend /opt/qt/lib/pkgconfig PKG_CONFIG_PATH
# End /etc/profile.d/qt.sh
Therefore, my PKG_CONFIG_PATH must have been like yours before I installed Qt-4.8.3. In other words, empty.
The LFS book doesn't mention anything about PKG_CONFIG_PATH (except as part of the configuration for installing Libpipeline). But the BLFS book mentions it explicitly as though it should already be set...
Originally Posted by The current BLFS book for pkg-config-0.27.1
The default setting for PKG_CONFIG_PATH is /usr/lib/pkgconfig:/usr/share/pkgconfig because of the prefix used to install pkg-config. You may add to PKG_CONFIG_PATH by exporting additional paths on your system where .pc files are installed.
I haven't had any problems of any kind related to this matter including when I installed makedepend. But I wonder if I should fix my PKG_CONFIG_PATH variable since there are .pc files located in /usr/lib/pkgconfig and /usr/share/pkgconfig. I could do that in /etc/profile. To me, it looks like something I should do.