netcdf-c/librpc/fix
2011-09-02 18:23:45 +00:00

39 lines
642 B
Bash

#!/bin/sh
RPCF="\
rpcdebug.c \
rpcdebug.h \
rpcpath.h \
rpcutil.c \
rpcutil.h"
NCF="\
ncrpc.c \
ncrpc.h \
ncrpccvt.c \
ncrpccvt.h \
ncrpcdispatch.c \
ncrpcdispatch.h \
ncrpcdump.c \
ncrpcdump.h \
ncrpcmeta.c \
ncrpcmeta.h \
ncrpcnode.h \
ncrpcproto.c \
ncrpcproto.h"
for f in ${RPCF} ; do
rm -f ./$f
cat ckp1/$f \
| sed -e 's/[#]include[ \t]*["]cr\([a-zA-Z0-9_]*\)[.]h/#include "rpc\1.h"/' \
| sed -e 's/[#]include[ \t]*["]nccr\([a-zA-Z0-9_]*\)[.]h/#include "ncrpc\1.h"/' \
| sed -e 's/^cr/rpc/' \
| sed -e 's/ CR/ RPC/' \
| sed -e 's/nccr/ncrpc/' \
| sed -e 's/ NCCR/ NCRPC/' \
| cat >./$f
done
exit