aboutsummaryrefslogtreecommitdiff
path: root/ld
diff options
context:
space:
mode:
authorRalf Wildenhues <Ralf.Wildenhues@gmx.de>2009-08-22 19:02:57 +0000
committerRalf Wildenhues <Ralf.Wildenhues@gmx.de>2009-08-22 19:02:57 +0000
commit14ec8efdb130026287714cd32332bb9e5a25e779 (patch)
treea476009361fde29e848ecf0d7350cc175406d212 /ld
parent758227f0c55d3081a11884e9ee66c161f7994a06 (diff)
downloadgdb-14ec8efdb130026287714cd32332bb9e5a25e779.zip
gdb-14ec8efdb130026287714cd32332bb9e5a25e779.tar.gz
gdb-14ec8efdb130026287714cd32332bb9e5a25e779.tar.bz2
Cleanups in binutils makefiles.
ld/: * Makefile.am (bin_PROGRAMS): Renamed from ... (noinst_PROGRAMS): ... this. (transform): Override, including the renaming of ld-new to ld. (install-exec-local): Installation of ld in $(bindir) not needed here any more. (AM_CPPFLAGS): Renamed from ... (INCLUDES): ... this. (MAINTAINERCLEANFILES): Add ld.1. * Makefile.in: Regenerate. gold/: * Makefile.am (AM_CPPFLAGS): Renamed from ... (INCLUDES): ... this. * testsuite/Makefile.am (AUTOMAKE_OPTIONS): Add -Wno-portability. (AM_CPPFLAGS): Renamed from ... (INCLUDE): ... this. * Makefile.in, testsuite/Makefile.in: Regenerate. bfd/: * Makefile.am (libbfd_la_LDFLAGS): Initialize early, to allow appending. [INSTALL_LIBBFD] (bfdlib_LTLIBRARIES, bfdinclude_HEADERS): Set only in this condition. [!INSTALL_LIBBFD] (noinst_LTLIBRARIES, libbfd_la_LDFLAGS): New, to build but not install libbfd.la in this condition. (install-bfdlibLTLIBRARIES, uninstall-bfdlibLTLIBRARIES) (install_libbfd, install_libbfd): Remove. * Makefile.in: Regenerate. binutils/: * Makefile.am (AM_CPPFLAGS): Renamed from ... (INCLUDES): ... this. (bin2c$(EXEEXT_FOR_BUILD): Adjust rule. (installcheck-local): Renamed from ... (installcheck): ... this. * Makefile.in: Regenerate. gas/: * Makefile.am (YFLAGS): Remove, not needed any more. (AM_CPPFLAGS): Renamed from ... (INCLUDES): ... this. * Makefile.in: Regenerate. gprof/: * Makefile.am (AM_CPPFLAGS): Renamed from ... (INCLUDES): ... this. * Makefile.in: Regenerate. opcodes/: * Makefile.am (libopcodes_la_LDFLAGS): Initialize early. [INSTALL_LIBBFD] (bfdlib_LTLIBRARIES): Set only in this condition. [INSTALL_LIBBFD] (bfdinclude_DATA): New. [!INSTALL_LIBBFD] (noinst_LTLIBRARIES): New. [!INSTALL_LIBBFD] (libopcodes_la_LDFLAGS): Ensure libopcodes.la is built shared even if it is not to be installed. (install-bfdlibLTLIBRARIES,uninstall-bfdlibLTLIBRARIES) (install_libopcodes, uninstall_libopcodes): Remove. (AM_CPPFLAGS): Renamed from ... (INCLUDES): ... this. * Makefile.in: Regenerate.
Diffstat (limited to 'ld')
-rw-r--r--ld/ChangeLog10
-rw-r--r--ld/Makefile.am15
-rw-r--r--ld/Makefile.in89
3 files changed, 75 insertions, 39 deletions
diff --git a/ld/ChangeLog b/ld/ChangeLog
index ac628d8..6b11a80 100644
--- a/ld/ChangeLog
+++ b/ld/ChangeLog
@@ -1,5 +1,15 @@
2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
+ * Makefile.am (bin_PROGRAMS): Renamed from ...
+ (noinst_PROGRAMS): ... this.
+ (transform): Override, including the renaming of ld-new to ld.
+ (install-exec-local): Installation of ld in $(bindir) not needed
+ here any more.
+ (AM_CPPFLAGS): Renamed from ...
+ (INCLUDES): ... this.
+ (MAINTAINERCLEANFILES): Add ld.1.
+ * Makefile.in: Regenerate.
+
* Makefile.am (AUTOMAKE_OPTIONS): Remove cygnus. Add
no-texinfo.tex, no-dist, foreign.
(TEXINFO_TEX): New variable.
diff --git a/ld/Makefile.am b/ld/Makefile.am
index 9cd9b54..a268898 100644
--- a/ld/Makefile.am
+++ b/ld/Makefile.am
@@ -90,7 +90,8 @@ CXX_FOR_TARGET = ` \
fi; \
fi`
-noinst_PROGRAMS = ld-new
+transform = s/^ld-new$$/ld/;@program_transform_name@
+bin_PROGRAMS = ld-new
info_TEXINFOS = ld.texinfo
ld_TEXINFOS = configdoc.texi
noinst_TEXINFOS = ldint.texinfo
@@ -101,7 +102,7 @@ AM_MAKEINFOFLAGS = -I $(srcdir) -I $(BFDDIR)/doc -I ../bfd/doc \
TEXI2DVI = texi2dvi -I $(srcdir) -I $(BFDDIR)/doc -I ../bfd/doc \
-I $(top_srcdir)/../libiberty
-INCLUDES = -I. -I$(srcdir) -I../bfd -I$(BFDDIR) -I$(INCDIR) \
+AM_CPPFLAGS = -I. -I$(srcdir) -I../bfd -I$(BFDDIR) -I$(INCDIR) \
@INCINTL@ $(HDEFINES) $(CFLAGS) \
-DLOCALEDIR="\"$(datadir)/locale\""
@@ -1924,7 +1925,7 @@ ld.1: $(srcdir)/ld.texinfo configdoc.texi
(rm -f $@.T$$$$ && exit 1)
rm -f ld.pod
-MAINTAINERCLEANFILES = configdoc.texi
+MAINTAINERCLEANFILES = configdoc.texi ld.1
# We want to reconfigure if configure.host or configure.tgt changes. We
# extract version from bfd/configure.in, so we must depend on that also.
@@ -1940,13 +1941,7 @@ CLEANFILES = dep.sed DEP DEPA DEP1 DEP2 spu_ovl.s spu_ovl.o spu_icache.s spu_ica
.PHONY: install-exec-local install-data-local
install-exec-local: ld-new$(EXEEXT)
- $(mkinstalldirs) $(DESTDIR)$(bindir) $(DESTDIR)$(tooldir)/bin
- @list='$(noinst_PROGRAMS)'; for p in $$list; do \
- if test -f $$p; then \
- echo " $(LIBTOOL) --mode=install $(INSTALL_PROGRAM) $$p $(bindir)/`echo $$p|sed -e 's/$(EXEEXT)$$//' -e 's/-new//'|sed '$(transform)'|sed 's/$$/$(EXEEXT)/'`"; \
- $(LIBTOOL) --mode=install $(INSTALL_PROGRAM) $$p $(DESTDIR)$(bindir)/`echo $$p|sed -e 's/$(EXEEXT)$$//' -e 's/-new//'|sed '$(transform)'|sed 's/$$/$(EXEEXT)/'`; \
- else :; fi; \
- done
+ $(mkinstalldirs) $(DESTDIR)$(tooldir)/bin
n=`echo ld | sed '$(transform)'`; \
if [ "$(bindir)/$$n$(EXEEXT)" != "$(tooldir)/bin/ld$(EXEEXT)" ]; then \
rm -f $(DESTDIR)$(tooldir)/bin/ld$(EXEEXT); \
diff --git a/ld/Makefile.in b/ld/Makefile.in
index 137fa54..80105a2 100644
--- a/ld/Makefile.in
+++ b/ld/Makefile.in
@@ -25,7 +25,6 @@ install_sh_DATA = $(install_sh) -c -m 644
install_sh_PROGRAM = $(install_sh) -c
install_sh_SCRIPT = $(install_sh) -c
INSTALL_HEADER = $(INSTALL_DATA)
-transform = $(program_transform_name)
NORMAL_INSTALL = :
PRE_INSTALL = :
POST_INSTALL = :
@@ -35,7 +34,7 @@ POST_UNINSTALL = :
build_triplet = @build@
host_triplet = @host@
target_triplet = @target@
-noinst_PROGRAMS = ld-new$(EXEEXT)
+bin_PROGRAMS = ld-new$(EXEEXT)
# Automake 1.9 will only build info files in the objdir if they are
# mentioned in DISTCLEANFILES. It doesn't have to be unconditional,
@@ -69,7 +68,9 @@ mkinstalldirs = $(SHELL) $(top_srcdir)/../mkinstalldirs
CONFIG_HEADER = config.h
CONFIG_CLEAN_FILES = po/Makefile.in
CONFIG_CLEAN_VPATH_FILES =
-PROGRAMS = $(noinst_PROGRAMS)
+am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(infodir)" \
+ "$(DESTDIR)$(man1dir)"
+PROGRAMS = $(bin_PROGRAMS)
am_ld_new_OBJECTS = ldgram.$(OBJEXT) ldlex.$(OBJEXT) lexsup.$(OBJEXT) \
ldlang.$(OBJEXT) mri.$(OBJEXT) ldctor.$(OBJEXT) \
ldmain.$(OBJEXT) ldwrite.$(OBJEXT) ldexp.$(OBJEXT) \
@@ -118,7 +119,6 @@ RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
install-pdf-recursive install-ps-recursive install-recursive \
installcheck-recursive installdirs-recursive pdf-recursive \
ps-recursive uninstall-recursive
-am__installdirs = "$(DESTDIR)$(infodir)" "$(DESTDIR)$(man1dir)"
am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
am__vpath_adj = case $$p in \
$(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
@@ -152,6 +152,7 @@ CTAGS = ctags
DEJATOOL = $(PACKAGE)
RUNTESTDEFAULTFLAGS = --tool $$tool --srcdir $$srcdir
DIST_SUBDIRS = $(SUBDIRS)
+transform = s/^ld-new$$/ld/;@program_transform_name@
ACLOCAL = @ACLOCAL@
AMTAR = @AMTAR@
AR = @AR@
@@ -388,7 +389,7 @@ AM_MAKEINFOFLAGS = -I $(srcdir) -I $(BFDDIR)/doc -I ../bfd/doc \
TEXI2DVI = texi2dvi -I $(srcdir) -I $(BFDDIR)/doc -I ../bfd/doc \
-I $(top_srcdir)/../libiberty
-INCLUDES = -I. -I$(srcdir) -I../bfd -I$(BFDDIR) -I$(INCDIR) \
+AM_CPPFLAGS = -I. -I$(srcdir) -I../bfd -I$(BFDDIR) -I$(INCDIR) \
@INCINTL@ $(HDEFINES) $(CFLAGS) \
-DLOCALEDIR="\"$(datadir)/locale\""
@@ -766,7 +767,7 @@ ld_new_SOURCES = ldgram.y ldlex.l lexsup.c ldlang.c mri.c ldctor.c ldmain.c \
ld_new_DEPENDENCIES = $(EMULATION_OFILES) $(EMUL_EXTRA_OFILES) $(BFDLIB) $(LIBIBERTY) $(LIBINTL_DEP)
ld_new_LDADD = $(EMULATION_OFILES) $(EMUL_EXTRA_OFILES) $(BFDLIB) $(LIBIBERTY) $(LIBINTL)
-MAINTAINERCLEANFILES = configdoc.texi ld.info
+MAINTAINERCLEANFILES = configdoc.texi ld.1 ld.info
# We want to reconfigure if configure.host or configure.tgt changes. We
# extract version from bfd/configure.in, so we must depend on that also.
@@ -842,9 +843,43 @@ distclean-hdr:
-rm -f config.h stamp-h1
po/Makefile.in: $(top_builddir)/config.status $(top_srcdir)/po/Make-in
cd $(top_builddir) && $(SHELL) ./config.status $@
-
-clean-noinstPROGRAMS:
- @list='$(noinst_PROGRAMS)'; test -n "$$list" || exit 0; \
+install-binPROGRAMS: $(bin_PROGRAMS)
+ @$(NORMAL_INSTALL)
+ test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)"
+ @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
+ for p in $$list; do echo "$$p $$p"; done | \
+ sed 's/$(EXEEXT)$$//' | \
+ while read p p1; do if test -f $$p || test -f $$p1; \
+ then echo "$$p"; echo "$$p"; else :; fi; \
+ done | \
+ sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \
+ -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \
+ sed 'N;N;N;s,\n, ,g' | \
+ $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \
+ { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \
+ if ($$2 == $$4) files[d] = files[d] " " $$1; \
+ else { print "f", $$3 "/" $$4, $$1; } } \
+ END { for (d in files) print "f", d, files[d] }' | \
+ while read type dir files; do \
+ if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \
+ test -z "$$files" || { \
+ echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(bindir)$$dir'"; \
+ $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \
+ } \
+ ; done
+
+uninstall-binPROGRAMS:
+ @$(NORMAL_UNINSTALL)
+ @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
+ files=`for p in $$list; do echo "$$p"; done | \
+ sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \
+ -e 's/$$/$(EXEEXT)/' `; \
+ test -n "$$list" || exit 0; \
+ echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \
+ cd "$(DESTDIR)$(bindir)" && rm -f $$files
+
+clean-binPROGRAMS:
+ @list='$(bin_PROGRAMS)'; test -n "$$list" || exit 0; \
echo " rm -f" $$list; \
rm -f $$list || exit $$?; \
test -n "$(EXEEXT)" || exit 0; \
@@ -1588,7 +1623,7 @@ check: $(BUILT_SOURCES)
all-am: Makefile $(INFO_DEPS) $(PROGRAMS) $(MANS) config.h
installdirs: installdirs-recursive
installdirs-am:
- for dir in "$(DESTDIR)$(infodir)" "$(DESTDIR)$(man1dir)"; do \
+ for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(infodir)" "$(DESTDIR)$(man1dir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
done
install: $(BUILT_SOURCES)
@@ -1629,8 +1664,8 @@ maintainer-clean-generic:
-test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
clean: clean-recursive
-clean-am: clean-aminfo clean-generic clean-libtool \
- clean-noinstPROGRAMS mostlyclean-am
+clean-am: clean-aminfo clean-binPROGRAMS clean-generic clean-libtool \
+ mostlyclean-am
distclean: distclean-recursive
-rm -f $(am__CONFIG_DISTCLEAN_FILES)
@@ -1668,7 +1703,7 @@ install-dvi-am: $(DVIS)
echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(dvidir)'"; \
$(INSTALL_DATA) $$files "$(DESTDIR)$(dvidir)" || exit $$?; \
done
-install-exec-am: install-exec-local
+install-exec-am: install-binPROGRAMS install-exec-local
install-html: install-html-recursive
@@ -1777,8 +1812,9 @@ ps: ps-recursive
ps-am: $(PSS)
-uninstall-am: uninstall-dvi-am uninstall-html-am uninstall-info-am \
- uninstall-man uninstall-pdf-am uninstall-ps-am
+uninstall-am: uninstall-binPROGRAMS uninstall-dvi-am uninstall-html-am \
+ uninstall-info-am uninstall-man uninstall-pdf-am \
+ uninstall-ps-am
uninstall-man: uninstall-man1
@@ -1788,13 +1824,14 @@ uninstall-man: uninstall-man1
.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
all all-am am--refresh check check-DEJAGNU check-am clean \
- clean-aminfo clean-generic clean-libtool clean-noinstPROGRAMS \
+ clean-aminfo clean-binPROGRAMS clean-generic clean-libtool \
ctags ctags-recursive dist-info distclean distclean-DEJAGNU \
distclean-compile distclean-generic distclean-hdr \
distclean-libtool distclean-local distclean-tags dvi dvi-am \
- html html-am info info-am install install-am install-data \
- install-data-am install-data-local install-dvi install-dvi-am \
- install-exec install-exec-am install-exec-local install-html \
+ html html-am info info-am install install-am \
+ install-binPROGRAMS install-data install-data-am \
+ install-data-local install-dvi install-dvi-am install-exec \
+ install-exec-am install-exec-local install-html \
install-html-am install-info install-info-am install-man \
install-man1 install-pdf install-pdf-am install-ps \
install-ps-am install-strip installcheck installcheck-am \
@@ -1802,9 +1839,9 @@ uninstall-man: uninstall-man1
maintainer-clean-aminfo maintainer-clean-generic mostlyclean \
mostlyclean-aminfo mostlyclean-compile mostlyclean-generic \
mostlyclean-libtool mostlyclean-local pdf pdf-am ps ps-am tags \
- tags-recursive uninstall uninstall-am uninstall-dvi-am \
- uninstall-html-am uninstall-info-am uninstall-man \
- uninstall-man1 uninstall-pdf-am uninstall-ps-am
+ tags-recursive uninstall uninstall-am uninstall-binPROGRAMS \
+ uninstall-dvi-am uninstall-html-am uninstall-info-am \
+ uninstall-man uninstall-man1 uninstall-pdf-am uninstall-ps-am
# Disable -Werror, if it has been enabled, since old versions of bison/
@@ -3223,13 +3260,7 @@ mostlyclean-local:
.PHONY: install-exec-local install-data-local
install-exec-local: ld-new$(EXEEXT)
- $(mkinstalldirs) $(DESTDIR)$(bindir) $(DESTDIR)$(tooldir)/bin
- @list='$(noinst_PROGRAMS)'; for p in $$list; do \
- if test -f $$p; then \
- echo " $(LIBTOOL) --mode=install $(INSTALL_PROGRAM) $$p $(bindir)/`echo $$p|sed -e 's/$(EXEEXT)$$//' -e 's/-new//'|sed '$(transform)'|sed 's/$$/$(EXEEXT)/'`"; \
- $(LIBTOOL) --mode=install $(INSTALL_PROGRAM) $$p $(DESTDIR)$(bindir)/`echo $$p|sed -e 's/$(EXEEXT)$$//' -e 's/-new//'|sed '$(transform)'|sed 's/$$/$(EXEEXT)/'`; \
- else :; fi; \
- done
+ $(mkinstalldirs) $(DESTDIR)$(tooldir)/bin
n=`echo ld | sed '$(transform)'`; \
if [ "$(bindir)/$$n$(EXEEXT)" != "$(tooldir)/bin/ld$(EXEEXT)" ]; then \
rm -f $(DESTDIR)$(tooldir)/bin/ld$(EXEEXT); \