From: Ralf Wildenhues Date: Wed, 10 May 2006 20:37:36 +0000 (+0000) Subject: * lib/missing (sed_minuso, sed_output): New variables. X-Git-Tag: Release-1-9b~62 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=503629c4780dbd48669ca19f7687361bc85200e9;p=thirdparty%2Fautomake.git * lib/missing (sed_minuso, sed_output): New variables. (autom4te, help2man, makeinfo): Use them. Unifies detection of `-o FILE', `--output FILE', `--output=FILE', stricter regex. Fixes `missing' to detect `--output' for help2man. Fixes PR automake/483. Report by Dennis J. Linse. (autom4te): Document in `missing --help'. * THANKS: Update. --- diff --git a/ChangeLog b/ChangeLog index 3f293a896..5900fc6f9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,13 @@ +2006-05-10 Ralf Wildenhues + + * lib/missing (sed_minuso, sed_output): New variables. + (autom4te, help2man, makeinfo): Use them. Unifies detection of + `-o FILE', `--output FILE', `--output=FILE', stricter regex. + Fixes `missing' to detect `--output' for help2man. Fixes + PR automake/483. Report by Dennis J. Linse. + (autom4te): Document in `missing --help'. + * THANKS: Update. + 2006-04-26 Thien-Thi Nguyen (tiny change) * doc/automake.texi (Dependency Tracking Evolution): Fix typo. diff --git a/THANKS b/THANKS index e6a4f7743..5c2a8797e 100644 --- a/THANKS +++ b/THANKS @@ -52,6 +52,7 @@ David A. Swierczek swiercze@mr.med.ge.com David Pashley david@davidpashley.com David Zaroski cz253@cleveland.Freenet.Edu Dean Povey dpovey@wedgetail.com +Dennis J. Linse Dennis.J.Linse@SAIC.com Derek R. Price derek.price@openavenue.com Diab Jerius djerius@cfa.harvard.edu Didier Cassirame faded@free.fr diff --git a/lib/missing b/lib/missing index c82c8b56d..fb4f10c49 100755 --- a/lib/missing +++ b/lib/missing @@ -1,7 +1,7 @@ #! /bin/sh # Common stub for a few missing GNU programs while installing. -scriptversion=2006-01-12.21 +scriptversion=2006-05-10.22 # Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003, 2004, 2005, 2006 # Free Software Foundation, Inc. @@ -33,6 +33,8 @@ if test $# -eq 0; then fi run=: +sed_output='s/.* --output[ =]\([^ ]*\).*/\1/p' +sed_minuso='s/.* -o \([^ ]*\).*/\1/p' # In the cases where this matters, `missing' is being run in the # srcdir already. @@ -77,6 +79,7 @@ Supported PROGRAM values: aclocal touch file \`aclocal.m4' autoconf touch file \`configure' autoheader touch file \`config.h.in' + autom4te touch the output file, or create a stub one automake touch all \`Makefile.in' files bison create \`y.tab.[ch]', if possible, from existing .[ch] flex create \`lex.yy.c', if possible, from existing .c @@ -192,8 +195,8 @@ WARNING: \`$1' is needed, but is $msg. You can get \`$1' as part of \`Autoconf' from any GNU archive site." - file=`echo "$*" | sed -n 's/.*--output[ =]*\([^ ]*\).*/\1/p'` - test -z "$file" && file=`echo "$*" | sed -n 's/.*-o[ ]*\([^ ]*\).*/\1/p'` + file=`echo "$*" | sed -n "$sed_output"` + test -z "$file" && file=`echo "$*" | sed -n "$sed_minuso"` if test -f "$file"; then touch $file else @@ -267,11 +270,9 @@ WARNING: \`$1' is $msg. You should only need it if \`Help2man' package in order for those modifications to take effect. You can get \`Help2man' from any GNU archive site." - file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'` - if test -z "$file"; then - file=`echo "$*" | sed -n 's/.*--output=\([^ ]*\).*/\1/p'` - fi - if [ -f "$file" ]; then + file=`echo "$*" | sed -n "$sed_output"` + test -z "$file" && file=`echo "$*" | sed -n "$sed_minuso"` + if test -f "$file"; then touch $file else test -z "$file" || exec >$file @@ -289,7 +290,8 @@ WARNING: \`$1' is $msg. You should only need it if DU, IRIX). You might want to install the \`Texinfo' package or the \`GNU make' package. Grab either from any GNU archive site." # The file to touch is that specified with -o ... - file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'` + file=`echo "$*" | sed -n "$sed_output"` + test -z "$file" && file=`echo "$*" | sed -n "$sed_minuso"` if test -z "$file"; then # ... or it is the one specified with @setfilename ... infile=`echo "$*" | sed 's/.* \([^ ]*\) *$/\1/'`