[Clfs-dev] Util-linux and libudev

William Harrington kb0iic at berzerkula.org
Sun Mar 9 12:16:25 PDT 2014


On Mar 8, 2014, at 11:18 AM, William Harrington wrote:

> Greetings,
>
> Right now, util-linux installs two binaries findmnt and lsblk.  
> Without udev support, those binaries won't output UUID information.
>
> LFS had to make a change and build util-linux in /tools and use that  
> for ch6 systemd/udev/eudev build. Then build util-linux after  
> systemd/udev/eudev for libudev support.
>
> We already have util-linux in tools with the boot section or chroot.  
> So for clfs git systemd or master branch, eudev would need the  
> following:
>
> KILL=/bin/kill HAVE_BLKID=1 BLKID_LIBS="-lblkid" BLKID_CFLAGS="-I/ 
> tools/include/blkid"
>
> Or set PKG_CONFIG_PATH=/tools/lib/pkgconfig
> and
>
> sed -i "s:blkid/::" src/udev/udev-builtin-blkid.c
> And we need to move util-linux after final-system systemd/eudev in  
> the master/systemd branches.
> Sincerely,
> William Harrington
> _______________________________________________
> Clfs-dev mailing list
> Clfs-dev at lists.cross-lfs.org
> http://lists.cross-lfs.org/listinfo.cgi/clfs-dev-cross-lfs.org

Okay I have had a successful build with the x86_64-64 book regarding  
the changes required to using libblkid from tools for e2fsprogs and  
systemd and moving util-linux after systemd and dbus. And added test  
suite commands for systemd.

Of course we'll need to adjust some commands for the multilib books.

For e2fsprogs:

sed -i -e 's|^LD_LIBRARY_PATH.*|&:/tools/lib|' tests/test_config
LIBS=-L/tools/lib CFLAGS="-I/tools/include" PKG_CONFIG_PATH=/tools/lib/ 
pkgconfig ../configure.........

For systemd:

cat > config.cache << "EOF"
KILL=/bin/kill
HAVE_BLKID=1
BLKID_LIBS="-L/tools/lib -lblkid"
BLKID_CFLAGS="-I/tools/include/blkid"
EOF

sed -i "s:blkid/::" src/udev/udev-builtin-blkid.c   (before configure)

sed -i s:test/udev-test.pl::g Makefile (for a test suite failure  
before make -k check)
make -k check

And then for util-linux after systemd and dbus:

Same commands except this time it'll link against libudev and will  
include addition information for UUID and other output for findmnt and  
lsblk.

You can refer to the LFS systemd branch book and look at ch6 e2fsprogs  
and systemd builds to see what I am talking about for changes  
utilizing /tools/lib/liblkid.  I did also adjust Systemd commands to  
not use LIBRARAY_PATH=/tools/lib make and instead set BLKID_LIBS="-L/ 
tools/lib -lblkid"

For Dbus: I may replace that this package does not have a test suite  
text to state that there is a test suite but requires additional  
packages from cblfs or so. But since cblfs is quite old, I don't know  
if our current version of dbus is the same or needs updated for  
required packages supporting the dbus test suite. I can refer to BLFS  
for that at the moment.

Any suggestions are requested. I plan to make the changes sometime  
today or tomorrow after I test a multilib build.

Sincerely,

William Harrington



More information about the Clfs-dev mailing list