From 37139c92fb6f97d12a5306f75c4fbbd34240c37c Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Sun, 10 Jan 1999 21:32:23 +0000 Subject: [PATCH] * Makefile.am (scriptdir): New macro. (script_DATA): Likewise. (install-data-hook): Use them. (EXTRA_DIST): Added script_DATA. (installcheck-local): Use script_DATA. --- ChangeLog | 6 ++++++ Makefile.am | 16 +++++++++------- Makefile.in | 44 ++++++++++++++++++++++++++++++++++---------- lib/am/Makefile.am | 16 +++++++++------- 4 files changed, 58 insertions(+), 24 deletions(-) diff --git a/ChangeLog b/ChangeLog index d399f95a8..b9ec45dcc 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 1999-01-10 Tom Tromey + * Makefile.am (scriptdir): New macro. + (script_DATA): Likewise. + (install-data-hook): Use them. + (EXTRA_DIST): Added script_DATA. + (installcheck-local): Use script_DATA. + * Makefile.am (pkgdata_DATA): Removed duplicate definition. 1999-01-10 Alexandre Oliva diff --git a/Makefile.am b/Makefile.am index d6a197f63..4523d103b 100644 --- a/Makefile.am +++ b/Makefile.am @@ -18,19 +18,21 @@ ltlib-clean.am ltlib.am ltlibrary.am mans-vars.am mans.am multilib.am \ program.am progs-clean.am progs.am remake-hdr.am remake.am scripts.am \ subdirs.am tags-clean.am tags.am texi-vers.am texinfos.am -pkgdata_DATA = COPYING INSTALL texinfo.tex ansi2knr.c ansi2knr.1 $(amfiles) \ +pkgdata_DATA = COPYING INSTALL texinfo.tex ansi2knr.c ansi2knr.1 $(amfiles) + ## These must all be executable when installed. However, if we use ## _SCRIPTS, then the program transform will be applied, which is not ## what we want. So we make them executable by hand. -config.guess config.sub install-sh mdate-sh missing mkinstalldirs \ -elisp-comp ylwrap acinstall +scriptdir = $(pkgdatadir) +script_DATA = config.guess config.sub install-sh mdate-sh missing \ +mkinstalldirs elisp-comp ylwrap acinstall install-data-hook: - @for prog in $(pkgdata_DATA); do \ - chmod +x $(pkgdatadir)/$$prog; \ + @for prog in $(script_DATA); do \ + chmod +x $(scriptdir)/$$prog; \ done -EXTRA_DIST = acinstall $(pkgdata_DATA) +EXTRA_DIST = acinstall $(pkgdata_DATA) $(script_DATA) # The following requires a fixed version of the Emacs 19.30 etags. ETAGS_ARGS = automake.in aclocal.in --lang=none \ @@ -40,7 +42,7 @@ TAGS_DEPENDENCIES = automake.in aclocal.in automake.texi ## `test -x' is not portable. So we use Perl instead. If Perl ## doesn't exist, then this test is meaningless anyway. installcheck-local: - for file in $(pkgdata_SCRIPTS); do \ + for file in $(script_DATA); do \ $(PERL) -e "exit ! -x '$(pkgdatadir)/$$file';" || exit 1; \ done diff --git a/Makefile.in b/Makefile.in index f28996d31..05ddac102 100644 --- a/Makefile.in +++ b/Makefile.in @@ -74,10 +74,13 @@ info_TEXINFOS = automake.texi amfiles = clean-hdr.am clean-kr.am clean.am comp-vars.am compile.am data-clean.am data.am dejagnu.am depend.am depend2.am dist-vars.am footer.am header-vars.am header.am java-clean.am java.am kr-extra.am library.am libs-clean.am libs.am libtool.am lisp-clean.am lisp.am ltlib-clean.am ltlib.am ltlibrary.am mans-vars.am mans.am multilib.am program.am progs-clean.am progs.am remake-hdr.am remake.am scripts.am subdirs.am tags-clean.am tags.am texi-vers.am texinfos.am -pkgdata_DATA = COPYING INSTALL texinfo.tex ansi2knr.c ansi2knr.1 $(amfiles) config.guess config.sub install-sh mdate-sh missing mkinstalldirs elisp-comp ylwrap acinstall +pkgdata_DATA = COPYING INSTALL texinfo.tex ansi2knr.c ansi2knr.1 $(amfiles) +scriptdir = $(pkgdatadir) +script_DATA = config.guess config.sub install-sh mdate-sh missing mkinstalldirs elisp-comp ylwrap acinstall -EXTRA_DIST = acinstall $(pkgdata_DATA) + +EXTRA_DIST = acinstall $(pkgdata_DATA) $(script_DATA) ETAGS_ARGS = $(amfiles) TAGS_DEPENDENCIES = $(ETAGS_ARGS) @@ -90,7 +93,7 @@ TEXI2DVI = texi2dvi INFO_DEPS = automake.info DVIS = automake.dvi TEXINFOS = automake.texi -DATA = $(pkgdata_DATA) +DATA = $(pkgdata_DATA) $(script_DATA) DIST_COMMON = README AUTHORS COPYING ChangeLog INSTALL Makefile.am \ Makefile.in NEWS THANKS TODO aclocal.in aclocal.m4 ansi2knr.1 \ @@ -304,6 +307,25 @@ uninstall-pkgdataDATA: rm -f $(DESTDIR)$(pkgdatadir)/$$p; \ done +install-scriptDATA: $(script_DATA) + @$(NORMAL_INSTALL) + $(mkinstalldirs) $(DESTDIR)$(scriptdir) + @list='$(script_DATA)'; for p in $$list; do \ + if test -f $(srcdir)/$$p; then \ + echo " $(INSTALL_DATA) $(srcdir)/$$p $(DESTDIR)$(scriptdir)/$$p"; \ + $(INSTALL_DATA) $(srcdir)/$$p $(DESTDIR)$(scriptdir)/$$p; \ + else if test -f $$p; then \ + echo " $(INSTALL_DATA) $$p $(DESTDIR)$(scriptdir)/$$p"; \ + $(INSTALL_DATA) $$p $(DESTDIR)$(scriptdir)/$$p; \ + fi; fi; \ + done + +uninstall-scriptDATA: + @$(NORMAL_UNINSTALL) + list='$(script_DATA)'; for p in $$list; do \ + rm -f $(DESTDIR)$(scriptdir)/$$p; \ + done + # 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, @@ -468,7 +490,7 @@ installcheck: installcheck-recursive install-exec-am: install-binSCRIPTS install-exec: install-exec-recursive -install-data-am: install-info-am install-pkgdataDATA +install-data-am: install-info-am install-pkgdataDATA install-scriptDATA @$(NORMAL_INSTALL) $(MAKE) $(AM_MAKEFLAGS) install-data-hook install-data: install-data-recursive @@ -476,7 +498,8 @@ install-data: install-data-recursive install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am install: install-recursive -uninstall-am: uninstall-binSCRIPTS uninstall-info uninstall-pkgdataDATA +uninstall-am: uninstall-binSCRIPTS uninstall-info uninstall-pkgdataDATA \ + uninstall-scriptDATA uninstall: uninstall-recursive all-am: Makefile $(INFO_DEPS) $(SCRIPTS) $(DATA) all-redirect: all-recursive @@ -485,7 +508,7 @@ install-strip: installdirs: installdirs-recursive installdirs-am: $(mkinstalldirs) $(DESTDIR)$(bindir) $(DESTDIR)$(infodir) \ - $(DESTDIR)$(pkgdatadir) + $(DESTDIR)$(pkgdatadir) $(DESTDIR)$(scriptdir) mostlyclean-generic: @@ -526,7 +549,8 @@ maintainer-clean: maintainer-clean-recursive distclean-vti clean-vti maintainer-clean-vti install-info-am \ uninstall-info mostlyclean-aminfo distclean-aminfo clean-aminfo \ maintainer-clean-aminfo uninstall-pkgdataDATA install-pkgdataDATA \ -install-data-recursive uninstall-data-recursive install-exec-recursive \ +uninstall-scriptDATA install-scriptDATA 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 \ @@ -541,12 +565,12 @@ maintainer-clean install-data-hook: - @for prog in $(pkgdata_DATA); do \ - chmod +x $(pkgdatadir)/$$prog; \ + @for prog in $(script_DATA); do \ + chmod +x $(scriptdir)/$$prog; \ done installcheck-local: - for file in $(pkgdata_SCRIPTS); do \ + for file in $(script_DATA); do \ $(PERL) -e "exit ! -x '$(pkgdatadir)/$$file';" || exit 1; \ done diff --git a/lib/am/Makefile.am b/lib/am/Makefile.am index d6a197f63..4523d103b 100644 --- a/lib/am/Makefile.am +++ b/lib/am/Makefile.am @@ -18,19 +18,21 @@ ltlib-clean.am ltlib.am ltlibrary.am mans-vars.am mans.am multilib.am \ program.am progs-clean.am progs.am remake-hdr.am remake.am scripts.am \ subdirs.am tags-clean.am tags.am texi-vers.am texinfos.am -pkgdata_DATA = COPYING INSTALL texinfo.tex ansi2knr.c ansi2knr.1 $(amfiles) \ +pkgdata_DATA = COPYING INSTALL texinfo.tex ansi2knr.c ansi2knr.1 $(amfiles) + ## These must all be executable when installed. However, if we use ## _SCRIPTS, then the program transform will be applied, which is not ## what we want. So we make them executable by hand. -config.guess config.sub install-sh mdate-sh missing mkinstalldirs \ -elisp-comp ylwrap acinstall +scriptdir = $(pkgdatadir) +script_DATA = config.guess config.sub install-sh mdate-sh missing \ +mkinstalldirs elisp-comp ylwrap acinstall install-data-hook: - @for prog in $(pkgdata_DATA); do \ - chmod +x $(pkgdatadir)/$$prog; \ + @for prog in $(script_DATA); do \ + chmod +x $(scriptdir)/$$prog; \ done -EXTRA_DIST = acinstall $(pkgdata_DATA) +EXTRA_DIST = acinstall $(pkgdata_DATA) $(script_DATA) # The following requires a fixed version of the Emacs 19.30 etags. ETAGS_ARGS = automake.in aclocal.in --lang=none \ @@ -40,7 +42,7 @@ TAGS_DEPENDENCIES = automake.in aclocal.in automake.texi ## `test -x' is not portable. So we use Perl instead. If Perl ## doesn't exist, then this test is meaningless anyway. installcheck-local: - for file in $(pkgdata_SCRIPTS); do \ + for file in $(script_DATA); do \ $(PERL) -e "exit ! -x '$(pkgdatadir)/$$file';" || exit 1; \ done -- 2.47.3