[PATCH]: multilib fixes for fortran and java
Jack Howarth
howarth@bromo.msbb.uc.edu
Wed Nov 8 15:41:00 GMT 2006
The attached patch resolves the remaining issues
with performing a multilib build of the language
set including fortran and java on a G4 processor
machine under Darwin8. After the patch was applied,
the following regeneration steps were used in the
source tree...
cd libgfortran
aclocal -I ../config
autoconf -I ../config
automake -a
cd ..
cd boehm-gc
aclocal -I .. -I ../config
autoconf -I .. -I ../config
automake -a
cd ..
cd libffi
aclocal -I .. -I ../config
autoconf -I .. -I ../config
automake -a
cd ..
cd libjava
aclocal -I . -I .. -I ../config
autoconf -I . -I .. -I ../config
automake -a
cd classpath
aclocal -I m4 -I ../.. -I ../../config
autoconf -I m4 -I ../.. -I ../../config
automake -a
cd ../libltdl
aclocal -I ../.. -I ../../config
autoconf -I ../.. -I ../../config
automake -a
cd ..
cd ..
cd zlib
aclocal -I ../config
autoconf -I ../config
automake -a
cd ..
Tested on Linux x86_64 and Darwin PPC.
Okay for trunk and gcc branch?
Jack
Index: boehm-gc/ChangeLog
2006-11-07 Jack Howarth <howarth@bromo.med.uc.edu>
* aclocal.m4: Regenerate to use multi.m4.
* configure: Regenerate.
* Makefile.in: Regenerate.
Index: libgfortran/ChangeLog
2006-11-07 Jack Howarth <howarth@bromo.med.uc.edu>
* aclocal.m4: Regenerate to use multi.m4.
* configure: Regenerate.
* Makefile.in: Regenerate.
Index: zlib/ChangeLog
2006-11-07 Jack Howarth <howarth@bromo.med.uc.edu>
* Makefile.am: Add ACLOCAL_AMFLAGS to use multi.m4.
* aclocal.m4: Regenerate.
* configure: Regenerate.
* Makefile.in: Regenerate.
Index: libffi/ChangeLog
2006-11-07 Jack Howarth <howarth@bromo.med.uc.edu>
* Makefile.am: Add ACLOCAL_AMFLAGS to use multi.m4.
* aclocal.m4: Regenerate.
* configure: Regenerate.
* Makefile.in: Regenerate.
Index: libjava/ChangeLog
2006-11-07 Jack Howarth <howarth@bromo.med.uc.edu>
* configure.ac: Use multi.m4 from aclocal rather than custom
code. Use multi_basedir instead libgcj_basedir. Test for
/proc/self/exe when not cross-compiling.
* aclocal.m4: Regenerate.
* configure: Regenerate.
* Makefile.in: Regenerate.
Index: libjava/classpath/ChangeLog
2006-11-07 Jack Howarth <howarth@bromo.med.uc.edu>
* configure.ac: Use multi.m4 from aclocal rather than
custom code. Use multi_basedir instead libgcj_basedir.
* aclocal.m4: Regenerate.
* configure: Regenerate.
* Makefile.in: Regenerate.
Index: libjava/libltdl/ChangeLog
2006-11-07 Jack Howarth <howarth@bromo.med.uc.edu>
* Makefile.am: Add ACLOCAL_AMFLAGS to use multi.m4.
* configure.ac: Use multi.m4 from aclocal rather than
custom code.
* aclocal.m4: Regenerate.
* configure: Regenerate.
* Makefile.in: Regenerate.
Index: zlib/Makefile.am
===================================================================
--- zlib/Makefile.am (revision 118523)
+++ zlib/Makefile.am (working copy)
@@ -2,6 +2,8 @@
AUTOMAKE_OPTIONS = 1.8 cygnus
+ACLOCAL_AMFLAGS = -I ../config
+
ZLIB_SOURCES = adler32.c compress.c crc32.c crc32.h deflate.c \
deflate.h gzio.c infback.c inffast.c inffast.h inffixed.h inflate.c \
inflate.h inftrees.c inftrees.h trees.c trees.h uncompr.c zconf.h \
Index: libffi/Makefile.am
===================================================================
--- libffi/Makefile.am (revision 118523)
+++ libffi/Makefile.am (working copy)
@@ -1,7 +1,7 @@
## Process this with automake to create Makefile.in
AUTOMAKE_OPTIONS = foreign subdir-objects
-ACLOCAL_AMFLAGS = -I ..
+ACLOCAL_AMFLAGS = -I .. -I ../config
SUBDIRS = include testsuite
Index: libjava/libltdl/configure.ac
===================================================================
--- libjava/libltdl/configure.ac (revision 118523)
+++ libjava/libltdl/configure.ac (working copy)
@@ -30,6 +30,8 @@ AC_CONFIG_SRCDIR([ltdl.c])
## GCJ LOCAL: gcc tree uses maintainer mode.
AM_MAINTAINER_MODE
+AM_ENABLE_MULTILIB(, ../..)
+
## ------------------------------- ##
## Libltdl specific configuration. ##
## ------------------------------- ##
Index: libjava/libltdl/Makefile.am
===================================================================
--- libjava/libltdl/Makefile.am (revision 118523)
+++ libjava/libltdl/Makefile.am (working copy)
@@ -2,6 +2,8 @@
AUTOMAKE_OPTIONS = no-dependencies foreign
+ACLOCAL_AMFLAGS = -I ../.. -I ../../config
+
INCLUDES = $(GCINCS)
if INSTALL_LTDL
Index: libjava/configure.ac
===================================================================
--- libjava/configure.ac (revision 118523)
+++ libjava/configure.ac (working copy)
@@ -15,27 +15,8 @@ AC_ARG_WITH(target-subdir,
# We may get other options which we don't document:
# --with-target-subdir, --with-multisrctop, --with-multisubdir
-# When building with srcdir == objdir, links to the source files will
-# be created in directories within the target_subdir. We have to
-# adjust toplevel_srcdir accordingly, so that configure finds
-# install-sh and other auxiliary files that live in the top-level
-# source directory.
-if test "${srcdir}" = "."; then
- if test -z "${with_target_subdir}"; then
- toprel=".."
- else
- if test "${with_target_subdir}" != "."; then
- toprel="${with_multisrctop}../.."
- else
- toprel="${with_multisrctop}.."
- fi
- fi
-else
- toprel=".."
-fi
-
-libgcj_basedir=$srcdir/$toprel/./libjava
-AC_SUBST(libgcj_basedir)
+# Find the rest of the source tree framework.
+AM_ENABLE_MULTILIB(, ..)
AC_CANONICAL_SYSTEM
_GCC_TOPLEV_NONCANONICAL_BUILD
@@ -74,16 +55,6 @@ AC_ARG_ENABLE(version-specific-runtime-l
[version_specific_libs=no]
)
-# Default to --enable-multilib
-AC_ARG_ENABLE(multilib,
- AS_HELP_STRING([--enable-multilib],
- [build many library versions (default)]),
-[case "${enableval}" in
- yes) multilib=yes ;;
- no) multilib=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for multilib option) ;;
- esac], [multilib=yes])dnl
-
AC_ARG_ENABLE(plugin,
AS_HELP_STRING([--enable-plugin],
[build gcjwebplugin web browser plugin]),
@@ -905,7 +876,7 @@ AC_SUBST(HASH_SYNC_SPEC)
AM_CONDITIONAL(USING_GCC, test "$GCC" = yes)
# We're in the tree with gcc, and need to include some of its headers.
-GCC_UNWIND_INCLUDE='-I$(libgcj_basedir)/../gcc'
+GCC_UNWIND_INCLUDE='-I$(multi_basedir)/./libjava/../gcc'
if test "x${with_newlib}" = "xyes"; then
# We are being configured with a cross compiler. AC_REPLACE_FUNCS
@@ -945,7 +916,7 @@ else
AC_CHECK_LIB(dld, dladdr, [
AC_DEFINE(HAVE_DLADDR, 1, [Define if you have dladdr()])])])
- if test x"$build" = x"$host"; then
+ if test x"$cross_compiling" = x"no"; then
AC_CHECK_FILES(/proc/self/exe, [
AC_DEFINE(HAVE_PROC_SELF_EXE, 1, [Define if you have /proc/self/exe])])
else
@@ -1518,7 +1489,7 @@ AC_CONFIG_COMMANDS([default],
case " $CONFIG_FILES " in
*" Makefile "*)
LD="${ORIGINAL_LD_FOR_MULTILIBS}"
- ac_file=Makefile . ${libgcj_basedir}/../config-ml.in
+ ac_file=Makefile . ${multi_basedir}/./libjava/../config-ml.in
;;
esac
for ac_multi_file in $CONFIG_FILES; do
@@ -1534,7 +1505,7 @@ target=${target}
with_multisubdir=${with_multisubdir}
ac_configure_args="${multilib_arg} ${ac_configure_args}"
CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
-libgcj_basedir=${libgcj_basedir}
+multi_basedir=${multi_basedir}
CC="${CC}"
CXX="${CXX}"
ORIGINAL_LD_FOR_MULTILIBS="${ORIGINAL_LD_FOR_MULTILIBS}"
Index: libjava/classpath/configure.ac
===================================================================
--- libjava/classpath/configure.ac (revision 118523)
+++ libjava/classpath/configure.ac (working copy)
@@ -11,6 +11,9 @@ AC_CONFIG_SRCDIR(java/lang/System.java)
AC_CANONICAL_TARGET
+# Find the rest of the source tree framework.
+AM_ENABLE_MULTILIB(, ../..)
+
dnl -----------------------------------------------------------
dnl Fold all IA-32 CPU architectures into "x86"
dnl -----------------------------------------------------------
More information about the Gcc-patches
mailing list