re PR bootstrap/14905 ('make install' fails on grepjar.1, not included in tarball)
authorKelley Cook <kcook@gcc.gnu.org>
Mon, 12 Apr 2004 20:29:49 +0000 (20:29 +0000)
committerR. Kelley Cook <kcook@gcc.gnu.org>
Mon, 12 Apr 2004 20:29:49 +0000 (20:29 +0000)
2004-04-12  Kelley Cook  <kcook@gcc.gnu.org>

PR bootstrap/14905
* configure.ac: Parse --enable-generated-files-in-srcdir.
* Makefile.am: Copy man and info files to srcdir if requested.
* configure: Regenerate.
* Makefile.in Regenerate.

From-SVN: r80628

fastjar/ChangeLog
fastjar/Makefile.am
fastjar/Makefile.in
fastjar/configure
fastjar/configure.ac

index e5d690bde1c14a60d11a0220d9220870f7ea269f..5032e913ccaacbab18f5c6f26be3ae6db2692dec 100644 (file)
@@ -1,3 +1,11 @@
+2004-04-12  Kelley Cook  <kcook@gcc.gnu.org>
+
+       PR bootstrap/14905
+       * configure.ac: Parse --enable-generated-files-in-srcdir.
+       * Makefile.am: Copy man and info files to srcdir if requested.
+       * configure: Regenerate.
+       * Makefile.in Regenerate.
+
 2004-03-10  Kelley Cook  <kcook@gcc.gnu.org>
 
        * configure.ac: Bump AC_PREREQ to 2.59.
index 3d4ea36c23286117c30d7677723b6ade2a53a97b..6c442e22868cf691c661d816d646500a7be7681f 100644 (file)
@@ -82,3 +82,27 @@ jar.pod: $(srcdir)/fastjar.texi
 
 grepjar.pod: $(srcdir)/fastjar.texi
        -$(TEXI2POD) -D grepjar $< > $@
+
+# GCC LOCAL CHANGE
+# The following commands allow us to release tarballs with the man pages
+# and info documentation prebuilt.  This feature is enabled via 
+# --enable-generated-files-in-srcdir in the configure script.
+
+if GENINSRC
+STAMP_GENINSRC = stamp-geninsrc
+else
+STAMP_GENINSRC =
+endif
+
+all-local: $(STAMP_GENINSRC) 
+
+stamp-geninsrc: jar.1 grepjar.1 fastjar.info
+       -cp -p $(top_builddir)/jar.1 $(srcdir)/jar.1
+       -cp -p $(top_builddir)/grepjar.1 $(srcdir)/grepjar.1
+       -cp -p $(top_builddir)/fastjar.info $(srcdir)/fastjar.info
+       touch $@
+
+CLEANFILES = stamp-geninsrc
+MAINTAINERCLEANFILES = $(srcdir)/jar.1 \
+                       $(srcdir)/grepjar.1 \
+                       $(srcdir)/fastjar.info
index 2e295a25c71ce4630c26f9f684a7038bc004a0fd..2260777ed82cae64117f5a5ef8e1c8fcde720e13 100644 (file)
@@ -60,6 +60,8 @@ ECHO_N = @ECHO_N@
 ECHO_T = @ECHO_T@
 EGREP = @EGREP@
 EXEEXT = @EXEEXT@
+GENINSRC_FALSE = @GENINSRC_FALSE@
+GENINSRC_TRUE = @GENINSRC_TRUE@
 INSTALL_DATA = @INSTALL_DATA@
 INSTALL_PROGRAM = @INSTALL_PROGRAM@
 INSTALL_SCRIPT = @INSTALL_SCRIPT@
@@ -189,6 +191,20 @@ EXTRA_DIST = $(man_MANS)
 
 TEXI2POD = perl $(srcdir)/../contrib/texi2pod.pl
 POD2MAN = pod2man --center="GNU" --release="gcc-@gcc_version@"
+@GENINSRC_FALSE@STAMP_GENINSRC = 
+
+
+# GCC LOCAL CHANGE
+# The following commands allow us to release tarballs with the man pages
+# and info documentation prebuilt.  This feature is enabled via 
+# --enable-generated-files-in-srcdir in the configure script.
+@GENINSRC_TRUE@STAMP_GENINSRC = stamp-geninsrc
+
+CLEANFILES = stamp-geninsrc
+MAINTAINERCLEANFILES = $(srcdir)/jar.1 \
+                       $(srcdir)/grepjar.1 \
+                       $(srcdir)/fastjar.info
+
 subdir = .
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
 mkinstalldirs = $(SHELL) $(top_srcdir)/../mkinstalldirs
@@ -601,7 +617,7 @@ distcleancheck: distclean
               exit 1; } >&2
 check-am: all-am
 check: check-am
