From 1c5f58f99b104c8282f67301c37bae1197600560 Mon Sep 17 00:00:00 2001 From: Akim Demaille Date: Sun, 25 Feb 2001 18:04:29 +0000 Subject: [PATCH] * automake.in (&handle_texinfo, &handle_man_pages, &am_install_var): Don't deal with install-data-am, install-exec-am and unstall-am. (&initialize_per_input): Add them to %dependencies. Remove %exec_dir_p since the *.am files are now in charge of it. Remove @uninstall, @install_data, @install_exec. (&handle_merge_targets): Adjust to these removals. (&file_contents): Also &transform_cond for --no-installman and --no-installinfo. (&do_one_merge_target): Add some magic to install hooks on %dependencies' targets. (%required_targets): New. (&handle_factored_dependencies): Output required targets. * data.am, header.am, java.am, libs.am, lisp.am, ltlib.am, * mans-vars.am, mans.am, progs.am, python.am, scripts.am, * texinfos.am: Declare your dependencies on install-data-am, install-exec-am and uninstall-am. * tests/instdata2.test (incldata_HEADERS): New test. --- ChangeLog | 23 +++++++- Makefile.in | 90 +++++++++++++----------------- automake.in | 130 +++++++++++++++++++++---------------------- data.am | 4 ++ header.am | 4 ++ java.am | 6 +- lib/am/data.am | 4 ++ lib/am/header.am | 4 ++ lib/am/java.am | 6 +- lib/am/libs.am | 3 + lib/am/lisp.am | 3 + lib/am/ltlib.am | 6 +- lib/am/mans-vars.am | 11 +++- lib/am/progs.am | 3 + lib/am/python.am | 2 + lib/am/scripts.am | 3 + lib/am/texinfos.am | 8 ++- libs.am | 3 + lisp.am | 3 + ltlib.am | 6 +- m4/Makefile.in | 37 ++++++------ mans-vars.am | 11 +++- progs.am | 3 + python.am | 2 + scripts.am | 3 + tests/Makefile.am | 3 +- tests/Makefile.in | 34 +++++------ tests/instdata2.test | 21 +++++++ texinfos.am | 8 ++- 29 files changed, 281 insertions(+), 163 deletions(-) create mode 100755 tests/instdata2.test diff --git a/ChangeLog b/ChangeLog index 91db7f88..631c9e6f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,23 @@ +2001-02-25 Akim Demaille + + * automake.in (&handle_texinfo, &handle_man_pages, &am_install_var): + Don't deal with install-data-am, install-exec-am and unstall-am. + (&initialize_per_input): Add them to %dependencies. + Remove %exec_dir_p since the *.am files are now in charge of it. + Remove @uninstall, @install_data, @install_exec. + (&handle_merge_targets): Adjust to these removals. + (&file_contents): Also &transform_cond for --no-installman and + --no-installinfo. + (&do_one_merge_target): Add some magic to install hooks on + %dependencies' targets. + (%required_targets): New. + (&handle_factored_dependencies): Output required targets. + * data.am, header.am, java.am, libs.am, lisp.am, ltlib.am, + * mans-vars.am, mans.am, progs.am, python.am, scripts.am, + * texinfos.am: Declare your dependencies on install-data-am, + install-exec-am and uninstall-am. + * tests/instdata2.test (incldata_HEADERS): New test. + 2001-02-24 Tom Tromey * Makefile.am (amfiles): Added texibuild.am. @@ -23,12 +43,10 @@ * automake.in: Formatting and mying changes. - 2001-02-23 Akim Demaille * automake.in: Formatting and mying changes. - 2001-02-23 Akim Demaille * automake.in (&handle_man_pages): Let install-man and @@ -472,7 +490,6 @@ about libtool, and maintainer-clean. * clean.am, libtool.am: Handle these. - 2001-02-05 Akim Demaille * automake.in (handle_texinfo): No longer hard code the clean diff --git a/Makefile.in b/Makefile.in index 2527c922..0f665e1c 100644 --- a/Makefile.in +++ b/Makefile.in @@ -130,12 +130,12 @@ DVIS = automake.dvi TEXINFOS = automake.texi DATA = $(dist_pkgdata_DATA) $(dist_script_DATA) -DIST_COMMON = README $(dist_pkgdata_DATA) $(dist_script_DATA) AUTHORS \ -COPYING ChangeLog INSTALL Makefile.am Makefile.in NEWS README-alpha \ -THANKS TODO aclocal.in aclocal.m4 ansi2knr.1 ansi2knr.c automake.in \ -compile config.guess config.sub configure configure.in depcomp \ -elisp-comp install-sh mdate-sh missing mkinstalldirs py-compile \ -stamp-vti texinfo.tex version.texi ylwrap +DIST_COMMON = mkinstalldirs automake.in install-sh version.texi \ +aclocal.m4 README-alpha ansi2knr.c Makefile.am mdate-sh NEWS COPYING \ +stamp-vti ansi2knr.1 AUTHORS compile Makefile.in configure.in README \ +depcomp THANKS configure ylwrap elisp-comp py-compile ChangeLog missing \ +config.sub texinfo.tex INSTALL $(dist_script_DATA) aclocal.in \ +config.guess TODO $(dist_pkgdata_DATA) DIST_SUBDIRS = $(SUBDIRS) all: all-recursive @@ -206,19 +206,6 @@ maintainer-clean-vti: automake.info: automake.texi $(srcdir)/version.texi automake.dvi: automake.texi $(srcdir)/version.texi -.texi.info: - @cd $(srcdir) && rm -f $@ $@-[0-9] $@-[0-9][0-9] - cd $(srcdir) \ - && $(MAKEINFO) `echo $< | sed 's,.*/,,'` - -.texi.dvi: - TEXINPUTS=$(srcdir):$$TEXINPUTS \ - MAKEINFO='$(MAKEINFO) -I $(srcdir)' $(TEXI2DVI) $< - -.texi: - @cd $(srcdir) && rm -f $@ $@-[0-9] $@-[0-9][0-9] - cd $(srcdir) \ - && $(MAKEINFO) `echo $< | sed 's,.*/,,'` DVIPS = dvips .dvi.ps: @@ -505,20 +492,11 @@ check-am: all-am check: check-recursive installcheck-am: installcheck-local installcheck: installcheck-recursive -install-exec-am: install-binSCRIPTS install-exec: install-exec-recursive - -install-data-am: install-info-am install-dist_pkgdataDATA \ - install-dist_scriptDATA - @$(NORMAL_INSTALL) - $(MAKE) $(AM_MAKEFLAGS) install-data-hook 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-dist_pkgdataDATA uninstall-dist_scriptDATA uninstall: uninstall-recursive all-am: Makefile $(INFO_DEPS) $(SCRIPTS) $(DATA) install-strip: @@ -543,33 +521,18 @@ maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." -rm -f Makefile.in -clean: clean-recursive - -clean-am: clean-generic mostlyclean-am - -dist-all: dist - -distclean: distclean-recursive - -rm -f config.status - -distclean-am: clean-am distclean-generic distclean-tags - -maintainer-clean: maintainer-clean-recursive - -rm -f config.status - maintainer-clean-am: distclean-am maintainer-clean-aminfo \ maintainer-clean-generic maintainer-clean-vti -mostlyclean: mostlyclean-recursive - -mostlyclean-am: mostlyclean-aminfo mostlyclean-generic mostlyclean-vti +uninstall-am: uninstall-binSCRIPTS uninstall-dist_pkgdataDATA \ + uninstall-dist_scriptDATA uninstall-info .PHONY: all all-am all-recursive check check-am check-recursive clean \ - clean-generic clean-recursive dist dist-all distcheck distclean \ - distclean-generic distclean-recursive distclean-tags distdir \ - dvi dvi-am dvi-recursive info info-am info-recursive install \ - install-am install-binSCRIPTS install-data install-data-am \ - install-data-recursive install-dist_pkgdataDATA \ + clean-generic clean-recursive dist dist-all dist-info distcheck \ + distclean distclean-generic distclean-recursive distclean-tags \ + distdir dvi dvi-am dvi-recursive info info-am info-recursive \ + install install-am install-binSCRIPTS install-data \ + install-data-am install-data-recursive install-dist_pkgdataDATA \ install-dist_scriptDATA install-exec install-exec-am \ install-exec-recursive install-info-am install-recursive \ install-strip installcheck installcheck-am installcheck-local \ @@ -582,6 +545,33 @@ mostlyclean-am: mostlyclean-aminfo mostlyclean-generic mostlyclean-vti uninstall-dist_pkgdataDATA uninstall-dist_scriptDATA \ uninstall-info uninstall-recursive +install-man: + +distclean: distclean-recursive + -rm -f config.status + +clean-am: clean-generic mostlyclean-am + +install-exec-am: install-binSCRIPTS + +install-data-am: install-dist_pkgdataDATA install-dist_scriptDATA \ + install-info-am + @$(NORMAL_INSTALL) + $(MAKE) $(AM_MAKEFLAGS) install-data-hook + +distclean-am: clean-am distclean-generic distclean-tags + +dist-all: dist + +maintainer-clean: maintainer-clean-recursive + -rm -f config.status + +mostlyclean-am: mostlyclean-aminfo mostlyclean-generic mostlyclean-vti + +mostlyclean: mostlyclean-recursive + +clean: clean-recursive + install-data-hook: @$(POST_INSTALL) diff --git a/automake.in b/automake.in index 44889c15..d3dc7ef9 100755 --- a/automake.in +++ b/automake.in @@ -120,6 +120,22 @@ $copy_missing = 0; # TRUE if we should always update files that we know about. $force_missing = 0; +# List of targets we must always output. +# FIXME: Complete, and remove falsely required targets. +my %required_targets = + ( + 'all' => 1, + 'install' => 1, + 'install-data' => 1, + 'install-exec' => 1, + + # FIXME: Not required, temporary hack until install-data and install-exec + # are factored. + 'install-data-am' => 1, + 'install-exec-am' => 1, + + 'install-man' => 1, + ); # Variables filled during files scanning. @@ -2457,10 +2473,7 @@ sub handle_texinfo if (! defined $options{'no-installinfo'}) { - push (@uninstall, 'uninstall-info'); push (@installdirs, '$(DESTDIR)$(infodir)'); - unshift (@install_data, 'install-info-am'); - # Make sure documentation is made and installed first. Use # $(INFO_DEPS), not 'info', because otherwise recursive makes # get run twice during "make all". @@ -2541,7 +2554,6 @@ sub handle_man_pages $output_rules .= &file_contents ('mans', &transform ('SECTION', $sect)); } - &depend ('.PHONY', 'install-man', 'uninstall-man'); # We don't really need this, but we use it in case we ever want to # support noinst_MANS. @@ -2551,8 +2563,6 @@ sub handle_man_pages if (! defined $options{'no-installman'}) { - push (@install_data, 'install-man'); - push (@uninstall, 'uninstall-man'); push (@all, '$(MANS)'); } } @@ -3697,14 +3707,11 @@ sub handle_merge_targets $output_rules .= "install-binPROGRAMS: install-libLTLIBRARIES\n\n"; } # Print definitions users can use. - &do_one_merge_target ('install-exec', @install_exec); - $output_rules .= "\n"; - - &do_one_merge_target ('install-data', @install_data); - $output_rules .= "\n"; + &do_one_merge_target ('install-exec'); + &do_one_merge_target ('install-data'); &do_one_merge_target ('install', 'all-am'); - &do_one_merge_target ('uninstall', @uninstall); + &do_one_merge_target ('uninstall'); &do_one_merge_target ('all', @all); @@ -3731,16 +3738,29 @@ sub handle_merge_targets # relies on the fact that this doesn't add an extra \n at the end. sub do_one_merge_target { - local ($name, @values) = @_; + my ($name, @values) = @_; - if (&target_defined ($name . '-local')) + # Install hooks. + if (&target_defined ("$name-local")) { # User defined local form of target. So include it. - push (@values, $name . '-local'); - &depend ('.PHONY', $name . '-local'); + if (defined $dependencies{"$name-am"}) + { + depend ("$name-am", "$name-local"); + } + else + { + push (@values, "$name-local"); + } + &depend ('.PHONY', "$name-local"); } - &pretty_print_rule ($name . "-am:", "\t\t", @values); + # FIXME: Gross, should disapear once all these targets properly + # registered in %dependencies. + if (!defined $dependencies {"$name-am"}) + { + &pretty_print_rule ("$name-am:", "\t\t", @values); + } if ($name eq 'install') { # Special-case `install-am' to run install-exec-am and @@ -3750,15 +3770,17 @@ sub do_one_merge_target } elsif ($name eq 'install-exec' && &target_defined ('install-exec-hook')) { - $output_rules .= ("\t\@\$(NORMAL_INSTALL)\n" - . "\t" . '$(MAKE) $(AM_MAKEFLAGS) install-exec-hook' - . "\n"); + $actions{'install-exec-am'} .= + ("\t\@\$(NORMAL_INSTALL)\n" + . "\t" . '$(MAKE) $(AM_MAKEFLAGS) install-exec-hook' + . "\n"); } elsif ($name eq 'install-data' && &target_defined ('install-data-hook')) { - $output_rules .= ("\t\@\$(NORMAL_INSTALL)\n" - . "\t" . '$(MAKE) $(AM_MAKEFLAGS) install-data-hook' - . "\n"); + $actions{'install-data-am'} .= + ("\t\@\$(NORMAL_INSTALL)\n" + . "\t" . '$(MAKE) $(AM_MAKEFLAGS) install-data-hook' + . "\n"); } # To understand this special case, see handle_merge_targets. @@ -3910,7 +3932,9 @@ sub handle_factored_dependencies { # If there is nothing about this guy, skip it. next - unless @{$dependencies{$_}} || $actions{$_}; + unless (@{$dependencies{$_}} + || $actions{$_} + || $required_targets{$_}); &pretty_print_rule ("$_:", "\t", sort @{$dependencies{$_}}); $output_rules .= $actions{$_}; @@ -6415,26 +6439,6 @@ sub initialize_global_constants $AC_CANONICAL_HOST = 1; $AC_CANONICAL_SYSTEM = 2; - # Associative array of standard directory names. Entry is TRUE if - # corresponding directory should be installed during - # 'install-exec' phase. - %exec_dir_p = - ('bin', 1, - 'sbin', 1, - 'libexec', 1, - 'data', 0, - 'sysconf', 1, - 'localstate', 1, - 'lib', 1, - 'info', 0, - 'man', 0, - 'include', 0, - 'oldinclude', 0, - 'pkgdata', 0, - 'pkglib', 1, - 'pkginclude', 0 - ); - # Commonly found files we look for and automatically include in # DISTFILES. @common_files = @@ -6540,9 +6544,6 @@ sub initialize_per_input %dist_dirs = (); # List of dependencies for the obvious targets. - @install_data = (); - @install_exec = (); - @uninstall = (); @installdirs = (); @info = (); @@ -6560,8 +6561,11 @@ sub initialize_per_input %dependencies = ( # Installing/uninstalling. + 'install-data-am' => [], + 'install-exec-am' => [], 'install-man' => [], 'uninstall-man' => [], + 'uninstall-am' => [], # Cleaning. 'clean-am' => [], @@ -6710,12 +6714,17 @@ sub file_contents # Sanity check over COMMAND, and complete it with global options. &prog_error ("file_contents: $command") if $command ne '' && substr ($command, -1) ne ';'; - $command .= &transform_cond ('CYGNUS' => $cygnus_mode, - 'SHAR' => $options{'dist-shar'}, - 'BZIP2' => $options{'dist-bzip2'}, - 'ZIP' => $options{'dist-zip'}, - 'COMPRESS' => $options{'dist-tarZ'}, - 'CK-NEWS' => $options{'check-news'}); + $command .= + &transform_cond ('CYGNUS' => $cygnus_mode, + + 'SHAR' => $options{'dist-shar'}, + 'BZIP2' => $options{'dist-bzip2'}, + 'ZIP' => $options{'dist-zip'}, + 'COMPRESS' => $options{'dist-tarZ'}, + + 'INSTALL-INFO' => !$options{'no-installinfo'}, + 'INSTALL-MAN' => !$options{'no-installman'}, + 'CK-NEWS' => $options{'check-news'}); # Swallow the file and applied the COMMAND. my $file = $am_dir . '/' . $basename . '.am'; @@ -7211,23 +7220,12 @@ sub am_install_var &file_contents ($file, &transform ('DIR' => $X, 'NDIR' => $nodir_name) - . &transform_cond ('BASE' => $strip_subdir) + . &transform_cond ('BASE' => $strip_subdir, + 'EXEC' => $X =~ /exec/) . $ltxform . $cygxform); - push (@uninstall, 'uninstall-' . $X . $primary); - &depend ('.PHONY', 'uninstall-' . $X . $primary); push (@installdirs, '$(DESTDIR)$(' . $X . 'dir)'); - if (defined $exec_dir_p{$X} ? $exec_dir_p{$X} : ($X =~ /exec/)) - { - push (@install_exec, 'install-' . $X . $primary); - &depend ('.PHONY', 'install-' . $X . $primary); - } - else - { - push (@install_data, 'install-' . $X . $primary); - &depend ('.PHONY', 'install-' . $X . $primary); - } } } diff --git a/data.am b/data.am index 3cb22424..e7bcba64 100644 --- a/data.am +++ b/data.am @@ -15,6 +15,9 @@ ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. + +?EXEC?.PHONY install-exec-am: install-@DIR@DATA +?!EXEC?.PHONY install-data-am: install-@DIR@DATA install-@DIR@DATA: $(@DIR@_DATA) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(@NDIR@dir) @@ -31,6 +34,7 @@ install-@DIR@DATA: $(@DIR@_DATA) $(INSTALL_DATA) $$d$$p $(DESTDIR)$(@NDIR@dir)/$$f; \ done +.PHONY uninstall-am: uninstall-@DIR@DATA uninstall-@DIR@DATA: @$(NORMAL_UNINSTALL) @list='$(@DIR@_DATA)'; for p in $$list; do \ diff --git a/header.am b/header.am index ce60a44e..d8ddf1d8 100644 --- a/header.am +++ b/header.am @@ -15,6 +15,9 @@ ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. + +?EXEC?.PHONY install-exec-am: install-@DIR@HEADERS +?!EXEC?.PHONY install-data-am: install-@DIR@HEADERS install-@DIR@HEADERS: $(@DIR@_HEADERS) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(@NDIR@dir) @@ -29,6 +32,7 @@ install-@DIR@HEADERS: $(@DIR@_HEADERS) $(INSTALL_HEADER) $$d$$p $(DESTDIR)$(@NDIR@dir)/$$f; \ done +.PHONY uninstall-am: uninstall-@DIR@HEADERS uninstall-@DIR@HEADERS: @$(NORMAL_UNINSTALL) @list='$(@DIR@_HEADERS)'; for p in $$list; do \ diff --git a/java.am b/java.am index 64f2f6a6..b33f1c8f 100644 --- a/java.am +++ b/java.am @@ -1,5 +1,5 @@ ## automake - create Makefile.in from Makefile.am -## Copyright 1998, 1999 Free Software Foundation, Inc. +## Copyright 1998, 1999, 2001 Free Software Foundation, Inc. ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -15,6 +15,9 @@ ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. + +?EXEC?.PHONY install-exec-am: install-@DIR@JAVA +?!EXEC?.PHONY install-data-am: install-@DIR@JAVA install-@DIR@JAVA: class@DIR@.stamp @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(@NDIR@dir) @@ -26,6 +29,7 @@ install-@DIR@JAVA: class@DIR@.stamp $(INSTALL_DATA) $$p $(DESTDIR)$(@NDIR@dir)/$$p; \ done +.PHONY uninstall-am: uninstall-@DIR@JAVA uninstall-@DIR@JAVA: @$(NORMAL_UNINSTALL) @for p in *.class; do \ diff --git a/lib/am/data.am b/lib/am/data.am index 3cb22424..e7bcba64 100644 --- a/lib/am/data.am +++ b/lib/am/data.am @@ -15,6 +15,9 @@ ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. + +?EXEC?.PHONY install-exec-am: install-@DIR@DATA +?!EXEC?.PHONY install-data-am: install-@DIR@DATA install-@DIR@DATA: $(@DIR@_DATA) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(@NDIR@dir) @@ -31,6 +34,7 @@ install-@DIR@DATA: $(@DIR@_DATA) $(INSTALL_DATA) $$d$$p $(DESTDIR)$(@NDIR@dir)/$$f; \ done +.PHONY uninstall-am: uninstall-@DIR@DATA uninstall-@DIR@DATA: @$(NORMAL_UNINSTALL) @list='$(@DIR@_DATA)'; for p in $$list; do \ diff --git a/lib/am/header.am b/lib/am/header.am index ce60a44e..d8ddf1d8 100644 --- a/lib/am/header.am +++ b/lib/am/header.am @@ -15,6 +15,9 @@ ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. + +?EXEC?.PHONY install-exec-am: install-@DIR@HEADERS +?!EXEC?.PHONY install-data-am: install-@DIR@HEADERS install-@DIR@HEADERS: $(@DIR@_HEADERS) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(@NDIR@dir) @@ -29,6 +32,7 @@ install-@DIR@HEADERS: $(@DIR@_HEADERS) $(INSTALL_HEADER) $$d$$p $(DESTDIR)$(@NDIR@dir)/$$f; \ done +.PHONY uninstall-am: uninstall-@DIR@HEADERS uninstall-@DIR@HEADERS: @$(NORMAL_UNINSTALL) @list='$(@DIR@_HEADERS)'; for p in $$list; do \ diff --git a/lib/am/java.am b/lib/am/java.am index 64f2f6a6..b33f1c8f 100644 --- a/lib/am/java.am +++ b/lib/am/java.am @@ -1,5 +1,5 @@ ## automake - create Makefile.in from Makefile.am -## Copyright 1998, 1999 Free Software Foundation, Inc. +## Copyright 1998, 1999, 2001 Free Software Foundation, Inc. ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -15,6 +15,9 @@ ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. + +?EXEC?.PHONY install-exec-am: install-@DIR@JAVA +?!EXEC?.PHONY install-data-am: install-@DIR@JAVA install-@DIR@JAVA: class@DIR@.stamp @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(@NDIR@dir) @@ -26,6 +29,7 @@ install-@DIR@JAVA: class@DIR@.stamp $(INSTALL_DATA) $$p $(DESTDIR)$(@NDIR@dir)/$$p; \ done +.PHONY uninstall-am: uninstall-@DIR@JAVA uninstall-@DIR@JAVA: @$(NORMAL_UNINSTALL) @for p in *.class; do \ diff --git a/lib/am/libs.am b/lib/am/libs.am index 46574b07..b5b935fe 100644 --- a/lib/am/libs.am +++ b/lib/am/libs.am @@ -15,6 +15,8 @@ ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. + +.PHONY install-exec-am: install-@DIR@LIBRARIES install-@DIR@LIBRARIES: $(@DIR@_LIBRARIES) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(@NDIR@dir) @@ -40,6 +42,7 @@ install-@DIR@LIBRARIES: $(@DIR@_LIBRARIES) else :; fi; \ done +.PHONY uninstall-am: uninstall-@DIR@LIBRARIES uninstall-@DIR@LIBRARIES: @$(NORMAL_UNINSTALL) @list='$(@DIR@_LIBRARIES)'; for p in $$list; do \ diff --git a/lib/am/lisp.am b/lib/am/lisp.am index 50528784..0c020a03 100644 --- a/lib/am/lisp.am +++ b/lib/am/lisp.am @@ -16,6 +16,8 @@ ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. +?EXEC?.PHONY install-exec-am: install-@DIR@LISP +?!EXEC?.PHONY install-data-am: install-@DIR@LISP install-@DIR@LISP: $(@DIR@_LISP) $(ELCFILES) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(@NDIR@dir) @@ -35,6 +37,7 @@ install-@DIR@LISP: $(@DIR@_LISP) $(ELCFILES) else : ; fi; \ done +.PHONY uninstall-am: uninstall-@DIR@LISP uninstall-@DIR@LISP: @$(NORMAL_UNINSTALL) @list='$(@DIR@_LISP)'; for p in $$list; do \ diff --git a/lib/am/ltlib.am b/lib/am/ltlib.am index 8577b9da..cb10a2bc 100644 --- a/lib/am/ltlib.am +++ b/lib/am/ltlib.am @@ -1,5 +1,6 @@ ## automake - create Makefile.in from Makefile.am -## Copyright 1994, 1995, 1996, 1997, 1998, 1999 Free Software Foundation, Inc. +## Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2001 +## Free Software Foundation, Inc. ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -15,6 +16,8 @@ ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. + +.PHONY install-exec-am: install-@DIR@LTLIBRARIES install-@DIR@LTLIBRARIES: $(@DIR@_LTLIBRARIES) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(@NDIR@dir) @@ -31,6 +34,7 @@ install-@DIR@LTLIBRARIES: $(@DIR@_LTLIBRARIES) else :; fi; \ done +.PHONY uninstall-am: uninstall-@DIR@LTLIBRARIES uninstall-@DIR@LTLIBRARIES: @$(NORMAL_UNINSTALL) @list='$(@DIR@_LTLIBRARIES)'; for p in $$list; do \ diff --git a/lib/am/mans-vars.am b/lib/am/mans-vars.am index 347d632b..490e663b 100644 --- a/lib/am/mans-vars.am +++ b/lib/am/mans-vars.am @@ -1,5 +1,5 @@ ## automake - create Makefile.in from Makefile.am -## Copyright 1994, 1995, 1996 Free Software Foundation, Inc. +## Copyright 1994, 1995, 1996, 2001 Free Software Foundation, Inc. ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -15,4 +15,13 @@ ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. + NROFF = nroff + +## FIXME: This is not elegant: there is more than simply variables, +## but we take advantage of the facts that these are factored dependencies, +## and therefore will be output here, in the variable section. + +.PHONY: install-man uninstall-man +?INSTALL-MAN?install-data-am: install-man +?INSTALL-MAN?uninstall-am: uninstall-man diff --git a/lib/am/progs.am b/lib/am/progs.am index 6ea88982..231a4da0 100644 --- a/lib/am/progs.am +++ b/lib/am/progs.am @@ -15,6 +15,8 @@ ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. + +.PHONY install-exec-am: install-@DIR@PROGRAMS install-@DIR@PROGRAMS: $(@DIR@_PROGRAMS) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(@NDIR@dir) @@ -31,6 +33,7 @@ install-@DIR@PROGRAMS: $(@DIR@_PROGRAMS) else :; fi; \ done +.PHONY uninstall-am: uninstall-@DIR@PROGRAMS uninstall-@DIR@PROGRAMS: @$(NORMAL_UNINSTALL) @list='$(@DIR@_PROGRAMS)'; for p in $$list; do \ diff --git a/lib/am/python.am b/lib/am/python.am index 5f1694c7..089282f7 100644 --- a/lib/am/python.am +++ b/lib/am/python.am @@ -16,6 +16,7 @@ ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. +.PHONY install-exec-am: install-@DIR@PYTHON install-@DIR@PYTHON: $(@DIR@_PYTHON) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(@DIR@dir) @@ -30,6 +31,7 @@ install-@DIR@PYTHON: $(@DIR@_PYTHON) ## encoded in the actual files. @PYTHON=$(PYTHON) $(py_compile) --basedir $(DESTDIR)$(@DIR@dir) $(@DIR@_PYTHON) +.PHONY uninstall-am: uninstall-@DIR@PYTHON uninstall-@DIR@PYTHON: @$(NORMAL_UNINSTALL) list='$(@DIR@_PYTHON)'; for p in $$list; do \ diff --git a/lib/am/scripts.am b/lib/am/scripts.am index 34e98a22..e559ada8 100644 --- a/lib/am/scripts.am +++ b/lib/am/scripts.am @@ -15,6 +15,8 @@ ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. + +.PHONY install-exec-am: install-@DIR@SCRIPTS install-@DIR@SCRIPTS: $(@DIR@_SCRIPTS) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(@NDIR@dir) @@ -31,6 +33,7 @@ install-@DIR@SCRIPTS: $(@DIR@_SCRIPTS) else :; fi; \ done +.PHONY uninstall-am: uninstall-@DIR@SCRIPTS uninstall-@DIR@SCRIPTS: @$(NORMAL_UNINSTALL) @list='$(@DIR@_SCRIPTS)'; for p in $$list; do \ diff --git a/lib/am/texinfos.am b/lib/am/texinfos.am index b5236427..280d9bdf 100644 --- a/lib/am/texinfos.am +++ b/lib/am/texinfos.am @@ -27,6 +27,9 @@ DVIPS = dvips ## break a possible install-sh reference. ## Funny name due to --cygnus influence; we want to reserve ## `install-info' for the user. +.PHONY: install-info-am +?EXEC??INSTALL-INFO?insexec-data-am: install-info-am +?!EXEC??INSTALL-INFO?install-data-am: install-info-am install-info-am: $(INFO_DEPS) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(infodir) @@ -62,6 +65,8 @@ install-info-am: $(INFO_DEPS) done; \ else : ; fi +.PHONY: uninstall-info +?INSTALL-INFO?uninstall-am: uninstall-info uninstall-info: $(PRE_UNINSTALL) ## Run two loops here so that we can handle PRE_UNINSTALL and @@ -84,6 +89,7 @@ uninstall-info: else :; fi); \ done +.PHONY: dist-info dist-info: $(INFO_DEPS) list='$(INFO_DEPS)'; \ for base in $$list; do \ @@ -97,8 +103,6 @@ dist-info: $(INFO_DEPS) done; \ done -.PHONY: install-info-am uninstall-info - ## How to clean. The funny name is due to --cygnus influence; in ## Cygnus mode, `clean-info' is a target that users can use. diff --git a/libs.am b/libs.am index 46574b07..b5b935fe 100644 --- a/libs.am +++ b/libs.am @@ -15,6 +15,8 @@ ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. + +.PHONY install-exec-am: install-@DIR@LIBRARIES install-@DIR@LIBRARIES: $(@DIR@_LIBRARIES) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(@NDIR@dir) @@ -40,6 +42,7 @@ install-@DIR@LIBRARIES: $(@DIR@_LIBRARIES) else :; fi; \ done +.PHONY uninstall-am: uninstall-@DIR@LIBRARIES uninstall-@DIR@LIBRARIES: @$(NORMAL_UNINSTALL) @list='$(@DIR@_LIBRARIES)'; for p in $$list; do \ diff --git a/lisp.am b/lisp.am index 50528784..0c020a03 100644 --- a/lisp.am +++ b/lisp.am @@ -16,6 +16,8 @@ ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. +?EXEC?.PHONY install-exec-am: install-@DIR@LISP +?!EXEC?.PHONY install-data-am: install-@DIR@LISP install-@DIR@LISP: $(@DIR@_LISP) $(ELCFILES) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(@NDIR@dir) @@ -35,6 +37,7 @@ install-@DIR@LISP: $(@DIR@_LISP) $(ELCFILES) else : ; fi; \ done +.PHONY uninstall-am: uninstall-@DIR@LISP uninstall-@DIR@LISP: @$(NORMAL_UNINSTALL) @list='$(@DIR@_LISP)'; for p in $$list; do \ diff --git a/ltlib.am b/ltlib.am index 8577b9da..cb10a2bc 100644 --- a/ltlib.am +++ b/ltlib.am @@ -1,5 +1,6 @@ ## automake - create Makefile.in from Makefile.am -## Copyright 1994, 1995, 1996, 1997, 1998, 1999 Free Software Foundation, Inc. +## Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2001 +## Free Software Foundation, Inc. ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -15,6 +16,8 @@ ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. + +.PHONY install-exec-am: install-@DIR@LTLIBRARIES install-@DIR@LTLIBRARIES: $(@DIR@_LTLIBRARIES) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(@NDIR@dir) @@ -31,6 +34,7 @@ install-@DIR@LTLIBRARIES: $(@DIR@_LTLIBRARIES) else :; fi; \ done +.PHONY uninstall-am: uninstall-@DIR@LTLIBRARIES uninstall-@DIR@LTLIBRARIES: @$(NORMAL_UNINSTALL) @list='$(@DIR@_LTLIBRARIES)'; for p in $$list; do \ diff --git a/m4/Makefile.in b/m4/Makefile.in index d118e9e3..d58b2e24 100644 --- a/m4/Makefile.in +++ b/m4/Makefile.in @@ -153,16 +153,11 @@ check-am: all-am check: check-am installcheck-am: installcheck: installcheck-am -install-exec-am: install-exec: install-exec-am - -install-data-am: install-m4dataDATA install-data: install-data-am - install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am install: install-am -uninstall-am: uninstall-m4dataDATA uninstall: uninstall-am all-am: Makefile $(DATA) install-strip: @@ -184,29 +179,37 @@ maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." -rm -f Makefile.in -clean: clean-am +maintainer-clean-am: distclean-am maintainer-clean-generic -clean-am: clean-generic mostlyclean-am +uninstall-am: uninstall-m4dataDATA + +.PHONY: all all-am check check-am clean clean-generic distclean \ + distclean-generic distdir dvi dvi-am info info-am install \ + install-am install-data install-data-am install-exec \ + install-exec-am install-m4dataDATA install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-generic \ + uninstall uninstall-am uninstall-m4dataDATA + +install-man: distclean: distclean-am +clean-am: clean-generic mostlyclean-am + +install-exec-am: + +install-data-am: install-m4dataDATA + distclean-am: clean-am distclean-generic maintainer-clean: maintainer-clean-am -maintainer-clean-am: distclean-am maintainer-clean-generic +mostlyclean-am: mostlyclean-generic mostlyclean: mostlyclean-am -mostlyclean-am: mostlyclean-generic - -.PHONY: all all-am check check-am clean clean-generic distclean \ - distclean-generic distdir dvi dvi-am info info-am install \ - install-am install-data install-data-am install-exec \ - install-exec-am install-m4dataDATA install-strip installcheck \ - installcheck-am installdirs maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-generic \ - uninstall uninstall-am uninstall-m4dataDATA +clean: clean-am # Tell versions [3.59,3.63) of GNU make to not export all variables. diff --git a/mans-vars.am b/mans-vars.am index 347d632b..490e663b 100644 --- a/mans-vars.am +++ b/mans-vars.am @@ -1,5 +1,5 @@ ## automake - create Makefile.in from Makefile.am -## Copyright 1994, 1995, 1996 Free Software Foundation, Inc. +## Copyright 1994, 1995, 1996, 2001 Free Software Foundation, Inc. ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -15,4 +15,13 @@ ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. + NROFF = nroff + +## FIXME: This is not elegant: there is more than simply variables, +## but we take advantage of the facts that these are factored dependencies, +## and therefore will be output here, in the variable section. + +.PHONY: install-man uninstall-man +?INSTALL-MAN?install-data-am: install-man +?INSTALL-MAN?uninstall-am: uninstall-man diff --git a/progs.am b/progs.am index 6ea88982..231a4da0 100644 --- a/progs.am +++ b/progs.am @@ -15,6 +15,8 @@ ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. + +.PHONY install-exec-am: install-@DIR@PROGRAMS install-@DIR@PROGRAMS: $(@DIR@_PROGRAMS) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(@NDIR@dir) @@ -31,6 +33,7 @@ install-@DIR@PROGRAMS: $(@DIR@_PROGRAMS) else :; fi; \ done +.PHONY uninstall-am: uninstall-@DIR@PROGRAMS uninstall-@DIR@PROGRAMS: @$(NORMAL_UNINSTALL) @list='$(@DIR@_PROGRAMS)'; for p in $$list; do \ diff --git a/python.am b/python.am index 5f1694c7..089282f7 100644 --- a/python.am +++ b/python.am @@ -16,6 +16,7 @@ ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. +.PHONY install-exec-am: install-@DIR@PYTHON install-@DIR@PYTHON: $(@DIR@_PYTHON) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(@DIR@dir) @@ -30,6 +31,7 @@ install-@DIR@PYTHON: $(@DIR@_PYTHON) ## encoded in the actual files. @PYTHON=$(PYTHON) $(py_compile) --basedir $(DESTDIR)$(@DIR@dir) $(@DIR@_PYTHON) +.PHONY uninstall-am: uninstall-@DIR@PYTHON uninstall-@DIR@PYTHON: @$(NORMAL_UNINSTALL) list='$(@DIR@_PYTHON)'; for p in $$list; do \ diff --git a/scripts.am b/scripts.am index 34e98a22..e559ada8 100644 --- a/scripts.am +++ b/scripts.am @@ -15,6 +15,8 @@ ## along with this program; if not, write to the Free Software ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. + +.PHONY install-exec-am: install-@DIR@SCRIPTS install-@DIR@SCRIPTS: $(@DIR@_SCRIPTS) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(@NDIR@dir) @@ -31,6 +33,7 @@ install-@DIR@SCRIPTS: $(@DIR@_SCRIPTS) else :; fi; \ done +.PHONY uninstall-am: uninstall-@DIR@SCRIPTS uninstall-@DIR@SCRIPTS: @$(NORMAL_UNINSTALL) @list='$(@DIR@_SCRIPTS)'; for p in $$list; do \ diff --git a/tests/Makefile.am b/tests/Makefile.am index ed84158a..b688a6f7 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -2,7 +2,7 @@ AUTOMAKE_OPTIONS = gnits -XFAIL_TESTS = +XFAIL_TESTS = TESTS = \ acinclude.test \ aclocal.test \ @@ -129,6 +129,7 @@ install.test \ install2.test \ installsh.test \ instdata.test \ +instdata2.test \ instexec.test \ insthook.test \ instman.test \ diff --git a/tests/Makefile.in b/tests/Makefile.in index c9327577..8606cf0f 100644 --- a/tests/Makefile.in +++ b/tests/Makefile.in @@ -206,6 +206,7 @@ install.test \ install2.test \ installsh.test \ instdata.test \ +instdata2.test \ instexec.test \ insthook.test \ instman.test \ @@ -453,16 +454,11 @@ check-am: all-am check: check-am installcheck-am: installcheck: installcheck-am -install-exec-am: install-exec: install-exec-am - -install-data-am: install-data: install-data-am - install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am install: install-am -uninstall-am: uninstall: uninstall-am all-am: Makefile install-strip: @@ -483,28 +479,34 @@ maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." -rm -f Makefile.in -clean: clean-am +maintainer-clean-am: distclean-am maintainer-clean-generic -clean-am: clean-generic mostlyclean-am +.PHONY: all all-am check check-TESTS check-am clean clean-generic \ + distclean distclean-generic distdir dvi dvi-am info info-am \ + install install-am install-data install-data-am install-exec \ + install-exec-am install-strip installcheck installcheck-am \ + installdirs maintainer-clean maintainer-clean-generic \ + mostlyclean mostlyclean-generic uninstall uninstall-am + +install-man: distclean: distclean-am +clean-am: clean-generic mostlyclean-am + +install-exec-am: + +install-data-am: + distclean-am: clean-am distclean-generic distclean-local maintainer-clean: maintainer-clean-am -maintainer-clean-am: distclean-am maintainer-clean-generic +mostlyclean-am: mostlyclean-generic mostlyclean: mostlyclean-am -mostlyclean-am: mostlyclean-generic - -.PHONY: all all-am check check-TESTS check-am clean clean-generic \ - distclean distclean-generic distdir dvi dvi-am info info-am \ - install install-am install-data install-data-am install-exec \ - install-exec-am install-strip installcheck installcheck-am \ - installdirs maintainer-clean maintainer-clean-generic \ - mostlyclean mostlyclean-generic uninstall uninstall-am +clean: clean-am distclean-local: diff --git a/tests/instdata2.test b/tests/instdata2.test new file mode 100755 index 00000000..a49ec5d8 --- /dev/null +++ b/tests/instdata2.test @@ -0,0 +1,21 @@ +#! /bin/sh + +# Test that installing under $exec_prefix is handled by install-exec. +# Testing with headers for instance. + +. $srcdir/defs || exit 1 + +cat >Makefile.am << \EOF +inclexecdir = $(exec_prefix)/include +inclexec_HEADERS = my-config.h + +incldatadir = $(prefix)/include +incldata_HEADERS = my-data.h +EOF + +set -e +$AUTOMAKE +grep '^install-exec-am: install-inclexecHEADERS$' Makefile.in +grep '^install-data-am: install-incldataHEADERS$' Makefile.in + +exit 0 diff --git a/texinfos.am b/texinfos.am index b5236427..280d9bdf 100644 --- a/texinfos.am +++ b/texinfos.am @@ -27,6 +27,9 @@ DVIPS = dvips ## break a possible install-sh reference. ## Funny name due to --cygnus influence; we want to reserve ## `install-info' for the user. +.PHONY: install-info-am +?EXEC??INSTALL-INFO?insexec-data-am: install-info-am +?!EXEC??INSTALL-INFO?install-data-am: install-info-am install-info-am: $(INFO_DEPS) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(infodir) @@ -62,6 +65,8 @@ install-info-am: $(INFO_DEPS) done; \ else : ; fi +.PHONY: uninstall-info +?INSTALL-INFO?uninstall-am: uninstall-info uninstall-info: $(PRE_UNINSTALL) ## Run two loops here so that we can handle PRE_UNINSTALL and @@ -84,6 +89,7 @@ uninstall-info: else :; fi); \ done +.PHONY: dist-info dist-info: $(INFO_DEPS) list='$(INFO_DEPS)'; \ for base in $$list; do \ @@ -97,8 +103,6 @@ dist-info: $(INFO_DEPS) done; \ done -.PHONY: install-info-am uninstall-info - ## How to clean. The funny name is due to --cygnus influence; in ## Cygnus mode, `clean-info' is a target that users can use. -- 2.43.5