[BusyBox] static & shared lib

Lancelot lancelotice at gmail.com
Fri Aug 19 02:59:16 UTC 2005


hi, Rob
I had checked I lib under /export/fs. those libary files are all in
this directory.

ldd /sbin/init ==> list the follow messanges, and there are all in the lib .
/sbin/init: is setuid
        libm.so.0 => /lib/libm.so.0 (0x4000d000)
        libcrypt.so.0 => /lib/libcrypt.so.0 (0x40023000)
        libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x4003f000)
        libc.so.0 => /lib/libc.so.0 (0x4004e000)
        ld-uClibc.so.0 => /lib/ld-uClibc.so.0 (0x40000000)

On 8/9/05, Rob Landley <rob at landley.net> wrote:
> On Tuesday 09 August 2005 06:20, Lancelot wrote:
> > hi, all
> >
> > I am using intel iop80331 development board, and mount root file system by
> > NFS.
> >
> > If I built busybox in buildroot with static, I can work normal everytime.
> > But, when I built it with shared lib, I can only work normal on first
> > time when I mount the file system. And I used the follow command to
> > mount the file system.
> >
> > mount -t ext2 -o loop root_fs_arm.ext2 /exports/fs
> 
> Sounds like your mount is hiding your shared libraries somehow.  (Do they live
> under /export/fs?)
> 
> > Initializing random number generator... done.
> > Starting network...
> > a: applet not found!
> 
> Is your init script trying to call an applet named "a"?
> 
> > So, what's different between static and shared lib in busybox?
> > Is it the same as normal in linux ?
> 
> What's the alternative?
> 
> Yes, busybox is an executable.  Statically linked executables don't need
> external libraries (with the exception of the horror that is glibc
> dynamically loading a random library to do name resolution).  Dynamically
> linked executables need external libraries.
> 
> > can any one give me some kind of hint ?
> > I didn't what to do on next.
> 
> Throw in a dynamically linked "hello world" program at the failure point and
> make sure it's getting run.
> 
> Rob
>



More information about the busybox mailing list