This is the mail archive of the
java-patches@sourceware.cygnus.com
mailing list for the Java project.
Patch: sparc64, libffi, etc
- To: Java Patch List <java-patches at sourceware dot cygnus dot com>
- Subject: Patch: sparc64, libffi, etc
- From: Tom Tromey <tromey at cygnus dot com>
- Date: 01 May 2000 15:30:34 -0600
- Reply-To: tromey at cygnus dot com
I'm checking in this patch from Jakub Jelinek. It fixes a number of
problems which he discovered while doing a Sparc64 port of libjava.
His comments are included.
Tom
Hi!
With this patch, I can build libgcj (inside of gcc build tree) on
sparc64-redhat-linux (which uses multilibs ., 32/ and alt/).
Basically, there were a few issues: JC1FLAGS never included the multilib
options, this patch adds that to config-ml.in and moves the -L$(here) stuff
to the Makefile.am because $(here) is dependent on the particular multidir.
libffi's Makefile did not have SUBDIRS and thus automake does not work as
expected for multilibs with it (the build died because only . libffi was
built, not 32/ nor alt/ and then 32/libjava wanted to link against it).
Another thing is that if libstdc++ is built at the same time as libgcj, then
we need to -L resp. -rpath the path to it, so that the system libstdc++ is
not used, but the one being build.
And last this has incorporated my libtool patch to fix multilib building in
--mode=link (libtool will pass through -B, -b, -V gcc options plus any
options which are used to distinguish multilibs) - otherwise the build fails
because gcc tries to -shared build without -m32 objects created with -m32,
which is a no-no.
Also, I wonder, will target-libffi be included in gcc's toplevel
Makefile.in in the near future? As both Makefile.in's have pretty diverged,
it required some time to sync them together.
And last, will your local changes to libtool (not passing -DPIC for .java
and .class) be included in libtool?
libgcj:
2000-04-28 Jakub Jelinek <jakub@redhat.com>
* ltconfig (extra_compiler_flags, extra_compiler_flags_value):
New variables. Set for gcc using -print-multi-lib. Export them
to libtool.
(sparc64-*-linux-gnu*): Use libsuff 64 for search paths.
* ltmain.sh (B|b|V): Don't throw away gcc's -B, -b and -V options
for -shared links.
(extra_compiler_flags_value, extra_compiler_flags): Check these
for extra compiler options which need to be passed down in
compiler_flags.
* config-ml.in (multi-do): Pass modified JC1FLAGS to multidir
Makefiles.
libgcj/libffi:
2000-04-28 Jakub Jelinek <jakub@redhat.com>
* Makefile.am (SUBDIRS): Define.
(AM_MAKEFLAGS): Likewise.
(Multilib support.): Add section.
* Makefile.in: Rebuilt.
* ltconfig (extra_compiler_flags, extra_compiler_flags_value):
New variables. Set for gcc using -print-multi-lib. Export them
to libtool.
(sparc64-*-linux-gnu*): Use libsuff 64 for search paths.
* ltmain.sh (B|b|V): Don't throw away gcc's -B, -b and -V options
for -shared links.
(extra_compiler_flags_value, extra_compiler_flags): Check these
for extra compiler options which need to be passed down in
compiler_flags.
libgcj/libjava:
2000-04-28 Jakub Jelinek <jakub@redhat.com>
* Makefile.am (GCJCOMPILE, JCFLAGS, JF1CLAGS, jv_convert_LINK,
gij_LINK, libgcj.zip, .java=.class): Move -L option out of FLAGS.
(libgcj_la_LDFLAGS): Add -L../libstdc++ for in-gcc builds.
(jv_convert_LDFLAGS, gij_LDFLAGS): Add `pwd`/../libstdc++ to
-rpath for in-gcc builds.
* Makefile.in: Rebuilt.
--- libgcj/libffi/ltmain.sh.jj Sun Aug 8 15:27:19 1999
+++ libgcj/libffi/ltmain.sh Fri Apr 28 14:48:29 2000
@@ -787,6 +787,7 @@ compiler."
finalize_command="$CC"
compile_rpath=
+ compiler_flags=
finalize_rpath=
compile_shlibpath=
finalize_shlibpath=
@@ -916,6 +917,13 @@ compiler."
prev=
continue
;;
+ B|b|V)
+ compiler_flags="$compiler_flags -$prev$qarg"
+ prev=
+ compile_command="$compile_command -$prev$qarg"
+ finalize_command="$finalize_command -$prev$qarg"
+ continue
+ ;;
*)
eval "$prev=\"\$arg\""
prev=
@@ -1076,6 +1084,17 @@ compiler."
# Some other compiler flag.
-* | +*)
+ if test "X$extra_compiler_flags_value" != "X"; then
+ is_extra_compiler_flag=
+ eval "case \"\$arg\" in \
+ $extra_compiler_flags_value) \
+ is_extra_compiler_flag=yes ;; \
+ esac"
+ if test "$is_extra_compiler_flag"; then
+ prev=`echo "X$arg" | $Xsed -e 's/^-//'`
+ continue
+ fi
+ fi
# Unknown arguments in both finalize_command and compile_command need
# to be aesthetically quoted because they are evaled later.
arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"`
@@ -1084,6 +1103,16 @@ compiler."
arg="\"$arg\""
;;
esac
+ if test "X$extra_compiler_flags" != "X"; then
+ is_extra_compiler_flag=
+ eval "case \"\$arg\" in \
+ $extra_compiler_flags) \
+ is_extra_compiler_flag=yes ;; \
+ esac"
+ if test "$is_extra_compiler_flag"; then
+ compiler_flags="$compiler_flags $arg"
+ fi
+ fi
;;
*.o | *.obj | *.a | *.lib)
--- libgcj/libffi/ltconfig.jj Sun Aug 8 15:27:19 1999
+++ libgcj/libffi/ltconfig Fri Apr 28 14:48:29 2000
@@ -985,6 +985,29 @@ else
fi
echo "$ac_t$with_gnu_ld" 1>&6
+extra_compiler_flags=
+extra_compiler_flags_value=
+if test "$with_gcc" = yes; then
+ extra_compiler_flags_value="-B|-b|-V"
+ extra_compiler_flags="-B*|-b*|-V*"
+ # Check to see what are the possible multilibing options
+ echo $ac_n "checking what multilib options $compiler supports ... $ac_c" 1>&6
+ multilibopts=
+ if ${CC-cc} -print-multi-lib >/dev/null 2>&1; then
+ for dir in `${CC-cc} -print-multi-lib 2>/dev/null`; do
+ multilibopts="$multilibopts`echo $dir | sed -e 's/^[^;]*;//' -e 's/@/ -/g'`"
+ done
+ fi
+ # Kill any whitespace at the beginning and end
+ multilibopts=`echo $multilibopts`
+ if test -n "$multilibopts"; then
+ extra_compiler_flags="$extra_compiler_flags`echo $multilibopts | sed -e 's/ -/|-/g' -e 's/^-/|-/'`"
+ echo "$ac_t$multilibopts" 1>&6
+ else
+ echo "$ac_t"none 1>&6
+ fi
+fi
+
# See if the linker supports building shared libraries.
echo $ac_n "checking whether the linker ($LD) supports shared libraries... $ac_c" 1>&6
@@ -1109,8 +1132,8 @@ EOF
*)
if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $linkopts ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $linkopts ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
+ archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $linkopts ${wl}-soname $wl$soname -o $lib'
+ archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $linkopts ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
else
ld_shlibs=no
fi
@@ -1217,7 +1240,7 @@ else
# FreeBSD 3 and greater uses gcc -shared to do shared libraries.
freebsd*)
- archive_cmds='$CC -shared -o $lib $libobjs $deplibs $linkopts'
+ archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags $linkopts'
hardcode_libdir_flag_spec='-R$libdir'
hardcode_direct=yes
hardcode_minus_L=no
@@ -1242,9 +1265,9 @@ else
irix5* | irix6*)
if test "$with_gcc" = yes; then
- archive_cmds='$CC -shared $libobjs $deplibs $linkopts ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib'
+ archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $linkopts ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib'
else
- archive_cmds='$LD -shared $libobjs $deplibs $linkopts -soname $soname `test -n "$verstring" && echo -set_version $verstring` -o $lib'
+ archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags $linkopts -soname $soname `test -n "$verstring" && echo -set_version $verstring` -o $lib'
fi
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
hardcode_libdir_separator=:
@@ -1279,7 +1302,7 @@ else
osf3* | osf4*)
if test "$with_gcc" = yes; then
allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $linkopts ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib'
+ archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags $linkopts ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib'
else
allow_undefined_flag=' -expect_unresolved \*'
archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linkopts -soname $soname `test -n "$verstring" && echo -set_version $verstring` -o $lib'
@@ -1771,6 +1794,13 @@ linux-gnu*)
*) dynamic_linker='Linux ld.so' ;;
esac
fi
+ case "$host_cpu" in
+ sparc64)
+ libsuff=64
+ sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
+ sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
+ ;;
+ esac
;;
netbsd*)
@@ -2428,7 +2458,8 @@ case "$ltmain" in
finish_cmds finish_eval global_symbol_pipe global_symbol_to_cdecl \
hardcode_libdir_flag_spec hardcode_libdir_separator \
sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
- compiler_c_o compiler_o_lo need_locks exclude_expsyms include_expsyms; do
+ compiler_c_o compiler_o_lo need_locks exclude_expsyms include_expsyms \
+ extra_compiler_flags extra_compiler_flags_value; do
case "$var" in
reload_cmds | old_archive_cmds | old_archive_from_new_cmds | \
@@ -2653,6 +2684,10 @@ archive_cmds=$archive_cmds
archive_expsym_cmds=$archive_expsym_cmds
postinstall_cmds=$postinstall_cmds
postuninstall_cmds=$postuninstall_cmds
+
+# Case patterns for extra compiler flags needed for linking
+extra_compiler_flags=$extra_compiler_flags
+extra_compiler_flags_value=$extra_compiler_flags_value
# Method to check whether dependent libraries are shared objects.
deplibs_check_method=$deplibs_check_method
--- libgcj/libffi/Makefile.am.jj Mon Apr 17 09:27:22 2000
+++ libgcj/libffi/Makefile.am Fri Apr 28 14:48:29 2000
@@ -2,6 +2,8 @@
AUTOMAKE_OPTIONS = cygnus
+SUBDIRS = include
+
EXTRA_DIST = LICENSE ChangeLog.v1 src/mips/ffi.c src/mips/n32.S \
src/mips/n32.s src/mips/o32.S src/mips/o32.s \
src/sparc/ffi.c src/sparc/v8.S src/sparc/v9.S \
@@ -13,6 +15,52 @@ EXTRA_DIST = LICENSE ChangeLog.v1 src/mi
VPATH = @srcdir@:@srcdir@/src:@srcdir@/src/@TARGETDIR@
+## ################################################################
+
+##
+## This section is for make and multilib madness.
+##
+
+# Work around what appears to be a GNU make bug handling MAKEFLAGS
+# values defined in terms of make variables, as is the case for CC and
+# friends when we are called from the top level Makefile.
+AM_MAKEFLAGS = \
+ "AR_FLAGS=$(AR_FLAGS)" \
+ "CC_FOR_BUILD=$(CC_FOR_BUILD)" \
+ "CFLAGS=$(CFLAGS)" \
+ "CXXFLAGS=$(CXXFLAGS)" \
+ "CFLAGS_FOR_BUILD=$(CFLAGS_FOR_BUILD)" \
+ "CFLAGS_FOR_TARGET=$(CFLAGS_FOR_TARGET)" \
+ "INSTALL=$(INSTALL)" \
+ "INSTALL_DATA=$(INSTALL_DATA)" \
+ "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
+ "INSTALL_SCRIPT=$(INSTALL_SCRIPT)" \
+ "JC1FLAGS=$(JC1FLAGS)" \
+ "LDFLAGS=$(LDFLAGS)" \
+ "LIBCFLAGS=$(LIBCFLAGS)" \
+ "LIBCFLAGS_FOR_TARGET=$(LIBCFLAGS_FOR_TARGET)" \
+ "MAKE=$(MAKE)" \
+ "MAKEINFO=$(MAKEINFO) $(MAKEINFOFLAGS)" \
+ "PICFLAG=$(PICFLAG)" \
+ "PICFLAG_FOR_TARGET=$(PICFLAG_FOR_TARGET)" \
+ "SHELL=$(SHELL)" \
+ "exec_prefix=$(exec_prefix)" \
+ "infodir=$(infodir)" \
+ "libdir=$(libdir)" \
+ "prefix=$(prefix)" \
+ "AR=$(AR)" \
+ "AS=$(AS)" \
+ "CC=$(CC)" \
+ "CXX=$(CXX)" \
+ "LD=$(LD)" \
+ "LIBCFLAGS=$(LIBCFLAGS)" \
+ "NM=$(NM)" \
+ "PICFLAG=$(PICFLAG)" \
+ "RANLIB=$(RANLIB)" \
+ "DESTDIR=$(DESTDIR)"
+
+MAKEOVERRIDES=
+
# Multilib support variables.
MULTISRCTOP =
MULTIBUILDTOP =
@@ -84,3 +132,31 @@ AM_CFLAGS = -fexceptions
libffi_la_LDFLAGS = -release $(VERSION)
INCLUDES = -I$(top_srcdir)/include -Iinclude -I$(top_srcdir)/src
+
+# Multilib support.
+.PHONY: all-multi mostlyclean-multi clean-multi distclean-multi \
+ maintainer-clean-multi
+
+all-recursive: all-multi
+install-recursive: install-multi
+mostlyclean-recursive: mostlyclean-multi
+clean-recursive: clean-multi
+distclean-recursive: distclean-multi
+maintainer-clean-recursive: maintainer-clean-multi
+
+all-multi:
+ $(MULTIDO) $(AM_MAKEFLAGS) DO=all multi-do
+install-multi:
+ $(MULTIDO) $(AM_MAKEFLAGS) DO=install multi-do
+mostlyclean-multi:
+ $(MULTICLEAN) $(AM_MAKEFLAGS) DO=mostlyclean multi-clean
+clean-multi:
+ $(MULTICLEAN) $(AM_MAKEFLAGS) DO=clean multi-clean
+distclean-multi:
+ $(MULTICLEAN) $(AM_MAKEFLAGS) DO=distclean multi-clean
+maintainer-clean-multi:
+ $(MULTICLEAN) $(AM_MAKEFLAGS) DO=maintainer-clean multi-clean
+
+
+## ################################################################
+
--- libgcj/libffi/Makefile.in.jj Mon Apr 17 09:27:22 2000
+++ libgcj/libffi/Makefile.in Fri Apr 28 14:48:29 2000
@@ -1,6 +1,6 @@
# Makefile.in generated automatically by automake 1.4a from Makefile.am
-# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
+# Copyright (C) 1994, 1995-9, 2000 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
@@ -30,8 +30,6 @@ mandir = @mandir@
includedir = @includedir@
oldincludedir = /usr/include
-DESTDIR =
-
pkgdatadir = $(datadir)/@PACKAGE@
pkglibdir = $(libdir)/@PACKAGE@
pkgincludedir = $(includedir)/@PACKAGE@
@@ -56,20 +54,18 @@ POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
+
+@SET_MAKE@
host_alias = @host_alias@
host_triplet = @host@
-AMTAR = @AMTAR@
-AMTARFLAGS = @AMTARFLAGS@
AS = @AS@
CC = @CC@
DLLTOOL = @DLLTOOL@
EXEEXT = @EXEEXT@
-LD = @LD@
LIBTOOL = @LIBTOOL@
LN_S = @LN_S@
MAINT = @MAINT@
MAKEINFO = @MAKEINFO@
-NM = @NM@
OBJDUMP = @OBJDUMP@
PACKAGE = @PACKAGE@
RANLIB = @RANLIB@
@@ -77,11 +73,13 @@ SHELL = @SHELL@
TARGET = @TARGET@
TARGETDIR = @TARGETDIR@
VERSION = @VERSION@
-install_sh = @install_sh@
+libffi_basedir = @libffi_basedir@
AUTOMAKE_OPTIONS = cygnus
+SUBDIRS = include
+
EXTRA_DIST = LICENSE ChangeLog.v1 src/mips/ffi.c src/mips/n32.S \
src/mips/n32.s src/mips/o32.S src/mips/o32.s \
src/sparc/ffi.c src/sparc/v8.S src/sparc/v9.S \
@@ -94,6 +92,47 @@ EXTRA_DIST = LICENSE ChangeLog.v1 src/mi
VPATH = @srcdir@:@srcdir@/src:@srcdir@/src/@TARGETDIR@
+# Work around what appears to be a GNU make bug handling MAKEFLAGS
+# values defined in terms of make variables, as is the case for CC and
+# friends when we are called from the top level Makefile.
+AM_MAKEFLAGS = \
+ "AR_FLAGS=$(AR_FLAGS)" \
+ "CC_FOR_BUILD=$(CC_FOR_BUILD)" \
+ "CFLAGS=$(CFLAGS)" \
+ "CXXFLAGS=$(CXXFLAGS)" \
+ "CFLAGS_FOR_BUILD=$(CFLAGS_FOR_BUILD)" \
+ "CFLAGS_FOR_TARGET=$(CFLAGS_FOR_TARGET)" \
+ "INSTALL=$(INSTALL)" \
+ "INSTALL_DATA=$(INSTALL_DATA)" \
+ "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
+ "INSTALL_SCRIPT=$(INSTALL_SCRIPT)" \
+ "JC1FLAGS=$(JC1FLAGS)" \
+ "LDFLAGS=$(LDFLAGS)" \
+ "LIBCFLAGS=$(LIBCFLAGS)" \
+ "LIBCFLAGS_FOR_TARGET=$(LIBCFLAGS_FOR_TARGET)" \
+ "MAKE=$(MAKE)" \
+ "MAKEINFO=$(MAKEINFO) $(MAKEINFOFLAGS)" \
+ "PICFLAG=$(PICFLAG)" \
+ "PICFLAG_FOR_TARGET=$(PICFLAG_FOR_TARGET)" \
+ "SHELL=$(SHELL)" \
+ "exec_prefix=$(exec_prefix)" \
+ "infodir=$(infodir)" \
+ "libdir=$(libdir)" \
+ "prefix=$(prefix)" \
+ "AR=$(AR)" \
+ "AS=$(AS)" \
+ "CC=$(CC)" \
+ "CXX=$(CXX)" \
+ "LD=$(LD)" \
+ "LIBCFLAGS=$(LIBCFLAGS)" \
+ "NM=$(NM)" \
+ "PICFLAG=$(PICFLAG)" \
+ "RANLIB=$(RANLIB)" \
+ "DESTDIR=$(DESTDIR)"
+
+
+MAKEOVERRIDES =
+
# Multilib support variables.
MULTISRCTOP =
MULTIBUILDTOP =
@@ -115,20 +154,22 @@ ffitest_LDADD = libffi.la
TARGET_SRC_MIPS_GCC = src/mips/ffi.c src/mips/o32.S src/mips/n32.S
TARGET_SRC_MIPS_SGI = src/mips/ffi.c src/mips/o32.s src/mips/n32.s
TARGET_SRC_X86 = src/x86/ffi.c src/x86/sysv.S
-TARGET_SRC_SPARC = src/sparc/ffi.c src/sparc/v8.S src/sparc/v9.S
+TARGET_SRC_SPARC = src/sparc/ffi.c src/sparc/v8.S src/sparc/v9.S
TARGET_SRC_ALPHA = src/alpha/ffi.c src/alpha/osf.S
TARGET_SRC_IA64 = src/ia64/ffi.c src/ia64/unix.S
TARGET_SRC_M68K = src/m68k/ffi.c src/m68k/sysv.S
TARGET_SRC_POWERPC = src/powerpc/ffi.c src/powerpc/sysv.S
TARGET_SRC_ARM = src/arm/sysv.S src/arm/ffi.c
-libffi_la_common_SOURCES = src/debug.c src/prep_cif.c src/types.c src/raw_api.c src/java_raw_api.c
+libffi_la_common_SOURCES = src/debug.c src/prep_cif.c src/types.c \
+ src/raw_api.c src/java_raw_api.c
+
@MIPS_GCC_TRUE@libffi_la_SOURCES = @MIPS_GCC_TRUE@$(libffi_la_common_SOURCES) $(TARGET_SRC_MIPS_GCC)
@MIPS_SGI_TRUE@libffi_la_SOURCES = @MIPS_SGI_TRUE@$(libffi_la_common_SOURCES) $(TARGET_SRC_MIPS_SGI)
@X86_TRUE@libffi_la_SOURCES = @X86_TRUE@$(libffi_la_common_SOURCES) $(TARGET_SRC_X86)
@SPARC_TRUE@libffi_la_SOURCES = @SPARC_TRUE@$(libffi_la_common_SOURCES) $(TARGET_SRC_SPARC)
@ALPHA_TRUE@libffi_la_SOURCES = @ALPHA_TRUE@$(libffi_la_common_SOURCES) $(TARGET_SRC_ALPHA)
-@IA64_TRUE@libffi_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_IA64)
+@IA64_TRUE@libffi_la_SOURCES = @IA64_TRUE@$(libffi_la_common_SOURCES) $(TARGET_SRC_IA64)
@M68K_TRUE@libffi_la_SOURCES = @M68K_TRUE@$(libffi_la_common_SOURCES) $(TARGET_SRC_M68K)
@POWERPC_TRUE@libffi_la_SOURCES = @POWERPC_TRUE@$(libffi_la_common_SOURCES) $(TARGET_SRC_POWERPC)
@ARM_TRUE@libffi_la_SOURCES = @ARM_TRUE@$(libffi_la_common_SOURCES) $(TARGET_SRC_ARM)
@@ -155,6 +196,8 @@ libffi_la_LIBADD =
@ALPHA_TRUE@raw_api.lo java_raw_api.lo ffi.lo osf.lo
@ARM_TRUE@am_libffi_la_OBJECTS = debug.lo prep_cif.lo types.lo \
@ARM_TRUE@raw_api.lo java_raw_api.lo sysv.lo ffi.lo
+@IA64_TRUE@am_libffi_la_OBJECTS = debug.lo prep_cif.lo types.lo \
+@IA64_TRUE@raw_api.lo java_raw_api.lo ffi.lo unix.lo
@M68K_TRUE@am_libffi_la_OBJECTS = debug.lo prep_cif.lo types.lo \
@M68K_TRUE@raw_api.lo java_raw_api.lo ffi.lo sysv.lo
@MIPS_GCC_TRUE@am_libffi_la_OBJECTS = debug.lo prep_cif.lo types.lo \
@@ -179,8 +222,9 @@ COMPILE = $(CC) $(DEFS) $(INCLUDES) $(AM
LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
CFLAGS = @CFLAGS@
CCLD = $(CC)
-LINK = $(LIBTOOL) --mode=link "$(CCLD)" $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
+LINK = $(LIBTOOL) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
DIST_SOURCES = $(libffi_la_SOURCES) $(ffitest_SOURCES)
+depcomp =
DIST_COMMON = README ./stamp-h.in ChangeLog Makefile.am Makefile.in \
acconfig.h aclocal.m4 config.guess config.sub configure configure.in \
fficonfig.h.in install-sh ltconfig ltmain.sh missing mkinstalldirs
@@ -189,7 +233,6 @@ fficonfig.h.in install-sh ltconfig ltmai
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
GZIP_ENV = --best
-depcomp =
SOURCES = $(libffi_la_SOURCES) $(ffitest_SOURCES)
OBJECTS = $(am_libffi_la_OBJECTS) $(am_ffitest_OBJECTS)
@@ -296,6 +339,7 @@ java_raw_api.lo: src/java_raw_api.c
ffi.lo: src/alpha/ffi.c
osf.lo: src/alpha/osf.S
sysv.lo: src/arm/sysv.S
+unix.lo: src/ia64/unix.S
o32.lo: src/mips/o32.S
n32.lo: src/mips/n32.S
v8.lo: src/sparc/v8.S
@@ -330,6 +374,59 @@ ffitest$(EXEEXT): $(ffitest_OBJECTS) $(f
.s.lo:
$(LTCOMPILE) -c -o $@ $<
+# This directory's subdirectories are mostly independent; you can cd
+# into them and run `make' without going through this Makefile.
+# To change the values of `make' variables: instead of editing Makefiles,
+# (1) if the variable is set in `config.status', edit `config.status'
+# (which will cause the Makefiles to be regenerated when you run `make');
+# (2) otherwise, pass the desired values on the `make' command line.
+
+all-recursive install-data-recursive install-exec-recursive \
+installdirs-recursive install-recursive uninstall-recursive install-info-recursive \
+check-recursive installcheck-recursive info-recursive dvi-recursive:
+ @set fnord $(MAKEFLAGS); amf=$$2; \
+ dot_seen=no; \
+ target=`echo $@ | sed s/-recursive//`; \
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ echo "Making $$target in $$subdir"; \
+ if test "$$subdir" = "."; then \
+ dot_seen=yes; \
+ local_target="$$target-am"; \
+ else \
+ local_target="$$target"; \
+ fi; \
+ (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+ || case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \
+ done; \
+ if test "$$dot_seen" = "no"; then \
+ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
+ fi; test -z "$$fail"
+
+mostlyclean-recursive clean-recursive distclean-recursive \
+maintainer-clean-recursive:
+ @set fnord $(MAKEFLAGS); amf=$$2; \
+ dot_seen=no; \
+ rev=''; list='$(SUBDIRS)'; for subdir in $$list; do \
+ rev="$$subdir $$rev"; \
+ if test "$$subdir" = "."; then dot_seen=yes; else :; fi; \
+ done; \
+ test "$$dot_seen" = "no" && rev=". $$rev"; \
+ target=`echo $@ | sed s/-recursive//`; \
+ for subdir in $$rev; do \
+ echo "Making $$target in $$subdir"; \
+ if test "$$subdir" = "."; then \
+ local_target="$$target-am"; \
+ else \
+ local_target="$$target"; \
+ fi; \
+ (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+ || case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \
+ done && test -z "$$fail"
+tags-recursive:
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
+ done
+
tags: TAGS
ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
@@ -339,12 +436,17 @@ ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS
done | \
$(AWK) ' { files[$$0] = 1; } \
END { for (i in files) print i; }'`; \
- mkid -f$$here/ID $$unique $(LISP)
+ mkid -fID $$unique $(LISP)
-TAGS: $(HEADERS) $(SOURCES) fficonfig.h.in $(TAGS_DEPENDENCIES) \
+TAGS: tags-recursive $(HEADERS) $(SOURCES) fficonfig.h.in $(TAGS_DEPENDENCIES) \
$(TAGS_FILES) $(LISP)
tags=; \
here=`pwd`; \
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ if test "$$subdir" = .; then :; else \
+ test -f $$subdir/TAGS && tags="$$tags -i $$here/$$subdir/TAGS"; \
+ fi; \
+ done; \
list='$(SOURCES) $(HEADERS) $(TAGS_FILES)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
@@ -423,42 +525,53 @@ distdir: $(DISTFILES)
@for file in $(DISTFILES); do \
if test -f $$file; then d=.; else d=$(srcdir); fi; \
if test -d $$d/$$file; then \
- cp -pR $$d/$$file $(distdir); \
+ cp -pR $$d/$$file $(distdir) \
+ || exit 1; \
else \
test -f $(distdir)/$$file \
- || ln $$d/$$file $(distdir)/$$file 2> /dev/null \
- || cp -p $$d/$$file $(distdir)/$$file || :; \
+ || cp -p $$d/$$file $(distdir)/$$file \
+ || exit 1; \
+ fi; \
+ done
+ for subdir in $(SUBDIRS); do \
+ if test "$$subdir" = .; then :; else \
+ test -d $(distdir)/$$subdir \
+ || mkdir $(distdir)/$$subdir \
+ || exit 1; \
+ (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir=../$(distdir) distdir=../$(distdir)/$$subdir distdir) \
+ || exit 1; \
fi; \
done
info-am:
-info: info-am
+info: info-recursive
dvi-am:
-dvi: dvi-am
+dvi: dvi-recursive
check-am:
-check: check-am
+check: check-recursive
installcheck-am:
-installcheck: installcheck-am
+installcheck: installcheck-recursive
install-info-am:
-install-info: install-info-am
+install-info: install-info-recursive
all-recursive-am: fficonfig.h
$(MAKE) $(AM_MAKEFLAGS) all-recursive
install-exec-am: install-toolexeclibLTLIBRARIES
-install-exec: install-exec-am
+install-exec: install-exec-recursive
install-data-am:
-install-data: install-data-am
+install-data: install-data-recursive
install-am: all-am
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
-install: install-am
+install: install-recursive
uninstall-am: uninstall-toolexeclibLTLIBRARIES
-uninstall: uninstall-am
+uninstall: uninstall-recursive
all-am: Makefile $(LTLIBRARIES) $(PROGRAMS) fficonfig.h
-all-redirect: all-am
+all-redirect: all-recursive-am
install-strip:
$(MAKE) $(AM_MAKEFLAGS) INSTALL_STRIP_FLAG=-s install
-installdirs:
+installdirs: installdirs-recursive
+installdirs-am:
$(mkinstalldirs) $(DESTDIR)$(toolexeclibdir)
@@ -477,13 +590,13 @@ mostlyclean-am: mostlyclean-hdr mostlyc
mostlyclean-noinstPROGRAMS mostlyclean-tags \
mostlyclean-generic
-mostlyclean: mostlyclean-am
+mostlyclean: mostlyclean-recursive
clean-am: clean-hdr clean-toolexeclibLTLIBRARIES clean-compile \
clean-libtool clean-noinstPROGRAMS clean-tags \
clean-generic mostlyclean-am
-clean: clean-am
+clean: clean-recursive
distclean-am: distclean-hdr distclean-toolexeclibLTLIBRARIES \
distclean-compile distclean-libtool \
@@ -491,7 +604,7 @@ distclean-am: distclean-hdr distclean-t
distclean-generic clean-am
-rm -f libtool
-distclean: distclean-am
+distclean: distclean-recursive
-rm -f config.status
maintainer-clean-am: maintainer-clean-hdr \
@@ -502,7 +615,7 @@ maintainer-clean-am: maintainer-clean-h
@echo "This command is intended for maintainers to use;"
@echo "it deletes files that may require special tools to rebuild."
-maintainer-clean: maintainer-clean-am
+maintainer-clean: maintainer-clean-recursive
-rm -f config.status
.PHONY: mostlyclean-hdr distclean-hdr clean-hdr maintainer-clean-hdr \
@@ -513,15 +626,44 @@ mostlyclean-compile distclean-compile cl
maintainer-clean-compile mostlyclean-libtool distclean-libtool \
clean-libtool maintainer-clean-libtool mostlyclean-noinstPROGRAMS \
distclean-noinstPROGRAMS clean-noinstPROGRAMS \
-maintainer-clean-noinstPROGRAMS tags mostlyclean-tags distclean-tags \
-clean-tags maintainer-clean-tags distdir info-am info dvi-am dvi check \
-check-am installcheck-am installcheck install-info-am install-info \
-all-recursive-am install-exec-am install-exec install-data-am \
-install-data install-am install uninstall-am uninstall all-redirect \
-all-am all install-strip installdirs mostlyclean-generic \
-distclean-generic clean-generic maintainer-clean-generic clean \
-mostlyclean distclean maintainer-clean
-
+maintainer-clean-noinstPROGRAMS install-recursive uninstall-recursive \
+install-data-recursive uninstall-data-recursive install-exec-recursive \
+uninstall-exec-recursive installdirs-recursive uninstalldirs-recursive \
+all-recursive check-recursive installcheck-recursive info-recursive \
+dvi-recursive mostlyclean-recursive distclean-recursive clean-recursive \
+maintainer-clean-recursive tags tags-recursive mostlyclean-tags \
+distclean-tags clean-tags maintainer-clean-tags distdir info-am info \
+dvi-am dvi check check-am installcheck-am installcheck install-info-am \
+install-info all-recursive-am install-exec-am install-exec \
+install-data-am install-data install-am install uninstall-am uninstall \
+all-redirect all-am all install-strip installdirs-am installdirs \
+mostlyclean-generic distclean-generic clean-generic \
+maintainer-clean-generic clean mostlyclean distclean maintainer-clean
+
+
+# Multilib support.
+.PHONY: all-multi mostlyclean-multi clean-multi distclean-multi \
+ maintainer-clean-multi
+
+all-recursive: all-multi
+install-recursive: install-multi
+mostlyclean-recursive: mostlyclean-multi
+clean-recursive: clean-multi
+distclean-recursive: distclean-multi
+maintainer-clean-recursive: maintainer-clean-multi
+
+all-multi:
+ $(MULTIDO) $(AM_MAKEFLAGS) DO=all multi-do
+install-multi:
+ $(MULTIDO) $(AM_MAKEFLAGS) DO=install multi-do
+mostlyclean-multi:
+ $(MULTICLEAN) $(AM_MAKEFLAGS) DO=mostlyclean multi-clean
+clean-multi:
+ $(MULTICLEAN) $(AM_MAKEFLAGS) DO=clean multi-clean
+distclean-multi:
+ $(MULTICLEAN) $(AM_MAKEFLAGS) DO=distclean multi-clean
+maintainer-clean-multi:
+ $(MULTICLEAN) $(AM_MAKEFLAGS) DO=maintainer-clean multi-clean
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
--- libgcj/libjava/Makefile.in.jj Thu Apr 27 11:35:34 2000
+++ libgcj/libjava/Makefile.in Fri Apr 28 14:48:29 2000
@@ -157,7 +157,7 @@ data_DATA = libgcj.zip
@CANADIAN_FALSE@expanded = \
@CANADIAN_FALSE@`cd $(MULTIBUILDTOP)../$(COMPPATH)/gcc && pwd`
-GCJCOMPILE = CLASSPATH=$(here) $(LIBTOOL) --mode=compile $(GCJ) -fassume-compiled $(JC1FLAGS) -c
+GCJCOMPILE = CLASSPATH=$(here) $(LIBTOOL) --mode=compile $(GCJ) -fassume-compiled -L$(here) $(JC1FLAGS) -c
JAVAC = $(GCJ) -C
@@ -172,8 +172,8 @@ AM_CXXFLAGS = -fno-rtti -fvtable-thunks
@USING_GCC_FALSE@AM_CFLAGS = \
@USING_GCC_FALSE@@LIBGCJ_CFLAGS@
-JCFLAGS = -g -L$(here)
-JC1FLAGS = -g -L$(here) @LIBGCJ_JAVAFLAGS@
+JCFLAGS = -g
+JC1FLAGS = -g @LIBGCJ_JAVAFLAGS@
LIBFFIINCS = -I$(top_srcdir)/../libffi/include -I$(MULTIBUILDTOP)../libffi/include
@@ -204,7 +204,7 @@ libgcj_la_DEPENDENCIES = libgcj.zip $(ja
libgcj_la_LIBADD = $(javao_files) $(nat_files) $(c_files) $(GCOBJS) \
$(THREADOBJS) $(libffi_files) $(LIBLTDL)
-libgcj_la_LDFLAGS = -rpath $(toolexeclibdir) \
+libgcj_la_LDFLAGS = -L../libstdc++ -rpath $(toolexeclibdir) \
-version-info `grep -v '^\#' $(srcdir)/libtool-version`
@@ -240,9 +240,9 @@ CONVERT_DIR = gnu/gcj/convert
jv_convert_SOURCES =
EXTRA_jv_convert_SOURCES = $(convert_source_files)
jv_convert_LDFLAGS = --main=gnu.gcj.convert.Convert \
- -rpath $(toolexeclibdir)
+ -rpath `if test -d ../libstdc++; then cd ../libstdc++; pwd; fi` -rpath $(toolexeclibdir)
-jv_convert_LINK = $(LIBTOOL) --mode=link $(GCJ) $(JC1FLAGS) $(LDFLAGS) \
+jv_convert_LINK = $(LIBTOOL) --mode=link $(GCJ) -L$(here) $(JC1FLAGS) $(LDFLAGS) \
-o jv-convert
jv_convert_LDADD = $(convert_source_files:.java=.lo) libgcj.la \
@@ -253,8 +253,8 @@ jv_convert_DEPENDENCIES = $(convert_sour
gij_SOURCES = gij.cc
-gij_LDFLAGS = -rpath $(toolexeclibdir)
-gij_LINK = $(LIBTOOL) --mode=link $(GCJ) $(JC1FLAGS) $(LDFLAGS) \
+gij_LDFLAGS = -rpath `if test -d ../libstdc++; then cd ../libstdc++; pwd; fi` -rpath $(toolexeclibdir)
+gij_LINK = $(LIBTOOL) --mode=link $(GCJ) -L$(here) $(JC1FLAGS) $(LDFLAGS) \
-o gij
gij_LDADD = libgcj.la $(GCLIBS) $(THREADLIBS) $(ZLIBS) -L$(here)/.libs
@@ -1671,13 +1671,13 @@ $(awt_java_source_files:.java=.class): l
$(built_java_source_files:.java=.class): $(built_java_source_files)
javac="$(JAVAC)"; \
- $$javac $(JCFLAGS) -classpath $(here):`cd $(srcdir) && /bin/pwd` \
+ $$javac -L$(here) $(JCFLAGS) -classpath $(here):`cd $(srcdir) && /bin/pwd` \
-d $(here) $?
libgcj.zip: $(java_source_files) $(cond_awt_java_source_files)
$(MAKE) $(built_java_source_files:.java=.class)
javac="$(JAVAC)"; cd $(srcdir); \
- $$javac $(JCFLAGS) -classpath $(here):`/bin/pwd` -d $(here) \
+ $$javac -L$(here) $(JCFLAGS) -classpath $(here):`/bin/pwd` -d $(here) \
$(subst $(srcdir)/,,$?)
-@rm -f libgcj.zip
$(ZIP) -r libgcj java gnu -n .class -i '*.class' -i '*/'
--- libgcj/libjava/Makefile.am.jj Thu Apr 27 11:35:33 2000
+++ libgcj/libjava/Makefile.am Fri Apr 28 14:48:29 2000
@@ -71,7 +71,7 @@ GCJH = $(MULTIBUILDTOP)../$(COMPPATH)/gc
ZIP = $(MULTIBUILDTOP)../$(COMPPATH)/zip/zip$(EXEEXT)
endif # CANADIAN
-GCJCOMPILE = CLASSPATH=$(here) $(LIBTOOL) --mode=compile $(GCJ) -fassume-compiled $(JC1FLAGS) -c
+GCJCOMPILE = CLASSPATH=$(here) $(LIBTOOL) --mode=compile $(GCJ) -fassume-compiled -L$(here) $(JC1FLAGS) -c
JAVAC = $(GCJ) -C
@@ -91,8 +91,8 @@ else
AM_CFLAGS = @LIBGCJ_CFLAGS@
endif
-JCFLAGS = -g -L$(here)
-JC1FLAGS = -g -L$(here) @LIBGCJ_JAVAFLAGS@
+JCFLAGS = -g
+JC1FLAGS = -g @LIBGCJ_JAVAFLAGS@
LIBFFIINCS = -I$(top_srcdir)/../libffi/include -I$(MULTIBUILDTOP)../libffi/include
@@ -128,7 +128,7 @@ libgcj_la_DEPENDENCIES = libgcj.zip $(ja
$(c_files) $(GCOBJS) $(THREADOBJS) $(LIBLTDL)
libgcj_la_LIBADD = $(javao_files) $(nat_files) $(c_files) $(GCOBJS) \
$(THREADOBJS) $(libffi_files) $(LIBLTDL)
-libgcj_la_LDFLAGS = -rpath $(toolexeclibdir) \
+libgcj_la_LDFLAGS = -L../libstdc++ -rpath $(toolexeclibdir) \
## The mysterious backslash is consumed by make.
-version-info `grep -v '^\#' $(srcdir)/libtool-version`
@@ -154,7 +154,7 @@ $(built_java_source_files:.java=.class):
## This little nastiness is here so that the backquoted stuff in the
## GCJ definition can be correctly expanded, if required.
javac="$(JAVAC)"; \
- $$javac $(JCFLAGS) -classpath $(here):`cd $(srcdir) && /bin/pwd` \
+ $$javac -L$(here) $(JCFLAGS) -classpath $(here):`cd $(srcdir) && /bin/pwd` \
-d $(here) $?
## We have the zip file depend on the java sources and not the class
@@ -170,7 +170,7 @@ libgcj.zip: $(java_source_files) $(cond_
## This little nastiness is here so that the backquoted stuff in the
## GCJ definition can be correctly expanded, if required.
javac="$(JAVAC)"; cd $(srcdir); \
- $$javac $(JCFLAGS) -classpath $(here):`/bin/pwd` -d $(here) \
+ $$javac -L$(here) $(JCFLAGS) -classpath $(here):`/bin/pwd` -d $(here) \
$(subst $(srcdir)/,,$?)
-@rm -f libgcj.zip
## Note that we explicitly want to include directory information.
@@ -361,8 +361,8 @@ EXTRA_jv_convert_SOURCES = $(convert_sou
## need this because we are explicitly using libtool to link using the
## `.la' file.
jv_convert_LDFLAGS = --main=gnu.gcj.convert.Convert \
- -rpath $(toolexeclibdir)
-jv_convert_LINK = $(LIBTOOL) --mode=link $(GCJ) $(JC1FLAGS) $(LDFLAGS) \
+ -rpath `if test -d ../libstdc++; then cd ../libstdc++; pwd; fi` -rpath $(toolexeclibdir)
+jv_convert_LINK = $(LIBTOOL) --mode=link $(GCJ) -L$(here) $(JC1FLAGS) $(LDFLAGS) \
-o jv-convert
## We explicitly link in the libraries we need. This way we don't
## need -nodefaultlibs, so we can still rely on gcj picking up the
@@ -380,8 +380,8 @@ gij_SOURCES = gij.cc
## We need -nodefaultlibs because we want to avoid gcj's `-lgcj'. We
## need this because we are explicitly using libtool to link using the
## `.la' file.
-gij_LDFLAGS = -rpath $(toolexeclibdir)
-gij_LINK = $(LIBTOOL) --mode=link $(GCJ) $(JC1FLAGS) $(LDFLAGS) \
+gij_LDFLAGS = -rpath `if test -d ../libstdc++; then cd ../libstdc++; pwd; fi` -rpath $(toolexeclibdir)
+gij_LINK = $(LIBTOOL) --mode=link $(GCJ) -L$(here) $(JC1FLAGS) $(LDFLAGS) \
-o gij
## We explicitly link in the libraries we need. This way we don't
## need -nodefaultlibs, so we can still rely on gcj picking up the
--- libgcj/ltconfig.jj Tue Aug 3 05:16:01 1999
+++ libgcj/ltconfig Fri Apr 28 14:48:29 2000
@@ -1059,6 +1059,29 @@ else
fi
echo "$ac_t$with_gnu_ld" 1>&6
+extra_compiler_flags=
+extra_compiler_flags_value=
+if test "$with_gcc" = yes; then
+ extra_compiler_flags_value="-B|-b|-V"
+ extra_compiler_flags="-B*|-b*|-V*"
+ # Check to see what are the possible multilibing options
+ echo $ac_n "checking what multilib options $compiler supports ... $ac_c" 1>&6
+ multilibopts=
+ if ${CC-cc} -print-multi-lib >/dev/null 2>&1; then
+ for dir in `${CC-cc} -print-multi-lib 2>/dev/null`; do
+ multilibopts="$multilibopts`echo $dir | sed -e 's/^[^;]*;//' -e 's/@/ -/g'`"
+ done
+ fi
+ # Kill any whitespace at the beginning and end
+ multilibopts=`echo $multilibopts`
+ if test -n "$multilibopts"; then
+ extra_compiler_flags="$extra_compiler_flags`echo $multilibopts | sed -e 's/ -/|-/g' -e 's/^-/|-/'`"
+ echo "$ac_t$multilibopts" 1>&6
+ else
+ echo "$ac_t"none 1>&6
+ fi
+fi
+
# See if the linker supports building shared libraries.
echo $ac_n "checking whether the linker ($LD) supports shared libraries... $ac_c" 1>&6
@@ -1188,8 +1211,8 @@ EOF
netbsd*)
if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $linkopts ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $linkopts ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
+ archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $linkopts ${wl}-soname $wl$soname -o $lib'
+ archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $linkopts ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
else
archive_cmds='$LD -Bshareable $libobjs $deplibs $linkopts -o $lib'
# can we support soname and/or expsyms with a.out? -oliva
@@ -1226,8 +1249,8 @@ EOF
*)
if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $linkopts ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $linkopts ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
+ archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $linkopts ${wl}-soname $wl$soname -o $lib'
+ archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $linkopts ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
else
ld_shlibs=no
fi
@@ -1350,7 +1373,7 @@ else
# FreeBSD 3 and greater uses gcc -shared to do shared libraries.
freebsd*)
- archive_cmds='$CC -shared -o $lib $libobjs $deplibs $linkopts'
+ archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags $linkopts'
hardcode_libdir_flag_spec='-R$libdir'
hardcode_direct=yes
hardcode_shlibpath_var=no
@@ -1371,9 +1394,9 @@ else
irix5* | irix6*)
if test "$with_gcc" = yes; then
- archive_cmds='$CC -shared $libobjs $deplibs $linkopts ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${objdir}/so_locations -o $lib'
+ archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $linkopts ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${objdir}/so_locations -o $lib'
else
- archive_cmds='$LD -shared $libobjs $deplibs $linkopts -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${objdir}/so_locations -o $lib'
+ archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags $linkopts -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${objdir}/so_locations -o $lib'
fi
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
hardcode_libdir_separator=:
@@ -1408,7 +1431,7 @@ else
osf3* | osf4*)
if test "$with_gcc" = yes; then
allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $linkopts ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${objdir}/so_locations -o $lib'
+ archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags $linkopts ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${objdir}/so_locations -o $lib'
else
allow_undefined_flag=' -expect_unresolved \*'
archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linkopts -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${objdir}/so_locations -o $lib'
@@ -1937,6 +1960,13 @@ linux-gnu*)
*) dynamic_linker='Linux ld.so' ;;
esac
fi
+ case "$host_cpu" in
+ sparc64)
+ libsuff=64
+ sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
+ sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
+ ;;
+ esac
;;
netbsd*)
@@ -2615,7 +2645,8 @@ case "$ltmain" in
finish_cmds finish_eval global_symbol_pipe global_symbol_to_cdecl \
hardcode_libdir_flag_spec hardcode_libdir_separator \
sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
- compiler_c_o compiler_o_lo need_locks exclude_expsyms include_expsyms; do
+ compiler_c_o compiler_o_lo need_locks exclude_expsyms include_expsyms \
+ extra_compiler_flags extra_compiler_flags_value; do
case "$var" in
reload_cmds | old_archive_cmds | old_archive_from_new_cmds | \
@@ -2848,6 +2879,10 @@ archive_cmds=$archive_cmds
archive_expsym_cmds=$archive_expsym_cmds
postinstall_cmds=$postinstall_cmds
postuninstall_cmds=$postuninstall_cmds
+
+# Case patterns for extra compiler flags needed for linking
+extra_compiler_flags=$extra_compiler_flags
+extra_compiler_flags_value=$extra_compiler_flags_value
# Method to check whether dependent libraries are shared objects.
deplibs_check_method=$deplibs_check_method
--- libgcj/ltmain.sh.jj Sat Oct 16 23:51:09 1999
+++ libgcj/ltmain.sh Fri Apr 28 14:48:29 2000
@@ -812,6 +812,7 @@ compiler."
finalize_command="$CC"
compile_rpath=
+ compiler_flags=
finalize_rpath=
compile_shlibpath=
finalize_shlibpath=
@@ -979,6 +980,13 @@ compiler."
prev=
continue
;;
+ B|b|V)
+ compiler_flags="$compiler_flags -$prev$qarg"
+ prev=
+ compile_command="$compile_command -$prev$qarg"
+ finalize_command="$finalize_command -$prev$qarg"
+ continue
+ ;;
*)
eval "$prev=\"\$arg\""
prev=
@@ -1156,6 +1164,17 @@ compiler."
# Some other compiler flag.
-* | +*)
+ if test "X$extra_compiler_flags_value" != "X"; then
+ is_extra_compiler_flag=
+ eval "case \"\$arg\" in \
+ $extra_compiler_flags_value) \
+ is_extra_compiler_flag=yes ;; \
+ esac"
+ if test "$is_extra_compiler_flag"; then
+ prev=`echo "X$arg" | $Xsed -e 's/^-//'`
+ continue
+ fi
+ fi
# Unknown arguments in both finalize_command and compile_command need
# to be aesthetically quoted because they are evaled later.
arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"`
@@ -1164,6 +1183,16 @@ compiler."
arg="\"$arg\""
;;
esac
+ if test "X$extra_compiler_flags" != "X"; then
+ is_extra_compiler_flag=
+ eval "case \"\$arg\" in \
+ $extra_compiler_flags) \
+ is_extra_compiler_flag=yes ;; \
+ esac"
+ if test "$is_extra_compiler_flag"; then
+ compiler_flags="$compiler_flags $arg"
+ fi
+ fi
;;
*.o | *.obj | *.a | *.lib)
--- libgcj/config-ml.in.jj Mon Sep 6 21:28:20 1999
+++ libgcj/config-ml.in Fri Apr 28 14:48:34 2000
@@ -498,6 +498,7 @@ multi-do:
LIBCFLAGS="$(LIBCFLAGS) $${flags}" \
LIBCXXFLAGS="$(LIBCXXFLAGS) $${flags}" \
LDFLAGS="$(LDFLAGS) $${flags}" \
+ JC1FLAGS="$(JC1FLAGS) $${flags}" \
$(DO)); then \
true; \
else \
Jakub