make scripts work with more shells,

use current variable names.
This commit is contained in:
rsc 2004-04-21 05:49:52 +00:00
parent 0d6c3c2408
commit 7ac9b0e140
5 changed files with 10 additions and 6 deletions

View file

@ -2,6 +2,6 @@
DIRS=\ DIRS=\
port\ port\
$objtype\ $OBJTYPE\
<$PLAN9/src/mkdirs <$PLAN9/src/mkdirs

View file

@ -35,7 +35,7 @@ FILES=\
ALLOFILES=${FILES:%=%.$O} ALLOFILES=${FILES:%=%.$O}
# cull things in the per-machine directories from this list # cull things in the per-machine directories from this list
OFILES= `{sh ./reduce $O $objtype $ALLOFILES} OFILES= `{sh ./reduce $O $OBJTYPE $ALLOFILES}
HFILES=\ HFILES=\
$PLAN9/include/lib9.h\ $PLAN9/include/lib9.h\

View file

@ -3,6 +3,8 @@ shift
objtype=$1 objtype=$1
shift shift
reduce="("`ls -p ../$objtype/*.[cs] 2>/dev/null | sed 's/..$//' | sed 's/^.*\///' | tr '\012' '|' | sed 's/.$//'`")" nl='
'
reduce="("`ls -p ../$objtype/*.[cs] 2>/dev/null | sed 's/..$//' | sed 's/^.*\///' | tr "$nl" '|' | sed 's/.$//'`")"
echo $* | tr ' ' '\012' | egrep -v $reduce | tr \012 ' ' echo $* | tr ' ' "$nl" | egrep -v $reduce | tr "$nl" ' '

View file

@ -2,6 +2,6 @@
DIRS=\ DIRS=\
port\ port\
# $systype-$objtype\ $OBJTYPE\
<$PLAN9/src/mkdirs <$PLAN9/src/mkdirs

View file

@ -2,7 +2,7 @@
LIB=libsec.a LIB=libsec.a
OFILES=\ ALLOFILES=\
aes.$O\ aes.$O\
blowfish.$O\ blowfish.$O\
decodepem.$O\ decodepem.$O\
@ -54,6 +54,8 @@ OFILES=\
tlshand.$O\ tlshand.$O\
x509.$O\ x509.$O\
OFILES=`{sh ./reduce $O $OBJTYPE $ALLOFILES}
HFILES=$PLAN9/include/libsec.h HFILES=$PLAN9/include/libsec.h
<$PLAN9/src/mksyslib <$PLAN9/src/mksyslib