[Top][All Lists]

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

Re: libtool and 32/64-bit builds

From: Bob Friesenhahn
Subject: Re: libtool and 32/64-bit builds
Date: Thu, 25 Jul 2002 14:47:56 -0500 (CDT)

On Thu, 25 Jul 2002, Albert Chin wrote:

> Are you sure that [/64|/sparcv9] is added for user libraries?

I have verified (using gcc 3.1 with the -m64 option) that if
-L/usr/local/lib is specified, the linker will use a 64-bit library
located in /usr/local/lib/sparcv9 instead of a 32-bit library located
in /usr/local/lib.

Contrary to comments I have seen in various places, gcc 3.1 seems to
work great at producing 64-bit executables for both C *and* C++.

> $ cc -xarch=v9 a.c -L/opt/TWWfsw/zlib11/lib -lz
> =>     /usr/lib/64/
> =>     /usr/lib/64/
> =>    /usr/lib/64/
>         /usr/platform/SUNW,Ultra-2/lib/sparcv9/
> What do you make of this?

What I make of it is that you didn't specify a -R option to find the
library, so looks in a system directory instead.  This has
nothing to do with 32 vs 64 bit.

It would be way cool if libtool could manage the installation of 32 vs
64 bit libraries under Solaris 7+ so that simply specifying -m64
(doesn't this option work with Sun's compiler as well?) would be
sufficient for the .la and .so files to be installed under sparcv9.
This would avoid the need to modify autoconf, automake, and existing
packages in order to support installing 64-bit libraries under the
same prefix as 32-bit libraries.  It is of course possible for a
package to create a configured header file which differs between 32
and 64-bit builds, but this is a bit unusual.

Bob Friesenhahn

reply via email to

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