summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlan Modra <amodra@bigpond.net.au>2009-09-07 10:54:24 +0000
committerAlan Modra <amodra@bigpond.net.au>2009-09-07 10:54:24 +0000
commit88ef4d4b9ed0be349ed8ca6971dc6f271ffc076c (patch)
tree77212f4513520ce9988e36d2f7e12aa82f1ddd47
parentd99679abffaabb7d8c004d47ae253fe8f0c2bd6a (diff)
downloadgdb-88ef4d4b9ed0be349ed8ca6971dc6f271ffc076c.tar.gz
* configure.in (BUILD_LIBS, BUILD_LIB_DEPS): Define and subst.
* configure: Regenerate. * Makefile.am (LIBIBERTY, BUILD_LIBIBERTY, BUILD_LIBINTL): Delete. (BUILD_LIBS, BUILD_LIB_DEPS): Define. Use.. (i386-gen, ia64-gen, z8kgen): ..here. * Makefile.in: Regenerate.
-rw-r--r--opcodes/ChangeLog9
-rw-r--r--opcodes/Makefile.am20
-rw-r--r--opcodes/Makefile.in21
-rwxr-xr-xopcodes/configure46
-rw-r--r--opcodes/configure.in16
5 files changed, 73 insertions, 39 deletions
diff --git a/opcodes/ChangeLog b/opcodes/ChangeLog
index 9772f59a564..5ae8aede481 100644
--- a/opcodes/ChangeLog
+++ b/opcodes/ChangeLog
@@ -1,3 +1,12 @@
+2009-09-07 Alan Modra <amodra@bigpond.net.au>
+
+ * configure.in (BUILD_LIBS, BUILD_LIB_DEPS): Define and subst.
+ * configure: Regenerate.
+ * Makefile.am (LIBIBERTY, BUILD_LIBIBERTY, BUILD_LIBINTL): Delete.
+ (BUILD_LIBS, BUILD_LIB_DEPS): Define. Use..
+ (i386-gen, ia64-gen, z8kgen): ..here.
+ * Makefile.in: Regenerate.
+
2009-09-07 Tristan Gingold <gingold@adacore.com>
* z8k-opc.h: Regenerate.
diff --git a/opcodes/Makefile.am b/opcodes/Makefile.am
index 76eccbad7f8..43db72a085a 100644
--- a/opcodes/Makefile.am
+++ b/opcodes/Makefile.am
@@ -36,12 +36,8 @@ endif
# This is where bfd.h lives.
BFD_H = ../bfd/bfd.h
-# This is where libiberty lives.
-LIBIBERTY = ../libiberty/libiberty.a
-# This is only true when not cross-compiling.
-BUILD_LIBIBERTY = $(LIBIBERTY)
-# And so is this.
-BUILD_LIBINTL = $(LIBINTL)
+BUILD_LIBS = @BUILD_LIBS@
+BUILD_LIB_DEPS = @BUILD_LIB_DEPS@
# Header files.
HFILES = \
@@ -457,8 +453,8 @@ MOSTLYCLEANFILES = i386-gen$(EXEEXT_FOR_BUILD) ia64-gen$(EXEEXT_FOR_BUILD) \
MAINTAINERCLEANFILES = $(srcdir)/i386-tbl.h $(srcdir)/i386-init.h \
$(srcdir)/ia64-asmtab.c s390-opc.tab $(srcdir)/z8k-opc.h
-i386-gen$(EXEEXT_FOR_BUILD): i386-gen.o $(BUILD_LIBIBERTY) $(BUILD_LIBINTL)
- $(LINK_FOR_BUILD) i386-gen.o $(BUILD_LIBIBERTY) $(BUILD_LIBINTL)
+i386-gen$(EXEEXT_FOR_BUILD): i386-gen.o $(BUILD_LIB_DEPS)
+ $(LINK_FOR_BUILD) i386-gen.o $(BUILD_LIBS)
i386-gen.o: i386-gen.c i386-opc.h $(srcdir)/../include/opcode/i386.h \
$(INCDIR)/ansidecl.h $(INCDIR)/getopt.h $(INCDIR)/hashtab.h \
@@ -474,8 +470,8 @@ $(srcdir)/i386-init.h: @MAINT@ i386-gen$(EXEEXT_FOR_BUILD) i386-opc.tbl i386-reg
i386-opc.lo: $(srcdir)/i386-tbl.h
-ia64-gen$(EXEEXT_FOR_BUILD): ia64-gen.o $(BUILD_LIBIBERTY) $(BUILD_LIBINTL)
- $(LINK_FOR_BUILD) ia64-gen.o $(BUILD_LIBIBERTY) $(BUILD_LIBINTL)
+ia64-gen$(EXEEXT_FOR_BUILD): ia64-gen.o $(BUILD_LIB_DEPS)
+ $(LINK_FOR_BUILD) ia64-gen.o $(BUILD_LIBS)
ia64-gen.o: ia64-gen.c $(BFD_H) $(INCDIR)/ansidecl.h $(INCDIR)/getopt.h \
$(INCDIR)/libiberty.h $(INCDIR)/opcode/ia64.h $(INCDIR)/safe-ctype.h \
@@ -501,8 +497,8 @@ s390-opc.tab: s390-mkopc$(EXEEXT_FOR_BUILD) s390-opc.txt
s390-opc.lo: s390-opc.tab
-z8kgen$(EXEEXT_FOR_BUILD): z8kgen.o $(BUILD_LIBIBERTY) $(BUILD_LIBINTL)
- $(LINK_FOR_BUILD) z8kgen.o $(BUILD_LIBIBERTY) $(BUILD_LIBINTL)
+z8kgen$(EXEEXT_FOR_BUILD): z8kgen.o $(BUILD_LIB_DEPS)
+ $(LINK_FOR_BUILD) z8kgen.o $(BUILD_LIBS)
z8kgen.o: z8kgen.c
$(COMPILE_FOR_BUILD) -c $(srcdir)/z8kgen.c
diff --git a/opcodes/Makefile.in b/opcodes/Makefile.in
index bce410deb1b..5b4721af85f 100644
--- a/opcodes/Makefile.in
+++ b/opcodes/Makefile.in
@@ -140,6 +140,8 @@ AUTOHEADER = @AUTOHEADER@
AUTOMAKE = @AUTOMAKE@
AWK = @AWK@
BFD_MACHINES = @BFD_MACHINES@
+BUILD_LIBS = @BUILD_LIBS@
+BUILD_LIB_DEPS = @BUILD_LIB_DEPS@
CATALOGS = @CATALOGS@
CATOBJEXT = @CATOBJEXT@
CC = @CC@
@@ -306,13 +308,6 @@ libopcodes_la_LDFLAGS = $(am__append_1) -release `cat \
# This is where bfd.h lives.
BFD_H = ../bfd/bfd.h
-# This is where libiberty lives.
-LIBIBERTY = ../libiberty/libiberty.a
-# This is only true when not cross-compiling.
-BUILD_LIBIBERTY = $(LIBIBERTY)
-# And so is this.
-BUILD_LIBINTL = $(LIBINTL)
-
# Header files.
HFILES = \
cgen-ops.h cgen-types.h \
@@ -1297,8 +1292,8 @@ stamp-xc16x: $(CGENDEPS) $(CPUDIR)/xc16x.cpu $(CPUDIR)/xc16x.opc
$(MAKE) run-cgen arch=xc16x prefix=xc16x options= \
archfile=$(CPUDIR)/xc16x.cpu opcfile=$(CPUDIR)/xc16x.opc extrafiles=
-i386-gen$(EXEEXT_FOR_BUILD): i386-gen.o $(BUILD_LIBIBERTY) $(BUILD_LIBINTL)
- $(LINK_FOR_BUILD) i386-gen.o $(BUILD_LIBIBERTY) $(BUILD_LIBINTL)
+i386-gen$(EXEEXT_FOR_BUILD): i386-gen.o $(BUILD_LIB_DEPS)
+ $(LINK_FOR_BUILD) i386-gen.o $(BUILD_LIBS)
i386-gen.o: i386-gen.c i386-opc.h $(srcdir)/../include/opcode/i386.h \
$(INCDIR)/ansidecl.h $(INCDIR)/getopt.h $(INCDIR)/hashtab.h \
@@ -1314,8 +1309,8 @@ $(srcdir)/i386-init.h: @MAINT@ i386-gen$(EXEEXT_FOR_BUILD) i386-opc.tbl i386-reg
i386-opc.lo: $(srcdir)/i386-tbl.h
-ia64-gen$(EXEEXT_FOR_BUILD): ia64-gen.o $(BUILD_LIBIBERTY) $(BUILD_LIBINTL)
- $(LINK_FOR_BUILD) ia64-gen.o $(BUILD_LIBIBERTY) $(BUILD_LIBINTL)
+ia64-gen$(EXEEXT_FOR_BUILD): ia64-gen.o $(BUILD_LIB_DEPS)
+ $(LINK_FOR_BUILD) ia64-gen.o $(BUILD_LIBS)
ia64-gen.o: ia64-gen.c $(BFD_H) $(INCDIR)/ansidecl.h $(INCDIR)/getopt.h \
$(INCDIR)/libiberty.h $(INCDIR)/opcode/ia64.h $(INCDIR)/safe-ctype.h \
@@ -1336,8 +1331,8 @@ s390-opc.tab: s390-mkopc$(EXEEXT_FOR_BUILD) s390-opc.txt
s390-opc.lo: s390-opc.tab
-z8kgen$(EXEEXT_FOR_BUILD): z8kgen.o $(BUILD_LIBIBERTY) $(BUILD_LIBINTL)
- $(LINK_FOR_BUILD) z8kgen.o $(BUILD_LIBIBERTY) $(BUILD_LIBINTL)
+z8kgen$(EXEEXT_FOR_BUILD): z8kgen.o $(BUILD_LIB_DEPS)
+ $(LINK_FOR_BUILD) z8kgen.o $(BUILD_LIBS)
z8kgen.o: z8kgen.c
$(COMPILE_FOR_BUILD) -c $(srcdir)/z8kgen.c
diff --git a/opcodes/configure b/opcodes/configure
index ec7d164d779..52da1c49436 100755
--- a/opcodes/configure
+++ b/opcodes/configure
@@ -746,6 +746,8 @@ archdefs
SHARED_DEPENDENCIES
SHARED_LIBADD
SHARED_LDFLAGS
+BUILD_LIB_DEPS
+BUILD_LIBS
LIBM
cgendir
CGEN_MAINT_FALSE
@@ -5715,13 +5717,13 @@ if test "${lt_cv_nm_interface+set}" = set; then :
else
lt_cv_nm_interface="BSD nm"
echo "int some_variable = 0;" > conftest.$ac_ext
- (eval echo "\"\$as_me:5718: $ac_compile\"" >&5)
+ (eval echo "\"\$as_me:5720: $ac_compile\"" >&5)
(eval "$ac_compile" 2>conftest.err)
cat conftest.err >&5
- (eval echo "\"\$as_me:5721: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
+ (eval echo "\"\$as_me:5723: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
(eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
cat conftest.err >&5
- (eval echo "\"\$as_me:5724: output\"" >&5)
+ (eval echo "\"\$as_me:5726: output\"" >&5)
cat conftest.out >&5
if $GREP 'External.*some_variable' conftest.out > /dev/null; then
lt_cv_nm_interface="MS dumpbin"
@@ -6926,7 +6928,7 @@ ia64-*-hpux*)
;;
*-*-irix6*)
# Find out which ABI we are using.
- echo '#line 6929 "configure"' > conftest.$ac_ext
+ echo '#line 6931 "configure"' > conftest.$ac_ext
if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
(eval $ac_compile) 2>&5
ac_status=$?
@@ -8158,11 +8160,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:8161: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:8163: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:8165: \$? = $ac_status" >&5
+ echo "$as_me:8167: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -8497,11 +8499,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:8500: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:8502: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:8504: \$? = $ac_status" >&5
+ echo "$as_me:8506: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -8602,11 +8604,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:8605: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:8607: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:8609: \$? = $ac_status" >&5
+ echo "$as_me:8611: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -8657,11 +8659,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:8660: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:8662: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:8664: \$? = $ac_status" >&5
+ echo "$as_me:8666: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -11039,7 +11041,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 11042 "configure"
+#line 11044 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -11135,7 +11137,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 11138 "configure"
+#line 11140 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -12162,6 +12164,22 @@ esac
+#Libs for generator progs
+if test "x$cross_compiling" = "xno"; then
+ BUILD_LIBS=../libiberty/libiberty.a
+ BUILD_LIB_DEPS=$BUILD_LIBS
+else
+ # if cross-compiling, assume that the system provides -liberty
+ # and that the version is compatible with new headers.
+ BUILD_LIBS=-liberty
+ BUILD_LIB_DEPS=
+fi
+BUILD_LIBS="$BUILD_LIBS $LIBINTL"
+BUILD_LIB_DEPS="$BUILD_LIB_DEPS $LIBINTL_DEP"
+
+
+
+
# Horrible hacks to build DLLs on Windows and a shared library elsewhere.
SHARED_LDFLAGS=
SHARED_LIBADD=
diff --git a/opcodes/configure.in b/opcodes/configure.in
index c6344707771..75414d799a6 100644
--- a/opcodes/configure.in
+++ b/opcodes/configure.in
@@ -101,6 +101,22 @@ AC_CACHE_CHECK(linker --as-needed support, bfd_cv_ld_as_needed,
LT_LIB_M
+#Libs for generator progs
+if test "x$cross_compiling" = "xno"; then
+ BUILD_LIBS=../libiberty/libiberty.a
+ BUILD_LIB_DEPS=$BUILD_LIBS
+else
+ # if cross-compiling, assume that the system provides -liberty
+ # and that the version is compatible with new headers.
+ BUILD_LIBS=-liberty
+ BUILD_LIB_DEPS=
+fi
+BUILD_LIBS="$BUILD_LIBS $LIBINTL"
+BUILD_LIB_DEPS="$BUILD_LIB_DEPS $LIBINTL_DEP"
+
+AC_SUBST(BUILD_LIBS)
+AC_SUBST(BUILD_LIB_DEPS)
+
# Horrible hacks to build DLLs on Windows and a shared library elsewhere.
SHARED_LDFLAGS=
SHARED_LIBADD=