mirror of
https://git.FreeBSD.org/ports.git
synced 2024-12-14 03:10:47 +00:00
51952d781a
(thanks!) so remove NO_CDROM. It still requires a license for commercial use so print that out in MESSAGE. Closes PR ports/2843. Submitted by: bjn@visi.com
50 lines
824 B
Bash
50 lines
824 B
Bash
#!/bin/sh
|
|
#
|
|
# post-patch for sattrack-3.1.6
|
|
# modify bin scripts to point to correct install dir
|
|
#
|
|
# script by Brent J. Nordquist <bjn@visi.com>
|
|
# Sun Mar 2 1997
|
|
#
|
|
if [ -z "$WRKDIR" ]; then
|
|
WRKDIR="$1"
|
|
fi
|
|
RUN="$WRKDIR/SatTrack-3.1.6/run"
|
|
if [ -z "$WRKDIR" -o ! -d "$RUN" ]; then
|
|
echo $0: bad work directory $RUN >&2
|
|
exit 1
|
|
fi
|
|
cd $RUN
|
|
if [ -z "$PREFIX" ]; then
|
|
PREFIX="$2"
|
|
fi
|
|
if [ -z "$PREFIX" ]; then
|
|
echo $0: PREFIX not given >&2
|
|
exit 2
|
|
fi
|
|
|
|
do_subst()
|
|
{
|
|
if [ ! -r $1 ]; then
|
|
echo $0: cannot find file $1 >&2
|
|
exit 3
|
|
fi
|
|
sed "s@set satdir=.*\$@set satdir=$PREFIX/lib@" <$1 >$1.$$
|
|
if [ $? != 0 ]; then
|
|
echo $0: $1 sed failure >&2
|
|
rm -f $1.$$
|
|
exit 4
|
|
fi
|
|
cat $1.$$ >$1
|
|
if [ $? != 0 ]; then
|
|
echo $0: $1 cat failure >&2
|
|
rm -f $1
|
|
mv $1.$$ $1
|
|
exit 5
|
|
fi
|
|
rm -f $1.$$
|
|
}
|
|
|
|
do_subst getsts
|
|
do_subst gettle
|