LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch
User Name
Password
Linux From Scratch This Forum is for the discussion of LFS.
LFS is a project that provides you with the steps necessary to build your own custom Linux system.

Notices


Reply
  Search this Thread
Old 07-16-2018, 10:23 AM   #1
spenced
Member
 
Registered: Oct 2017
Posts: 43

Rep: Reputation: Disabled
general question about moving and linking libraries and installing new depends.


Hi all -

I've been working on a BLFS-systemd-201807012-dev version and have encountered this problem a few times (particularly when dealing with anything that wants to interact with Kerberos)

Many times in the in the install recipes I'm told to move the libraries to /lib from /usr/lib to make them available when /usr is not mounted, this makes it so when I go to new install new packages that they can't find the .so unless I go back and reinstall (kerberos), waiting to move the libraries until the new package is installed so they can be found and then moving them.

I've noticed that when making the new links to the moved libraries often multiple libraries are linked to one single .so file. How does this work?

How come new packages can't read the linked file properly? (it seems to me probably the same reason when I try to 'ls /foo.so' it replies 'not found')

Is there a way to force new packages to read the links so it knows where the libraries have been moved to -- so i don't have to go back back and reinstall the offending package? (i thought about making copies of the moved .so's but i don't think this the proper way.)

I have a general understanding of the difference between hard and soft links and how they are represented to the file system, but what are the particular practical reasons for using hard vs soft links?

Thanks!

spencer
 
Old 07-16-2018, 01:06 PM   #2
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,292

Rep: Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322
All the symlinks have to do with the way libraries are named in software. in a library foo.so.3.4.5
They mean (usually)
3 = a compatibility break from foo.so.2.x
4 = feature enhancement over foo.so.3.3.x
5 = a patch level or bug fix on foo.so.3.4.

Nobody, afaik, addresses the patch level; foo.so.3 suffices, unless you need the feature enhancements. When you run ldconfig, it sorts all those symlinks anyhow.

LFS is correct about /lib being supposed to be used for boot. But unix in ways is very last millenium - nobody had a terabyte hard disk then. If /usr doesn't have it's own partition (99.9999% of cases) it doesn't matter a hoot. Nowadays, my /home is bigger than my /, and that goes for most folks.
 
Old 07-17-2018, 01:34 PM   #3
spenced
Member
 
Registered: Oct 2017
Posts: 43

Original Poster
Rep: Reputation: Disabled
thanks for that! I kind of thought that about the reason for moving to /lib. Is there a particular reason when I go to build new packages that are looking for the libraries in the original /usr/lib/ location that they don't like following the link?
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
jdk SBo script , why ffmpeg libraries depends broken ? USUARIONUEVO Slackware 1 07-20-2016 03:56 PM
Statically linking to libraries lazylogik Linux - Newbie 1 07-06-2009 11:43 AM
Linking libraries. Gamma_User Linux - Newbie 1 01-19-2009 05:24 PM
linking static libraries??? birjodh Linux - General 1 06-07-2007 11:02 PM
Linking old libraries to new one? winterhunter Linux - Software 7 10-24-2005 04:37 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch

All times are GMT -5. The time now is 02:50 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration