Shared libraries (was Re: Window system bashing (was Re: X11 bashing))
Guy Harris
guy at auspex.auspex.com
Mon May 13 04:53:30 AEST 1991
> I was talking this over with someone the other day who claimed
>that SunOs' more recent versions have "often used" utilities like /bin/ls
>statically linked because there were complaints of performance hits -
>can anyone confirm or deny this?
Unless they're thinking of some SunOS release that hasn't come out yet,
yes, I can completely deny it:
bootme% cat /etc/motd
SunOS Release 4.1.1 (MCDLCD60) #9: Wed Mar 27 18:23:07 PST 1991
bootme% file /usr/bin/ls
/usr/bin/ls: sparc pure dynamically linked executable
bootme% cd /usr/bin
bootme% file * | egrep -v \
'dynamically linked|symbolic link|shell script|Permission denied'
bar: sparc demand paged executable
hostname: sparc pure executable
ln: sparc pure executable
mv: sparc pure executable
rfuadmin: commands text
sh: sparc demand paged executable
sunview1: directory
tar: sparc demand paged executable
bootme% cd /usr/ucb
bootme% file * | egrep -v \
'dynamically linked|symbolic link|shell script|Permission denied'
rcp: sparc demand paged set-uid executable
("/bin" is, of course, a symbolic link to "/usr/bin", so there's no
point in looking at it). So the set of regular utilities that are
statically linked includes:
bar - beats me why it's statically linked, unless it's by
analogy to "tar"
hostname - it's run as part of the very early boot sequence,
before "/usr" is mounted, i.e. before any shared libraries
are available
sh - see "hostname"
tar, rcp - statically linked so they can be used to snarf shared
libraries from somewhere else if you trash them (definitely
true of "rcp", I think that was the reason for "tar" as well
but I'm not sure)
ln, mv - maybe the same as for "tar" and "rcp"
>Is "ldconfig" or whatever it's called still a dynamically linked file?]
bootme% file /usr/etc/ldconfig
/usr/etc/ldconfig: sparc pure dynamically linked executable
bootme% cd /usr/etc
bootme% file * | egrep -v \
'dynamically linked|symbolic link|shell script|Permission denied'
fsck: sparc demand paged executable
ifconfig: sparc demand paged executable
init: sparc demand paged executable
intr: sparc demand paged executable
mount: sparc demand paged executable
praudit: sparc pure executable
restore: sparc demand paged set-uid executable
update: sparc executable
yp: directory
More information about the Comp.unix.wizards
mailing list