Post-LFS Package management

Gerard Beekmans gerard at linuxfromscratch.org
Thu Jun 29 12:11:56 PDT 2000


> Do you link everything?  How do you keep the paths straight?  OK, so if you
> link everything - how do you know which links to delete if you uninstall a
> package?

I create links rarely. I just add this line to /etc/profile
PATH=$PATH:/usr/package/bin

and to /etc/ld.so.conf:
/usr/package/lib

In case of libraries it's easier to have them in /usr/lib and
/usr/include, so I create symlinks:
cd /usr/lib
ln -s ../packagename/lib/* .

Right now if I have to uninstall a library package which files are
linked in /usr/lib and /usr/include I have to look in
/usr/packagename/lib and /usr/packagename/include to find which files it
has and remove the symlinks with the same names in /usr/lib and
/usr/include. I could write a script to do this (do a ls
/usr/package/lib and pipe it's output to the rm command. Or pipe it's
output to xargs and run rm on the list from xargs. Or whatever. I
haven't done it so I don't know what the best way is. Since I rarely
uninstall a library like zlib, libpng, libtiff, libgiff, libjpeg, I
don't have such a script and I don't have a need for it yet).

It may seem annoying having to edit a few files when uninstalling a
package (like /etc/profile, /etc/ld.so.conf, look in
/usr/packagename/lib and see if there are symlinks in /usr/lib with the
same name, etc) but I do prefer this way. Personally I think this little
extra trouble is worth it.

-- 
Gerard Beekmans
www.linuxfromscratch.org

-*- If Linux doesn't have the solution, you have the wrong problem -*-
--
Mail archive: http://www.pcrdallas.com/mail-archives/lfs-discuss
IRC access: server: irc.linuxfromscratch.org port: 6667 channel: #LFS
Unsubscribe: email lfs-discuss-request at linuxfromscratch.org and put
"unsubscribe" (without the quotation marks) in the body of the message
(no subject is required)



More information about the lfs-dev mailing list