automake
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Cross-compiling with automake


From: Ralf Wildenhues
Subject: Re: Cross-compiling with automake
Date: Mon, 6 Oct 2008 23:06:17 +0200
User-agent: Mutt/1.5.18 (2008-05-17)

Hello Thomas,

* Thomas Epperson wrote on Mon, Oct 06, 2008 at 12:41:19PM CEST:
> kernel_LDFLAGS = -nostdlib -lgcc -T $(srcdir)/x86/link.ld
> 
> I need to specify nostdlib and lgcc at the same time. But when I do it this
> way, lgcc gets ignored and the functions in it do not get linked in. I think
> this is a problem with the order in which nostdlib and lgcc are called.
> nostdlib gets caught in COLLECT_GCC_OPTIONS while lgcc gets passed to the
> collect2 program (output gathered from the -v flag).

I don't think your issue has to do with automake at all; it rather looks
like a GCC issue.  I can't tell if all you need is to use '-Wl,' or if
there is some limitation in the gcc driver that you need to work around.

> I can do away with the nostdlib option, but that causes undesired libraries
> to be linked in (which is bad).

Maybe --as-needed helps you (see the gnulib module lib-ignore for how to
use it portably).

Hope that helps.

Cheers,
Ralf




reply via email to

[Prev in Thread] Current Thread [Next in Thread]