This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Problem in compiling libffi as multilib
- From: Jeff Sturm <jsturm at one-point dot com>
- To: Bo Thorsen <bo at sonofthor dot dk>
- Cc: gcc at gcc dot gnu dot org
- Date: Sat, 20 Jul 2002 16:19:10 -0400 (EDT)
- Subject: Re: Problem in compiling libffi as multilib
On Fri, 19 Jul 2002, Bo Thorsen wrote:
> The problem is that both the 64 bit compilation (native x86-64) and the 32 bit
> (gcc -m32) will use the same config.status for building include/ffi.h. This
> means that I get the x86-64 defines in ffi.h.
I don't see this problem on sparc64. I have a related multilib problem
though, see below.
> ffi.h: $(top_builddir)/config.status ffi.h.in
> cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL)
> ./config.status
I have top_builddir=. in all multilibs. The generated fficonfig.h files
are different. (ffi.h is identical, because configure sets TARGET=SPARC
for both -m32 and -m64 builds.)
However I noticed libjava looks in the wrong place for the libffi headers,
causing spurious warnings in my libjava build. Could that be what you are
seeing? I'd guess this is the right fix, will test as soon as I do a new
bootstrap.
* configure.in (LIBFFIINCS): Don't include from MULTIBUILDTOP.
Index: configure.in
===================================================================
RCS file: /cvs/gcc/gcc/libjava/configure.in,v
retrieving revision 1.137
diff -u -r1.137 configure.in
--- configure.in 19 Jul 2002 14:41:14 -0000 1.137
+++ configure.in 20 Jul 2002 20:13:46 -0000
@@ -196,7 +196,7 @@
if test "$with_libffi" != no; then
AC_DEFINE(USE_LIBFFI)
LIBFFI=../libffi/libffi_convenience.la
- LIBFFIINCS='-I$(top_srcdir)/../libffi/include -I$(MULTIBUILDTOP)../libffi/include'
+ LIBFFIINCS='-I$(top_srcdir)/../libffi/include -I../libffi/include'
fi
AC_SUBST(LIBFFI)
AC_SUBST(LIBFFIINCS)