libtool
[Top][All Lists]
Advanced

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

Re: bi-arch build problem: cannot build 64-bit libs on ppc64


From: Maynard Johnson
Subject: Re: bi-arch build problem: cannot build 64-bit libs on ppc64
Date: Mon, 21 Jan 2008 10:27:11 -0600
User-agent: Thunderbird 2.0.0.9 (Windows/20071031)

Peter O'Gorman wrote:
Maynard Johnson wrote:
Peter O'Gorman wrote:
Maynard Johnson wrote:

   #> ./libtool --version
   ltmain.sh (GNU libtool) 1.5.24 (1.1220.2.455 2007/06/24 02:13:29)

   Copyright (C) 2007  Free Software Foundation, Inc.
   This is free software; see the source for copying conditions.  There
is NO
   warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR
PURPOSE.
Is it possible that while your ltmain.sh comes from libtool-1.5.24, your
configure was generated using an earlier version of libtool.m4?

Check your aclocal.m4 (and the m4 files it includes), for 'serial ??
AC_PROG_LIBTOOL'. For 1.5.24 that should be 'serial 51 AC_PROG_LIBTOOL'.
I started out with libtool 1.5.22 installed in /usr on my system.  I
installed 1.5.24 in /usr/local before posting to the list.  I thought I
had regenerated everything in my project from scratch after installing
1.5.24, but when I looked at aclocal.m4, I saw 'serial 48
AC_PROG_LIBTOOL'.  So I started again from scratch in a new session,
making sure that the libtool in my path was 1.5.24.  I checked out my
project fresh from CVS so that there were no old generated files; ran
the libtoolize, aclocal, autoheader, automake, and autoconf; then did
the configure as before (with CFLAGS and CXXFLAGS = "-m64".  Same
result.  I still see 'serial 48 AC_PROG_LIBTOOL' in aclocal.m4.  What am
I missing?

aclocal -I /usr/local/share/aclocal
That certainly helped! We're getting further than before, but now failing when building a C++ library as follows:

   g++ -DHAVE_CONFIG_H -I. -I. -I../.. -I ../../libopagent -I
   /opt/ibm/java2-ppc-50//include -I
   /opt/ibm/java2-ppc-50//include/linux -W -Wall -fPIC -m64 -MT
   libjvmpi_oprofile_la-jvmpi_oprofile.lo -MD -MP -MF
.deps/libjvmpi_oprofile_la-jvmpi_oprofile.Tpo -c jvmpi_oprofile.cpp -fPIC -DPIC -o .libs/libjvmpi_oprofile_la-jvmpi_oprofile.o
   /bin/sh ../../libtool --tag=CXX --mode=link g++  -m64   -o
libjvmpi_oprofile.la -rpath /usr/local/lib/oprofile libjvmpi_oprofile_la-jvmpi_oprofile.lo ../../libopagent/libopagent.la
   g++ -shared -nostdlib
   /usr/lib/gcc/powerpc64-suse-linux/4.1.2/../../../../lib64/crti.o
/usr/lib/gcc/powerpc64-suse-linux/4.1.2/64/crtbeginS.o .libs/libjvmpi_oprofile_la-jvmpi_oprofile.o -Wl,--rpath
   -Wl,/home/mpj/temp/oprofile/libopagent/.libs -Wl,--rpath
   -Wl,/usr/lib/gcc/powerpc64-suse-linux/4.1.2 -Wl,--rpath
   -Wl,/usr/local/lib/oprofile -Wl,--rpath
   -Wl,/usr/lib/gcc/powerpc64-suse-linux/4.1.2
   ../../libopagent/.libs/libopagent.so
   -L/usr/lib/gcc/powerpc64-suse-linux/4.1.2/64
   -L/usr/lib/gcc/powerpc64-suse-linux/4.1.2/../../../../lib64
   -L/lib/../lib64 -L/usr/lib/../lib64
   -L/usr/lib/gcc/powerpc64-suse-linux/4.1.2
   
-L/usr/lib/gcc/powerpc64-suse-linux/4.1.2/../../../../powerpc64-suse-linux/lib
   -L/usr/lib/gcc/powerpc64-suse-linux/4.1.2/../../..
   /usr/lib/gcc/powerpc64-suse-linux/4.1.2/libstdc++.so -lm -lc -lgcc_s
   /usr/lib/gcc/powerpc64-suse-linux/4.1.2/64/crtsavres.o
   /usr/lib/gcc/powerpc64-suse-linux/4.1.2/64/crtendS.o
/usr/lib/gcc/powerpc64-suse-linux/4.1.2/../../../../lib64/crtn.o -m64 -Wl,-soname -Wl,libjvmpi_oprofile.so.0 -o
   .libs/libjvmpi_oprofile.so.0.0.0
   /usr/lib/gcc/powerpc64-suse-linux/4.1.2/libstdc++.so: could not read
   symbols: File in wrong format
   collect2: ld returned 1 exit status

The 64-bit lib it should be finding is in /usr/lib/gcc/powerpc64-suse-linux/4.1.2/64/libstdc++.so. Note the '64' subdirectory. Any clues what I need to do for this case? Thanks much!

-Maynard

or copy libtool.m4 into your project, and add that relative path to the
aclocal includes (perhaps using Makefile.am 'ACLOCAL_AMFLAGS = -I ./foo').

Hope that after all of this the problem is fixed,
Peter






reply via email to

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