From: Alexandre Oliva Date: Thu, 4 Nov 1999 15:46:07 +0000 (+0000) Subject: * configure.in: Move ltconfig and ltmain.sh generation back... X-Git-Tag: multi-language-fork~11 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=527fc71c0389bf7b4d5c56355e534c581e67c34c;p=thirdparty%2Flibtool.git * configure.in: Move ltconfig and ltmain.sh generation back... * Makefile.am: here. --- diff --git a/ChangeLog b/ChangeLog index 127284ff4..a4e960e71 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +1999-11-04 Alexandre Oliva + + * configure.in: Move ltconfig and ltmain.sh generation back... + * Makefile.am: here. + 1999-11-02 Thomas Tanner * NEWS: updated diff --git a/Makefile.am b/Makefile.am index 2b590e103..0d2d23928 100644 --- a/Makefile.am +++ b/Makefile.am @@ -66,6 +66,28 @@ update-timestamps: echo "Cannot make dist before commit"; exit 1; else :; fi $(MAKE) TSDEPS="$(TSDEPS_DIST)" $(srcdir)/ltconfig $(srcdir)/ltmain.sh +# Do line number substitution, as well as PACKAGE, VERSION and TIMESTAMP. +# Line numbering transliterated from a section in autoconf (Autoconf 2.12). +@srcdir@/ltconfig: $(srcdir)/ltconfig.in $(top_srcdir)/configure.in $(TSDEPS) + rm -f ltconfig.T + date=`$(SHELL) $(srcdir)/mkstamp < $(srcdir)/ChangeLog` && \ + $(AWK) '/@LINENO@/ { printf "%d:", NR } { print }' $(srcdir)/ltconfig.in | \ + sed -e 's/@''PACKAGE@/@PACKAGE@/' -e 's/@''VERSION@/@VERSION@/' \ + -e "s%@""TIMESTAMP@%$$date%" \ + -e '/@LINENO@/s/^\([0-9][0-9]*\):\(.*\)@LINENO@/\2\1/' \ + > ltconfig.T + chmod +x ltconfig.T + mv -f ltconfig.T $@ || \ + (rm -f $@ && cp ltconfig.T $@ && rm -f ltconfig.T) + +@srcdir@/ltmain.sh: $(srcdir)/ltmain.in $(top_srcdir)/configure.in $(TSDEPS) + rm -f ltmain.shT + date=`$(SHELL) $(srcdir)/mkstamp < $(srcdir)/ChangeLog` && \ + sed -e 's/@''PACKAGE@/@PACKAGE@/' -e 's/@''VERSION@/@VERSION@/' \ + -e "s%@""TIMESTAMP@%$$date%" $(srcdir)/ltmain.in > ltmain.shT + mv -f ltmain.shT $@ || \ + (rm -f $@ && cp ltmain.shT $@ && rm -f ltmain.shT) + # All our rules should depend on these demo files. all-recursive: $(ACINCLUDE_M4_LIST) diff --git a/configure.in b/configure.in index 875a28351..7a131f7a9 100644 --- a/configure.in +++ b/configure.in @@ -72,53 +72,7 @@ done AC_SUBST(ACINCLUDE_M4_LIST) AC_SUBST(DIST_MAKEFILE_LIST) -AC_OUTPUT_COMMANDS([ - if test -n "$CONFIG_FILES" && test -n "$CONFIG_HEADERS"; then - # If both these vars are non-empty, then config.status wasn't run by - # automake rules (which always set one or the other to empty). - CONFIG_OTHER=${CONFIG_OTHER-ltconfig ltmain.sh} - fi - case "$CONFIG_FILES" in - *ltconfig*) - infile=ltconfig.in - outfile=ltconfig - tmpfile=${outfile}T - - ( cd $top_srcdir - rm -f $tmpfile - ${AWK} ' - /@LINENO@/ { sub("@LINENO@", NR); } - { print; } - ' $outfile > $tmpfile - - chmod +x $tmpfile - rm -f $outfile - mv -f $tmpfile $outfile || \ - (rm -f $outfile && cp $tmpfile $outfile && rm -f $tmpfile) - ) - ;; - - *ltmain.sh*) - infile=$top_srcdir/ltmain.in - outfile=$top_srcdir/ltmain.sh - tmpfile=${outfile}T - - ( cd $top_srcdir - rm -f $tmpfile - ${AWK} ' - /@LINENO@/ { sub("@LINENO@", NR); } - { print; } - ' $outfile > $tmpfile - - rm -f $outfile - mv -f $tmpfile $outfile || \ - (rm -f $outfile && cp $tmpfile $outfile && rm -f $tmpfile) - ) - ;; - esac -], [top_srcdir=$srcdir; AWK=$AWK]) - -AC_OUTPUT([Makefile doc/Makefile tests/Makefile $srcdir/ltconfig:ltconfig.in $srcdir/ltmain.sh:ltmain.in]) +AC_OUTPUT([Makefile doc/Makefile tests/Makefile]) # Local Variables: # mode:shell-script