Ken Moffat wrote:
> On Sat, Feb 04, 2012 at 04:31:09PM -0600, Bruce Dubbs wrote:
>> Forwarding to lfs-dev.
>>
>> John Burrell wrote:
>>> Bruce - strictly lfs - sorry, but I'm not registered in lfs-support.
>>>
>>> I replaced module-init-tools with kmod.
>>>
>>> In the configure --libdir=/lib
>>>
>>> This means that kmod puts libkmod.pc in /lib/pkgconfig
>> Yes it does.
>>
>>> Of course, there are many ways to get the pc file into
>> > /usr/lib/pkgconfig, where it belongs.
>>> I did:
>>>
>>> sed -i 's|pkgconfigdir = $(libdir)/pkgconfig|pkgconfigdir =
>>> /usr/lib/pkgconfig|' \
>> Makefile.am
>>> autoreconf
>>>
>>> then as per the book.
>> I took a look at my development system and I also have
>> /lib/pkgconfig/libtirpc.pc.
>>
>> Should we just create /usr/lib/pkgconfig as a part of Section 6.5 and
>> then a symlink from /lib/pkgconfig -> ../usr/lib/pkgconfig in Section 6.6?
>>
>> -- Bruce
>>
> The symlink shouldn't be needed on BLFS! For libtirpc I use:
>
> ./configure --prefix=/usr # (plus my usual --enable-static=no)
> make
> make libdir=/lib pkgconfigdir=/usr/lib/pkgconfig install
> ln -sfv /lib/libtirpc.so /usr/lib
> # -f technically only required for reruns or failed script, but does
> # no harm.
>
> I don't have kmod source handy, so I can't tell if it will take an
> overide in the same way.
I used the following instructions:
liblzma_CFLAGS="-I/usr/include" \
liblzma_LIBS="-L/lib -llzma" \
zlib_CFLAGS="-I/usr/include" \
zlib_LIBS="-L/lib -lz" \
./configure --prefix=/usr --bindir=/sbin --libdir=/lib \
--sysconfdir=/etc --with-xz --with-zlib
# Note bindir
make
make pkgconfigdir=/usr/lib/pkgconfig install
for target in depmod insmod modinfo modprobe rmmod; do
ln -sv kmod /sbin/$target
# Note /sbin, not /bin
done &&
ln -sv ../sbin/kmod /bin/lsmod
The directory tree looks like:
# ls -R
.:
bin lib sbin usr
./bin:
lsmod
./lib:
libkmod.la libkmod.so libkmod.so.1 libkmod.so.1.3.0
./sbin:
depmod insmod kmod modinfo modprobe rmmod
./usr:
include lib share
./usr/include:
libkmod.h
./usr/lib:
pkgconfig
./usr/lib/pkgconfig:
libkmod.pc
./usr/share:
man
./usr/share/man:
man5 man8
./usr/share/man/man5:
depmod.d.5 modprobe.d.5 modules.dep.5
./usr/share/man/man8:
depmod.8 insmod.8 lsmod.8 modinfo.8 modprobe.8 rmmod.8
-----
The only file here that looks out of place is libkmod.la, which probably
needs to be in /usr/lib.
The libkmod.pc looks right:
prefix=/usr
exec_prefix=/usr
libdir=/lib
includedir=/usr/include
Name: libkmod
Description: Library to deal with kernel modules
Version: 4
Libs: -L${libdir} -lkmod
Libs.private: -L/lib -llzma -L/lib -lz
Cflags: -I${includedir}
however, should we move the lzma library to /lib?
> If it will, anything installing to
> /usr/lib/pkgconfig should be sane enough to create the directory if
> not already present. Or, for the /lib/pkgconfig symlink, did
> you all agree to merge everything into /usr while I was offline :-) ?
Definitely not.
-- Bruce
--
http://linuxfromscratch.org/mailman/listinfo/lfs-dev
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page