Saturday, June 21, 2008

Jhalfs Primitive Package Management

Building BLFS packages with jhalfs is not generally easier than building them by hand. It may actually be harder. It requires the skills learned through building LFS and BLFS manually. It requires investigating how jhalfs works. It also requires the determination to enhance and/or debug the scrips generated by jhalfs. Even so, I am excited by the possibility of using jhalfs as a primitive package management tool. The packages that have been successfully installed through jhalfs are recorded in a tracking dir which is /var/lib/jhalfs/BLFS/ by default. This information is used as a component of jhalfs' dependency solving method. It also provides a quick reference of which BLFS packages have been installed.

Today, I used jhalfs to install cups, xpdf, and hal. To get cups and xpdf installed, I edited the scripts relying heavily on the notes in the post on Installing Common Unix Printing System for hp deskjet 3320 on LFS

Getting hal installed also required some editing of the the scripts. One reward for correctly installing hal is that now, the regular user can shut down the computer from within xfce without having to use sudo to do it. That is one of the things that Hal takes care of.

A minor detail to look out for is that some software would install a bootscript in the /etc/rc.d/init.d/ directory. It is necessary to edit that script to change directory to the location of the blfs-bootscripts-20060910 directory before doing that last make install-whatever, e.g., "make install-haldaemon". It is that dash plus word following "make install" that is the clue when this is necessary.

Also, some packages would install some optional documentation that may be built with some optional tools, and for me, those kinds of things bombed out. So, I commented out the lines that tried to install the optional stuff that I can live without.

The primary intent is to have all the scripts finish cleanly and record the installation of the package(s) in the tracking dir. The jhalfs documentation states that this is not to be relied upon and time will tell whether this idea is useful or not.


HAL XFCE SHUTDOWN TWEAKS
I expected there to be a fun problem to solve -- and there was! Xfce was still requiring sudo to shutdown and there was a message on the console saying: xfsm-shutdown-helper HAL not available ... bla bla

Based on faq [Xfce wiki] which indicates:
Your /etc/dbus-1/system.d/hal.conf should contain a section similar to this:

<policy group="halusers">
<allow send_interface="org.freedesktop.Hal.Device.SystemPowerManagement"/>
</policy>

And based on the mention that the user should be added to HAL users group, which in BLFS is halusers:x:61:, I added the user to the halusers group and put the section in etc/dbus-1/system.d/hal.conf.
That note in the faq [Xfce wiki] didn't help. The BLFS instructions for HAL put that code in the file /etc/dbus-1/system.d/halusers.conf instead.

What was really needed was to rebuild xfce4-session-4.4.1 with:
./configure --prefix=/usr --sysconfdir=/etc --enable-dbus
make
make install

On an LFS system, you can do that kind of fine-grained work. On many other systems -- they don't allow you.

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

Click blog title for the latest post