This is the mail archive of the libc-help@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: C Start-Up shared vs static


On Friday 04 December 2009 19:48:21 Charles Coldwell wrote:
> On Dec 4, 2009, at 5:32 PM, Mike Frysinger wrote:
> > On Friday 04 December 2009 15:40:25 Charles Coldwell wrote:
> >> Inspired by what I read in the linker script /usr/lib/libc.so.6, I
> >> tried
> >> replacing "-lc" in the command line above with
> >>
> >> /Volumes/cross/arm-none-linux/lib/libc.so.6
> >> /Volumes/cross/arm-none-linux/usr/lib/libc_nonshared.a
> >> --as-needed
> >> /Volumes/cross/arm-none-linux/lib/ld-linux.so.2
> >> --no-as-needed
> >>
> >> This works, and builds an executable that runs on my target
> >> system.  So it
> >> would appear that all the binaries are in the right places, and
> >> contain
> >> the right bits, but the gcc driver routines aren't using them
> >> correctly.
> >> Could this be a problem in gcc specs?
> >
> > more likely a problem with your install and/or configure.  your
> > /Volumes/cross/arm-none-linux/ needs to be configured as the
> > toolchain's
> > sysroot.
> 
> Oh, but in the part of my message above that you snipped was the
> complete command
> 
> And doesn't the "--sysroot=/Volumes/cross/arm-none-linux" switch on
> the collect2 command above do what you recommend?

so see what the linker is doing.  it should parse the linker script and load 
all of the libraries you need so you dont need to
-mike

Attachment: signature.asc
Description: This is a digitally signed message part.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]