Re: Question: Finding libraries that are required for busybox??

2018-06-26 Thread Eli Schwartz
On 06/26/2018 07:37 AM, Walter Harms wrote: > there is no static version of gnu-libc. There is absolutely a libc.a provided by GNU libc, and you can statically link it on account of it's a static library. I'm looking at it right now, along with the binaries which are, successfully, statically

Re: Question: Finding libraries that are required for busybox??

2018-06-26 Thread Eli Schwartz
On 06/25/2018 11:01 PM, Michael D. Setzer II wrote: > I went ahead and built a static version of busybox, but it increase the size > by > about 900K. > > -rwxr-xr-x. 1 root root 1280672 Jun 26 08:46 busybox > -rwxr-xr-x. 1 root root 383700 Jun 26 08:12 busybox.save It's expected that static

Re: Question: Finding libraries that are required for busybox?? Found something.

2018-06-26 Thread Michael D. Setzer II
busybox@busybox.net Subject: Re: Question: Finding libraries that are required for busybox?? > Am 25.06.2018 22:40, schrieb Eli Schwartz: > > On 06/25/2018 04:30 PM, Michael D. Setzer II wrote: > >> Thanks for all the quick reponses. Tried the options, but am jus

Re: Question: Finding libraries that are required for busybox??

2018-06-25 Thread Michael D. Setzer II
On 25 Jun 2018 at 16:35, Jody Bruchon wrote: Subject:Re: Question: Finding libraries that are required for busybox?? To: busybox@busybox.net From: Jody Bruchon Date sent: Mon, 25 Jun 2018 16:35:57 -0400 > libc.so.6 is the o

Re: Question: Finding libraries that are required for busybox??

2018-06-25 Thread Eli Schwartz
On 06/25/2018 04:30 PM, Michael D. Setzer II wrote: > Thanks for all the quick reponses. Tried the options, but am just seeing a > link > to libc.so.6 and no other libraries?? So your busybox binary is not statically linked. That doesn't really change anything. If your project depends on GNU

Re: Question: Finding libraries that are required for busybox??

2018-06-25 Thread Jody Bruchon
libc.so.6 is the only thing that's linked to your binary directly; the other libraries can't be detected in these ways so you won't see them. On 6/25/2018 4:30 PM, Michael D. Setzer II wrote: On 25 Jun 2018 at 15:30, Eli Schwartz wrote: Subject:Re: Question: Finding libraries

Re: Question: Finding libraries that are required for busybox??

2018-06-25 Thread Michael D. Setzer II
On 25 Jun 2018 at 15:30, Eli Schwartz wrote: Subject:Re: Question: Finding libraries that are required for busybox?? To: busybox@busybox.net From: Eli Schwartz Date sent: Mon, 25 Jun 2018 15:30:21 -0400 > On 06/25/2018 03:20 PM, Jody Bruchon wrote: > > By the way

Re: Question: Finding libraries that are required for busybox??

2018-06-25 Thread Eli Schwartz
On 06/25/2018 03:20 PM, Jody Bruchon wrote: > By the way, you can also grab the relocations directly from the > binary with this horrific expression (replace the path as needed): > > readelf -d /bin/busybox | sed 's/.*\[\([^]]*\)]/\1/' > > Scary but effective. That's some very complicated sed

Re: Question: Finding libraries that are required for busybox??

2018-06-25 Thread Jody Bruchon
That's a glib-specific issue. The network resolver loads the libnss_* files on demand based on the contents of /etc/nsswitch.conf and there is no way I'm aware of to probe for such on-demand loads (though I'm sure a way exists, it's probably unpleasant.) In my experience, this is limited to

Re: Question: Finding libraries that are required for busybox??

2018-06-25 Thread Laurent Bercot
Using busybox nslookup failed due to one of the libraries I had removed not being there? libnss_dns and libnss_files. ldd busybox doesn't report these libraries are used? Once I put those libraries back, the nslookup resolves. That's because those shared libraries are not used at build

Re: Question: Finding libraries that are required for busybox??

2018-06-25 Thread Eli Schwartz
On 06/25/2018 03:01 PM, Michael D. Setzer II wrote: > Ran into a problem when trying to clean up libraries that were not needed > within my project. > > Had done an ldd command on all programs and libraries, and created a list. > A number of libraries I had in project were not linked to any

Re: Question: Finding libraries that are required for busybox??

2018-06-25 Thread Mattias Schlenker
Am 25.06.2018 um 21:01 schrieb Michael D. Setzer II: Using busybox nslookup failed due to one of the libraries I had removed not being there? libnss_dns and libnss_files. ldd busybox doesn't report these libraries are used? Once I put those libraries back, the nslookup resolves. Is there a way