This is the mail archive of the crossgcc@sourceware.org mailing list for the crossgcc project.

See the CrossGCC FAQ for lots more information.


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: Error building ncurses.


On Wednesday 30 June 2010 22:00:04 Ben Greear wrote:
> 
> On 06/30/2010 12:53 PM, Yann E. MORIN wrote:
> > Ben, All,
> >
> > On Wednesday 30 June 2010 21:16:36 Ben Greear wrote:
> >> cg-ng build
> > [--SNIP--]
> >> I'm using arm-unknown-linux-gnueabi.  The only changes I made were to
> >> disable gcj and Fortran.
> >> Host system is 64-bit Fedora 11.
> >
> > OK.
> >
> >> The build.log had this at the bottom:
> > [--SNIP--]
> >> [ALL  ]    x86_64-build_redhat-linux-gnu-gcc ../objects/tic.o ../objects/dump_entry.o  -I../progs -I/home/greearb/tmp/cxt/targets/src/ncurses-5.7/progs
> >> -DHAVE_CONFIG_H -I/home/greearb/tmp/cxt/targets/src/ncurses-5.7/progs/../include -I. -I../include  -D_GNU_SOURCE -DNDEBUG -O2 --param
> >> max-inline-insns-single=1200 -static -L../lib -lncurses -L../lib -lncurses -dynamic  -ldl  -o tic
> >> [ALL  ]    /usr/bin/ld: cannot find -ldl
> >> [ALL  ]    collect2: ld returned 1 exit status
> >> [ERROR]    make[1]: *** [tic] Error 1
> >> [ALL  ]    make[1]: Leaving directory `/home/greearb/tmp/cxt/targets/arm-unknown-linux-gnueabi/build/build-ncurses-build-tic/progs'
> > [--SNIP--]
> >> As far as I can tell, I have lib dl installed fine:
> >> /lib/libdl-2.10.2.so
> >> /lib/libdl.so.2
> >> /lib64/libdl-2.10.2.so
> >> /lib64/libdl.so.2
> >> /usr/lib64/libdl.so
> >
> > Notice the '-static' on the command line? Do you have a libdl.a somewhere?
> > On my Debian, libdl is in package libc6-dev. Fedora should have it in a
> > similarly named package.
> Doesn't that -dynamic before -ldl change it back to use dynamic?

Not as I understand it. -static means to create a static executable. So
you have to have the required staric libs, of which libdl.
-dynamic is passed onto the Darwin linker (from the gc man page), which
is not used here, as we're not Darwinians. ;-]

> Anyway, glibc-static on Fedora installs some static libs, including libdl.a.
> I just installed that and I'm recompiling now.  I'll let you know how that goes.

Regarding your other mail, can we consider the issue resolved, then?

But static build is not required here, as tic for the build system is not
installed in the toolchain, and serves only to generate the target ncurses
static libs, that in turn are required to build gdb.

If we were to build tic as a dynamic executable, that'd solve the issue as
well, definitely. But strange that you be the first to hit the issue...

Regards,
Yann E. MORIN.

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'



--
For unsubscribe information see http://sourceware.org/lists.html#faq


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