/[svn]/ircd-hybrid-8/missing
ViewVC logotype

Diff of /ircd-hybrid-8/missing

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1156 by michael, Tue Aug 9 20:29:20 2011 UTC revision 1291 by michael, Sun Feb 12 20:24:41 2012 UTC
# Line 1  Line 1 
1  #! /bin/sh  #! /bin/sh
2  # Common stub for a few missing GNU programs while installing.  # Common stub for a few missing GNU programs while installing.
3    
4  scriptversion=2009-04-28.21; # UTC  scriptversion=2012-01-06.13; # UTC
5    
6  # Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003, 2004, 2005, 2006,  # Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003, 2004, 2005, 2006,
7  # 2008, 2009 Free Software Foundation, Inc.  # 2008, 2009, 2010, 2011, 2012 Free Software Foundation, Inc.
8  # Originally by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996.  # Originally by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996.
9    
10  # This program is free software; you can redistribute it and/or modify  # This program is free software; you can redistribute it and/or modify
# Line 84  Supported PROGRAM values: Line 84  Supported PROGRAM values:
84    help2man     touch the output file    help2man     touch the output file
85    lex          create \`lex.yy.c', if possible, from existing .c    lex          create \`lex.yy.c', if possible, from existing .c
86    makeinfo     touch the output file    makeinfo     touch the output file
   tar          try tar, gnutar, gtar, then tar without non-portable flags  
87    yacc         create \`y.tab.[ch]', if possible, from existing .[ch]    yacc         create \`y.tab.[ch]', if possible, from existing .[ch]
88    
89  Version suffixes to PROGRAM as well as the prefixes \`gnu-', \`gnu', and  Version suffixes to PROGRAM as well as the prefixes \`gnu-', \`gnu', and
# Line 122  case $1 in Line 121  case $1 in
121      # Not GNU programs, they don't have --version.      # Not GNU programs, they don't have --version.
122      ;;      ;;
123    
   tar*)  
     if test -n "$run"; then  
        echo 1>&2 "ERROR: \`tar' requires --run"  
        exit 1  
     elif test "x$2" = "x--version" || test "x$2" = "x--help"; then  
        exit 1  
     fi  
     ;;  
   
124    *)    *)
125      if test -z "$run" && ($1 --version) > /dev/null 2>&1; then      if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
126         # We have it, but it failed.         # We have it, but it failed.
# Line 226  WARNING: \`$1' $msg.  You should only ne Line 216  WARNING: \`$1' $msg.  You should only ne
216           \`Bison' from any GNU archive site."           \`Bison' from any GNU archive site."
217      rm -f y.tab.c y.tab.h      rm -f y.tab.c y.tab.h
218      if test $# -ne 1; then      if test $# -ne 1; then
219          eval LASTARG="\${$#}"          eval LASTARG=\${$#}
220          case $LASTARG in          case $LASTARG in
221          *.y)          *.y)
222              SRCFILE=`echo "$LASTARG" | sed 's/y$/c/'`              SRCFILE=`echo "$LASTARG" | sed 's/y$/c/'`
# Line 256  WARNING: \`$1' is $msg.  You should only Line 246  WARNING: \`$1' is $msg.  You should only
246           \`Flex' from any GNU archive site."           \`Flex' from any GNU archive site."
247      rm -f lex.yy.c      rm -f lex.yy.c
248      if test $# -ne 1; then      if test $# -ne 1; then
249          eval LASTARG="\${$#}"          eval LASTARG=\${$#}
250          case $LASTARG in          case $LASTARG in
251          *.l)          *.l)
252              SRCFILE=`echo "$LASTARG" | sed 's/l$/c/'`              SRCFILE=`echo "$LASTARG" | sed 's/l$/c/'`
# Line 318  WARNING: \`$1' is $msg.  You should only Line 308  WARNING: \`$1' is $msg.  You should only
308      touch $file      touch $file
309      ;;      ;;
310    
   tar*)  
     shift  
   
     # 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  
     ;;  
   
311    *)    *)
312      echo 1>&2 "\      echo 1>&2 "\
313  WARNING: \`$1' is needed, and is $msg.  WARNING: \`$1' is needed, and is $msg.

Legend:
Removed from v.1156  
changed lines
  Added in v.1291

svnadmin@ircd-hybrid.org
ViewVC Help
Powered by ViewVC 1.1.28