-all-am: Makefile $(INFO_DEPS) $(PROGRAMS) $(MANS) config.h
+all-am: Makefile $(INFO_DEPS) $(PROGRAMS) $(MANS) config.h all-local
 
 installdirs:
        $(mkinstalldirs) $(DESTDIR)$(bindir) $(DESTDIR)$(infodir) $(DESTDIR)$(man1dir)
@@ -622,6 +638,7 @@ install-strip:
 mostlyclean-generic:
 
 clean-generic:
+       -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
 
 distclean-generic:
        -rm -f $(CONFIG_CLEAN_FILES)
@@ -629,6 +646,7 @@ distclean-generic:
 maintainer-clean-generic:
        @echo "This command is intended for maintainers to use"
        @echo "it deletes files that may require special tools to rebuild."
+       -test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
 clean: clean-am
 
 clean-am: clean-binPROGRAMS clean-generic mostlyclean-am
@@ -707,19 +725,20 @@ uninstall-am: uninstall-binPROGRAMS uninstall-info-am uninstall-man
 
 uninstall-man: uninstall-man1
 
-.PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \
-       clean-generic ctags dist dist-all dist-gzip dist-info distcheck \
-       distclean distclean-compile distclean-generic distclean-hdr \
-       distclean-tags distcleancheck distdir distuninstallcheck dvi \
-       dvi-am info info-am install install-am install-binPROGRAMS \
-       install-data install-data-am install-exec install-exec-am \
-       install-info install-info-am install-man install-man1 \
-       install-strip installcheck installcheck-am installdirs \
-       maintainer-clean maintainer-clean-aminfo \
-       maintainer-clean-generic mostlyclean mostlyclean-aminfo \
-       mostlyclean-compile mostlyclean-generic pdf pdf-am ps ps-am \
-       tags uninstall uninstall-am uninstall-binPROGRAMS \
-       uninstall-info-am uninstall-man uninstall-man1
+.PHONY: CTAGS GTAGS all all-am all-local check check-am clean \
+       clean-binPROGRAMS clean-generic ctags dist dist-all dist-gzip \
+       dist-info distcheck distclean distclean-compile \
+       distclean-generic distclean-hdr distclean-tags distcleancheck \
+       distdir distuninstallcheck dvi dvi-am info info-am install \
+       install-am install-binPROGRAMS install-data install-data-am \
+       install-exec install-exec-am install-info install-info-am \
+       install-man install-man1 install-strip installcheck \
+       installcheck-am installdirs maintainer-clean \
+       maintainer-clean-aminfo maintainer-clean-generic mostlyclean \
+       mostlyclean-aminfo mostlyclean-compile mostlyclean-generic pdf \
+       pdf-am ps ps-am tags uninstall uninstall-am \
+       uninstall-binPROGRAMS uninstall-info-am uninstall-man \
+       uninstall-man1
 
 
 %.1: %.pod
@@ -734,6 +753,14 @@ jar.pod: $(srcdir)/fastjar.texi
 
 grepjar.pod: $(srcdir)/fastjar.texi
        -$(TEXI2POD) -D grepjar $< > $@
+
+all-local: $(STAMP_GENINSRC) 
+
+stamp-geninsrc: jar.1 grepjar.1 fastjar.info
+       -cp -p $(top_builddir)/jar.1 $(srcdir)/jar.1
+       -cp -p $(top_builddir)/grepjar.1 $(srcdir)/grepjar.1
+       -cp -p $(top_builddir)/fastjar.info $(srcdir)/fastjar.info
+       touch $@
 # 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.
 .NOEXPORT:
index 9c07ad4b98d775bf46bebcb4df2914d4c5fa2da6..6c17bc46d6815201523a2cd2f82f338fd3d17bfe 100755 (executable)
@@ -309,7 +309,7 @@ ac_includes_default="\
 # include <unistd.h>
 #endif"
 
-ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CYGPATH_W PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO AMTAR install_sh STRIP ac_ct_STRIP INSTALL_STRIP_PROGRAM AWK SET_MAKE am__leading_dot CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT DEPDIR am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH CCDEPMODE am__fastdepCC_TRUE am__fastdepCC_FALSE RM CP CHMOD MAINTAINER_MODE_TRUE MAINTAINER_MODE_FALSE MAINT fastjar_warn_cflags CPP EGREP ZLIBS ZDEPS ZINCS gcc_version LIBOBJS LTLIBOBJS'
+ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CYGPATH_W PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO AMTAR install_sh STRIP ac_ct_STRIP INSTALL_STRIP_PROGRAM AWK SET_MAKE am__leading_dot CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT DEPDIR am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH CCDEPMODE am__fastdepCC_TRUE am__fastdepCC_FALSE RM CP CHMOD MAINTAINER_MODE_TRUE MAINTAINER_MODE_FALSE MAINT fastjar_warn_cflags CPP EGREP ZLIBS ZDEPS ZINCS GENINSRC_TRUE GENINSRC_FALSE gcc_version LIBOBJS LTLIBOBJS'
 ac_subst_files=''
 
 # Initialize some variables set by options.
