Print this page
XXX Remove nawk(1)

Split Close
Expand all
Collapse all
          --- old/usr/src/cmd/sgs/tools/chkmsg.sh
          +++ new/usr/src/cmd/sgs/tools/chkmsg.sh
↓ open down ↓ 16 lines elided ↑ open up ↑
  17   17  # fields enclosed by brackets "[]" replaced with your own identifying
  18   18  # information: Portions Copyright [yyyy] [name of copyright owner]
  19   19  #
  20   20  # CDDL HEADER END
  21   21  #
  22   22  
  23   23  #
  24   24  # Copyright 2006 Sun Microsystems, Inc.  All rights reserved.
  25   25  # Use is subject to license terms.
  26   26  #
  27      -# ident "%Z%%M% %I%     %E% SMI"
  28   27  
  29   28  TOOLDIR="${SRC}/cmd/sgs/tools/"
  30   29  
  31   30  #
  32   31  # remove the temporary files
  33   32  #
  34   33  rm -f CATA_MSG_INTL_LIST CATA_MSG_ORIG_LIST
  35   34  rm -f MSG_INTL_LIST MSG_ORIG_LIST
  36   35  
  37   36  while getopts "m:" Arg
  38   37  do
  39   38          case $Arg in
  40      -        m)      nawk -f ${TOOLDIR}/catalog.awk $OPTARG ;;
       39 +        m)      /usr/xpg4/bin/awk -f ${TOOLDIR}/catalog.awk $OPTARG ;;
  41   40          \?)     echo "usage: chkmsg -m msgfile source-files" ; exit 1 ;;
  42   41          esac
  43   42  done
  44   43  shift `expr $OPTIND - 1`
  45   44  
  46   45  if [ $# -eq 0 ]; then
  47   46          echo "usage: chkmsg -m msgfile source-files"
  48   47          exit 1
  49   48  fi
  50   49  
↓ open down ↓ 6 lines elided ↑ open up ↑
  57   56          mv _TMP CATA_MSG_INTL_LIST
  58   57  fi
  59   58  if [ -s CATA_MSG_ORIG_LIST ] ; then
  60   59          sed -e "s/_32$//" -e "s/_64$//" CATA_MSG_ORIG_LIST | sort | uniq > _TMP
  61   60          mv _TMP CATA_MSG_ORIG_LIST
  62   61  fi
  63   62  
  64   63  #
  65   64  # Generate the lists for the source files and sort them
  66   65  #
  67      -nawk -f  ${TOOLDIR}/getmessage.awk      $*
       66 +/usr/xpg4/bin/awk -f  ${TOOLDIR}/getmessage.awk $*
  68   67  
  69   68  if [ -s MSG_INTL_LIST ] ; then
  70   69          sed -e "s/_32$//" -e "s/_64$//" MSG_INTL_LIST | sort | uniq > _TMP
  71   70          mv _TMP MSG_INTL_LIST
  72   71  fi
  73   72  if [ -s MSG_ORIG_LIST ] ; then
  74   73          sed -e "s/_32$//" -e "s/_64$//" MSG_ORIG_LIST | sort | uniq > _TMP
  75   74          mv _TMP MSG_ORIG_LIST
  76   75  fi
  77   76  
↓ open down ↓ 54 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX