From: Joe Z. <jz...@us...> - 2002-12-01 03:11:23
|
Update of /cvsroot/bobs/bobs In directory sc8-pr-cvs1:/tmp/cvs-serv32016 Modified Files: install-sh missing mkinstalldirs Log Message: Newest 'make' files. Index: install-sh =================================================================== RCS file: /cvsroot/bobs/bobs/install-sh,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** install-sh 15 Jun 2002 07:00:52 -0000 1.1 --- install-sh 1 Dec 2002 03:11:19 -0000 1.2 *************** *** 110,114 **** exit 1 else ! true fi --- 110,114 ---- exit 1 else ! : fi *************** *** 121,125 **** chmodcmd="" else ! instcmd=mkdir fi else --- 121,125 ---- chmodcmd="" else ! instcmd=$mkdirprog fi else *************** *** 129,135 **** # if $src (and thus $dsttmp) contains '*'. ! if [ -f $src -o -d $src ] then ! true else echo "install: $src does not exist" --- 129,135 ---- # if $src (and thus $dsttmp) contains '*'. ! if [ -f "$src" ] || [ -d "$src" ] then ! : else echo "install: $src does not exist" *************** *** 142,146 **** exit 1 else ! true fi --- 142,146 ---- exit 1 else ! : fi *************** *** 152,156 **** dst="$dst"/`basename $src` else ! true fi fi --- 152,156 ---- dst="$dst"/`basename $src` else ! : fi fi *************** *** 164,169 **** # Skip lots of stat calls in the usual case. if [ ! -d "$dstdir" ]; then ! defaultIFS=' ! ' IFS="${IFS-${defaultIFS}}" --- 164,169 ---- # Skip lots of stat calls in the usual case. if [ ! -d "$dstdir" ]; then ! defaultIFS=' ! ' IFS="${IFS-${defaultIFS}}" *************** *** 184,188 **** $mkdirprog "${pathcomp}" else ! true fi --- 184,188 ---- $mkdirprog "${pathcomp}" else ! : fi *************** *** 195,202 **** $doit $instcmd $dst && ! if [ x"$chowncmd" != x ]; then $doit $chowncmd $dst; else true ; fi && ! if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dst; else true ; fi && ! if [ x"$stripcmd" != x ]; then $doit $stripcmd $dst; else true ; fi && ! if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dst; else true ; fi else --- 195,202 ---- $doit $instcmd $dst && ! if [ x"$chowncmd" != x ]; then $doit $chowncmd $dst; else : ; fi && ! if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dst; else : ; fi && ! if [ x"$stripcmd" != x ]; then $doit $stripcmd $dst; else : ; fi && ! if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dst; else : ; fi else *************** *** 217,221 **** dstfile=`basename $dst` else ! true fi --- 217,221 ---- dstfile=`basename $dst` else ! : fi *************** *** 236,243 **** # errors from the above "$doit $instcmd $src $dsttmp" command. ! if [ x"$chowncmd" != x ]; then $doit $chowncmd $dsttmp; else true;fi && ! if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dsttmp; else true;fi && ! if [ x"$stripcmd" != x ]; then $doit $stripcmd $dsttmp; else true;fi && ! if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dsttmp; else true;fi && # Now rename the file to the real destination. --- 236,243 ---- # errors from the above "$doit $instcmd $src $dsttmp" command. ! if [ x"$chowncmd" != x ]; then $doit $chowncmd $dsttmp; else :;fi && ! if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dsttmp; else :;fi && ! if [ x"$stripcmd" != x ]; then $doit $stripcmd $dsttmp; else :;fi && ! if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dsttmp; else :;fi && # Now rename the file to the real destination. Index: missing =================================================================== RCS file: /cvsroot/bobs/bobs/missing,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** missing 15 Jun 2002 07:00:52 -0000 1.1 --- missing 1 Dec 2002 03:11:19 -0000 1.2 *************** *** 1,6 **** #! /bin/sh # Common stub for a few missing GNU programs while installing. ! # Copyright (C) 1996, 1997, 2001 Free Software Foundation, Inc. ! # Franc,ois Pinard <pi...@ir...>, 1996. # This program is free software; you can redistribute it and/or modify --- 1,6 ---- #! /bin/sh # Common stub for a few missing GNU programs while installing. ! # Copyright (C) 1996, 1997, 1999, 2000, 2002 Free Software Foundation, Inc. ! # Originally by Fran,cois Pinard <pi...@ir...>, 1996. # This program is free software; you can redistribute it and/or modify *************** *** 19,22 **** --- 19,27 ---- # 02111-1307, USA. + # As a special exception to the GNU General Public License, if you + # distribute this file as part of a program that contains a + # configuration script generated by Autoconf, you may include it under + # the same distribution terms that you use for the rest of that program. + if test $# -eq 0; then echo 1>&2 "Try \`$0 --help' for more information" *************** *** 24,30 **** fi # In the cases where this matters, `missing' is being run in the # srcdir already. ! if test -f configure.in; then configure_ac=configure.ac else --- 29,37 ---- fi + run=: + # In the cases where this matters, `missing' is being run in the # srcdir already. ! if test -f configure.ac; then configure_ac=configure.ac else *************** *** 33,36 **** --- 40,54 ---- case "$1" in + --run) + # Try to run requested program, and just exit if it succeeds. + run= + shift + "$@" && exit 0 + ;; + esac + + # If it does not exist, or fails to run (possibly an outdated version), + # try to emulate it. + case "$1" in -h|--h|--he|--hel|--help) *************** *** 44,47 **** --- 62,66 ---- -h, --help display this help and exit -v, --version output version information and exit + --run try to run the given command, and emulate it if it fails Supported PROGRAM values: *************** *** 52,62 **** bison create \`y.tab.[ch]', if possible, from existing .[ch] flex create \`lex.yy.c', if possible, from existing .c lex create \`lex.yy.c', if possible, from existing .c makeinfo touch the output file yacc create \`y.tab.[ch]', if possible, from existing .[ch]" ;; -v|--v|--ve|--ver|--vers|--versi|--versio|--version) ! echo "missing - GNU libit 0.0" ;; --- 71,83 ---- bison create \`y.tab.[ch]', if possible, from existing .[ch] flex create \`lex.yy.c', if possible, from existing .c + help2man touch the output file lex create \`lex.yy.c', if possible, from existing .c makeinfo touch the output file + tar try tar, gnutar, gtar, then tar without non-portable flags yacc create \`y.tab.[ch]', if possible, from existing .[ch]" ;; -v|--v|--ve|--ver|--vers|--versi|--versio|--version) ! echo "missing 0.4 - GNU automake" ;; *************** *** 67,74 **** ;; ! aclocal) echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if ! you modified \`acinclude.m4' or \`$configure_ac'. You might want to install the \`Automake' and \`Perl' packages. Grab them from any GNU archive site." --- 88,100 ---- ;; ! aclocal*) ! if test -z "$run" && ($1 --version) > /dev/null 2>&1; then ! # We have it, but it failed. ! exit 1 ! fi ! echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if ! you modified \`acinclude.m4' or \`${configure_ac}'. You might want to install the \`Automake' and \`Perl' packages. Grab them from any GNU archive site." *************** *** 77,83 **** autoconf) echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if ! you modified \`$configure_ac'. You might want to install the \`Autoconf' and \`GNU m4' packages. Grab them from any GNU archive site." --- 103,114 ---- autoconf) + if test -z "$run" && ($1 --version) > /dev/null 2>&1; then + # We have it, but it failed. + exit 1 + fi + echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if ! you modified \`${configure_ac}'. You might want to install the \`Autoconf' and \`GNU m4' packages. Grab them from any GNU archive site." *************** *** 86,95 **** autoheader) echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if ! you modified \`acconfig.h' or \`$configure_ac'. You might want to install the \`Autoconf' and \`GNU m4' packages. Grab them from any GNU archive site." ! files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' $configure_ac` test -z "$files" && files="config.h" touch_files= --- 117,131 ---- autoheader) + if test -z "$run" && ($1 --version) > /dev/null 2>&1; then + # We have it, but it failed. + exit 1 + fi + echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if ! you modified \`acconfig.h' or \`${configure_ac}'. You might want to install the \`Autoconf' and \`GNU m4' packages. Grab them from any GNU archive site." ! files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' ${configure_ac}` test -z "$files" && files="config.h" touch_files= *************** *** 104,111 **** ;; ! automake) echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if ! you modified \`Makefile.am', \`acinclude.m4' or \`$configure_ac'. You might want to install the \`Automake' and \`Perl' packages. Grab them from any GNU archive site." --- 140,152 ---- ;; ! automake*) ! if test -z "$run" && ($1 --version) > /dev/null 2>&1; then ! # We have it, but it failed. ! exit 1 ! fi ! echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if ! you modified \`Makefile.am', \`acinclude.m4' or \`${configure_ac}'. You might want to install the \`Automake' and \`Perl' packages. Grab them from any GNU archive site." *************** *** 115,118 **** --- 156,187 ---- ;; + autom4te) + if test -z "$run" && ($1 --version) > /dev/null 2>&1; then + # We have it, but it failed. + exit 1 + fi + + echo 1>&2 "\ + WARNING: \`$1' is needed, and you do not seem to have it handy on your + system. You might have modified some files without having the + proper tools for further handling them. + You can get \`$1Help2man' 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'` + if test -f "$file"; then + touch $file + else + test -z "$file" || exec >$file + echo "#! /bin/sh" + echo "# Created by GNU Automake missing as a replacement of" + echo "# $ $@" + echo "exit 0" + chmod +x $file + exit 1 + fi + ;; + bison|yacc) echo 1>&2 "\ *************** *** 168,172 **** --- 237,271 ---- ;; + help2man) + if test -z "$run" && ($1 --version) > /dev/null 2>&1; then + # We have it, but it failed. + exit 1 + fi + + echo 1>&2 "\ + WARNING: \`$1' is missing on your system. You should only need it if + you modified a dependency of a manual page. You may need the + \`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 + touch $file + else + test -z "$file" || exec >$file + echo ".ab help2man is required to generate this page" + exit 1 + fi + ;; + makeinfo) + if test -z "$run" && (makeinfo --version) > /dev/null 2>&1; then + # We have makeinfo, but it failed. + exit 1 + fi + echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if *************** *** 182,185 **** --- 281,323 ---- fi touch $file + ;; + + tar) + shift + if test -n "$run"; then + echo 1>&2 "ERROR: \`tar' requires --run" + exit 1 + fi + + # We have already tried tar in the generic part. + # Look for gnutar/gtar before invocation to avoid ugly error + # messages. + if (gnutar --version > /dev/null 2>&1); then + gnutar "$@" && exit 0 + fi + if (gtar --version > /dev/null 2>&1); then + gtar "$@" && exit 0 + fi + firstarg="$1" + if shift; then + case "$firstarg" in + *o*) + firstarg=`echo "$firstarg" | sed s/o//` + tar "$firstarg" "$@" && exit 0 + ;; + esac + case "$firstarg" in + *h*) + firstarg=`echo "$firstarg" | sed s/h//` + tar "$firstarg" "$@" && exit 0 + ;; + esac + fi + + echo 1>&2 "\ + WARNING: I can't seem to be able to run \`tar' with the given arguments. + You may want to install GNU tar or Free paxutils, or check the + command line arguments." + exit 1 ;; Index: mkinstalldirs =================================================================== RCS file: /cvsroot/bobs/bobs/mkinstalldirs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** mkinstalldirs 15 Jun 2002 07:00:52 -0000 1.1 --- mkinstalldirs 1 Dec 2002 03:11:19 -0000 1.2 *************** *** 5,11 **** # Public domain - # $Id$ - errstatus=0 for file --- 5,55 ---- # Public domain errstatus=0 + dirmode="" + + usage="\ + Usage: mkinstalldirs [-h] [--help] [-m mode] dir ..." + + # process command line arguments + while test $# -gt 0 ; do + case "${1}" in + -h | --help | --h* ) # -h for help + echo "${usage}" 1>&2; exit 0 ;; + -m ) # -m PERM arg + shift + test $# -eq 0 && { echo "${usage}" 1>&2; exit 1; } + dirmode="${1}" + shift ;; + -- ) shift; break ;; # stop option processing + -* ) echo "${usage}" 1>&2; exit 1 ;; # unknown option + * ) break ;; # first non-opt arg + esac + done + + for file + do + if test -d "$file"; then + shift + else + break + fi + done + + case $# in + 0) exit 0 ;; + esac + + case $dirmode in + '') + if mkdir -p -- . 2>/dev/null; then + echo "mkdir -p -- $*" + exec mkdir -p -- "$@" + fi ;; + *) + if mkdir -m "$dirmode" -p -- . 2>/dev/null; then + echo "mkdir -m $dirmode -p -- $*" + exec mkdir -m "$dirmode" -p -- "$@" + fi ;; + esac for file *************** *** 23,33 **** if test ! -d "$pathcomp"; then ! echo "mkdir $pathcomp" ! mkdir "$pathcomp" || lasterr=$? ! if test ! -d "$pathcomp"; then ! errstatus=$lasterr ! fi fi --- 67,88 ---- if test ! -d "$pathcomp"; then ! echo "mkdir $pathcomp" ! mkdir "$pathcomp" || lasterr=$? ! if test ! -d "$pathcomp"; then ! errstatus=$lasterr ! else ! if test ! -z "$dirmode"; then ! echo "chmod $dirmode $pathcomp" ! ! lasterr="" ! chmod "$dirmode" "$pathcomp" || lasterr=$? ! ! if test ! -z "$lasterr"; then ! errstatus=$lasterr ! fi ! fi ! fi fi *************** *** 38,40 **** --- 93,99 ---- exit $errstatus + # Local Variables: + # mode: shell-script + # sh-indentation: 3 + # End: # mkinstalldirs ends here |