Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 26 Nov 2003 10:25:24 -0600
From:      "Matthew D. Fuller" <fullermd@over-yonder.net>
To:        slave-mike <slave-mike@rv1.dynip.com>
Cc:        Tim Kientzle <kientzle@acm.org>
Subject:   Re: HEADS UP: /bin and /sbin are now dynamically linked
Message-ID:  <20031126162524.GP12248@over-yonder.net>
In-Reply-To: <3FC3AAAE.70508@rv1.dynip.com>
References:  <20031123012222.GB11523@dragon.nuxi.com> <p06002003bbe5c0f30237@[10.0.1.2]> <20031123042635.GB677@saboteur.dek.spc.org> <3FC16644.7070005@acm.org> <20031124114006.GA60761@dragon.nuxi.com> <p06002002bbe7fd7ac23c@[128.113.24.47]> <20031124210748.GG15294@wombat.localnet> <20031124224144.GC67578@dragon.nuxi.com> <20031125160934.GH12248@over-yonder.net> <3FC3AAAE.70508@rv1.dynip.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Nov 25, 2003 at 02:17:02PM -0500 I heard the voice of
slave-mike, and lo! it spake thus:
> Would it be possible to get a copy of this script?
> 
> Please! :)

Oh, it's pretty simplistic.  It's actually on a box that's in the closet
right now, but I think this is an older working version:
---
liblist:
    @echo '==> Getting needed libraries'
    -@(cd ${SRCBASE}/bin && ldd ${BINFILES}) > liblist.raw
    -@(cd ${SRCBASE}/sbin && ldd ${SBINFILES}) >> liblist.raw
[ ... similar stuff for other dirs ... ]
    -@grep -v '^[a-z]' liblist.raw | awk '{print $$3}' | sort | uniq \
        | sed 's,^${SRCBASE},,' | sed 's,^/,,' > liblist.cooked
    -@echo >> liblist.cooked
    @tar -cf - -C ${SRCBASE} `cat liblist.cooked` \
        | tar -xvpf - -C ${DSTBASE}
    -@(cd ${SRCBASE}/usr/lib && install -c -m 444 pam_* ${DSTBASE}/usr/lib)
    @echo '<== Done libraries'
---

You'll note that I already manually slipped in the pam_* .so's, which is
one of those additional non-obvious "extra files" things that Garance
mentioned in the other message.  I could probably replace the whole
transformation pipeline with a few lines of actual scripted awk(1); I
just did it all inline in the Makefile because I was lazy.

${SRCBASE} is somewhere I DESTDIR='d an installworld previously, and
${DSTBASE} becomes (as a result of a bunch of other make targets, of
which this is one of the later ones) a dir I can tar up and untar
somewhere as /.


-- 
Matthew Fuller     (MF4839)   |  fullermd@over-yonder.net
Systems/Network Administrator |  http://www.over-yonder.net/~fullermd/

"The only reason I'm burning my candle at both ends, is because I
      haven't figured out how to light the middle yet"



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20031126162524.GP12248>