Fixed adding EXEEXT at the end of the application name; run the app using

exec; some other minor fixes - a comment, some quotes


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/tools/make/trunk@13243 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Nicola Pero 2002-03-26 17:36:31 +00:00
parent 16a16229ca
commit 8e08ef8843

View file

@ -31,9 +31,6 @@ fi
if [ -z "$GNUSTEP_FLATTENED" ]; then
GNUSTEP_FLATTENED=@GNUSTEP_FLATTENED@
fi
if [ -z "$EXEEXT" ]; then
EXEEXT=@EXEEXT@
fi
# trap the --library-combo parameter
case $1 in
@ -53,10 +50,6 @@ esac
# Remove leading slashes at the end of the application name
app=`echo $app | sed 's%/*$%%'`
if [ -n "$EXEEXT" ]; then
app=$app$EXEEXT
fi
case $app in
/*) # An absolute path.
full_appname=$app;;
@ -91,11 +84,24 @@ fi
appname=`echo $app | sed 's/\.[a-z]*$//'`
appname=`basename $appname`
if [ ! -f $full_appname/$appname ]; then
echo "Could not find $full_appname executable/script"
if [ -n "$GNUSTEP_FLATTENED" ]; then
if [ -z "$EXEEXT" ]; then
EXEEXT=@EXEEXT@
fi
if [ -n "$EXEEXT" ]; then
appname="$appname$EXEEXT"
fi
fi
if [ ! -f "$full_appname/$appname" ]; then
echo "Could not find $full_appname/$appname executable/script"
exit 1
fi
IFS=" "
$full_appname/$appname "$@"
exec "$full_appname/$appname" "$@"