Date: Sun, 6 Sep 1998 13:24:37 -0400 (EDT) From: Chuck Robey <chuckr@glue.umd.edu> To: John Polstra <jdp@polstra.com> Cc: current@FreeBSD.ORG Subject: Re: nm Message-ID: <Pine.BSF.4.00.9809061321450.21019-100000@picnic.mat.net> In-Reply-To: <199809061753.KAA00153@austin.polstra.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, 6 Sep 1998, John Polstra wrote: > In article <Pine.BSF.4.00.9809061153520.21019-100000@picnic.mat.net>, > Chuck Robey <chuckr@glue.umd.edu> wrote: > > I notice that nm is one of those utils that has, like ld, completely > > different versions for aout and for elf. I just tried to use nm on an > > aout lib (choke, hack!) > > > > As a suggestion, does it seem reasonable to have a wrapper for nm such > > that it read ONLY the -elf or -aout flag, stripped it off, and then > > dispatched either the nm-elf or nm-aout tool? If there was neither flag > > in existence, it could look for OBJFORMAT in the environment, and if > > that failed, use /etc/objformat, else give an error message and die. > > I don't know what weird system you're running over there, but here's > the situation on mine: > > blake$ ls -li /usr/bin/{nm,objformat} > 55853 -r-xr-xr-x 9 bin bin 4420 Sep 4 16:36 /usr/bin/nm > 55853 -r-xr-xr-x 9 bin bin 4420 Sep 4 16:36 /usr/bin/objformat > blake$ ls -l /usr/libexec/{aout,elf}/nm > -r-xr-xr-x 1 bin bin 9168 Sep 4 16:36 /usr/libexec/aout/nm > -r-xr-xr-x 1 bin bin 157560 Sep 4 16:32 /usr/libexec/elf/nm > > In other words, your proposal was implemented long ago. Take a look > at the sources for "objformat". Dumb, I setenv'ed on one window and tried it in another. Decided it should have been done that way, so I suggested it. Aren't I prescient? What about installing the man pages for ld, which now conflict aout vs. elf, as ld-aout and ld-elf? Then setting maybe a softlink based upon the objformat, from ld to the real one? I've been caching away the ld-aout man page, to get at it. ----------------------------+----------------------------------------------- Chuck Robey | Interests include any kind of voice or data chuckr@glue.umd.edu | communications topic, C programming, and Unix. 213 Lakeside Drive Apt T-1 | Greenbelt, MD 20770 | I run Journey2 and picnic (FreeBSD-current) (301) 220-2114 | and jaunt (NetBSD). ----------------------------+----------------------------------------------- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.00.9809061321450.21019-100000>