libtool
[Top][All Lists]
Advanced

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

gcc -m* & libtool


From: Bob Friesenhahn
Subject: gcc -m* & libtool
Date: Mon, 25 Nov 2002 10:03:33 -0600 (CST)

A week ago I popped this into development libtool:

2002-11-18  Bob Friesenhahn  <address@hidden>

        * ltmain.in: When using gcc, pass -mfoo to the linker
        via $compiler_flags in order to pass architecture information to
        the linker (e.g. 32 vs 64-bit). This may also be accomplished via
        -Wl,-mfoo but this is not reliable with gcc because gcc may use
        -mfoo to select a different linker, different libraries, etc, while
        -Wl,-mfoo simply passes -mfoo to the linker. If there is a better
        solution, please let me know what it is.

Note that this passes -mfoo arguments to the compiler at link-time to
ensure/allow a consistent ABI to be requested across the compile and
link phases.  This scheme works well with Autoconf since the user can
configure a project like

  ./configure CFLAGS=-mfoo LDFLAGS=-mfoo

and everything works.

It is just as easy to pop this update out of libtool as it was to pop
it in, so if there is a better way to accomplish this that works
reliably across an entire project built with GCC, Autoconf, and
libtool, please let me know.

Thanks,

Bob
======================================
Bob Friesenhahn
address@hidden
http://www.simplesystems.org/users/bfriesen





reply via email to

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