@@ -849,6 +849,10 @@ Optional Features:
   --enable-dependency-tracking  Do not reject slow dependency extractors
   --enable-maintainer-mode enable make rules and dependencies not useful
                           (and sometimes confusing) to the casual installer
+  --enable-generated-files-in-srcdir
+                          put copies of generated files in source dir
+                          intended for creating source tarballs for users
+                          without texinfo, perl, bison or flex.
 
 Optional Packages:
   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
@@ -4981,6 +4985,36 @@ fi
 
 
 
+# GCC LOCAL CHANGE
+# We would like to our source tree to be readonly.  However when releases or
+# pre-releases are generated, the man pages need to be included as they are
+# converted from the texi files via perl which we don't require end users to
+# have installed.
+# Therefore we have --enable-generated-files-in-srcdir to do just that.
+
+echo "$as_me:$LINENO: checking whether to place generated files in the source directory" >&5
+echo $ECHO_N "checking whether to place generated files in the source directory... $ECHO_C" >&6
+    # Check whether --enable-generated-files-in-srcdir or --disable-generated-files-in-srcdir was given.
+if test "${enable_generated_files_in_srcdir+set}" = set; then
+  enableval="$enable_generated_files_in_srcdir"
+  generated_files_in_srcdir=$enableval
+else
+  generated_files_in_srcdir=no
+fi;
+
+echo "$as_me:$LINENO: result: $generated_files_in_srcdir" >&5
+echo "${ECHO_T}$generated_files_in_srcdir" >&6
+
+
+if test x$generated_files_in_srcdir = xyes; then
+  GENINSRC_TRUE=
+  GENINSRC_FALSE='#'
+else
+  GENINSRC_TRUE='#'
+  GENINSRC_FALSE=
+fi
+
+
 # Get the version trigger filename from the toplevel
 if test "${with_gcc_version_trigger+set}" = set; then
    gcc_version_trigger=$with_gcc_version_trigger
@@ -5104,6 +5138,13 @@ echo "$as_me: error: conditional \"MAINTAINER_MODE\" was never defined.
 Usually this means the macro was only invoked conditionally." >&2;}
    { (exit 1); exit 1; }; }
 fi
+if test -z "${GENINSRC_TRUE}" && test -z "${GENINSRC_FALSE}"; then
+  { { echo "$as_me:$LINENO: error: conditional \"GENINSRC\" was never defined.
+Usually this means the macro was only invoked conditionally." >&5
+echo "$as_me: error: conditional \"GENINSRC\" was never defined.
+Usually this means the macro was only invoked conditionally." >&2;}
+   { (exit 1); exit 1; }; }
+fi
 
 : ${CONFIG_STATUS=./config.status}
 ac_clean_files_save=$ac_clean_files
@@ -5684,6 +5725,8 @@ s,@EGREP@,$EGREP,;t t
 s,@ZLIBS@,$ZLIBS,;t t
 s,@ZDEPS@,$ZDEPS,;t t
 s,@ZINCS@,$ZINCS,;t t
+s,@GENINSRC_TRUE@,$GENINSRC_TRUE,;t t
+s,@GENINSRC_FALSE@,$GENINSRC_FALSE,;t t
 s,@gcc_version@,$gcc_version,;t t
 s,@LIBOBJS@,$LIBOBJS,;t t
 s,@LTLIBOBJS@,$LTLIBOBJS,;t t
index bb1ddf0abcbe993e8f35f73d86e2d50b3318b4fb..f80fa54aa3e31505f6e0e3ce875ef62593357162 100644 (file)
@@ -67,6 +67,26 @@ AC_SUBST(ZLIBS)
 AC_SUBST(ZDEPS)
 AC_SUBST(ZINCS)
 
+# GCC LOCAL CHANGE
+# We would like to our source tree to be readonly.  However when releases or
+# pre-releases are generated, the man pages need to be included as they are
+# converted from the texi files via perl which we don't require end users to
+# have installed.
+# Therefore we have --enable-generated-files-in-srcdir to do just that.
+
+AC_MSG_CHECKING([whether to place generated files in the source directory])
+  dnl generated-files-in-srcdir is disabled by default
+  AC_ARG_ENABLE(generated-files-in-srcdir, 
+[  --enable-generated-files-in-srcdir
+                          put copies of generated files in source dir
+                          intended for creating source tarballs for users
+                          without texinfo, perl, bison or flex.],
+      generated_files_in_srcdir=$enableval,
+      generated_files_in_srcdir=no)
+
+AC_MSG_RESULT($generated_files_in_srcdir)
+AM_CONDITIONAL(GENINSRC, test x$generated_files_in_srcdir = xyes)
+
 # Get the version trigger filename from the toplevel
 if test "${with_gcc_version_trigger+set}" = set; then
    gcc_version_trigger=$with_gcc_version_trigger