[PATCH modular 2/3] Add extra check for 'prefix'.

Trevor Woerner twoerner at gmail.com
Mon Oct 4 10:56:52 PDT 2010


From: Trevor Woerner <twoerner at gmail.com>

Make sure not to mistake an unknown option for a missing 'prefix'.

Signed-off-by: Trevor Woerner <twoerner at gmail.com>
---
 build.sh |   10 ++++++++++
 1 files changed, 10 insertions(+), 0 deletions(-)

diff --git a/build.sh b/build.sh
index 93ad6e5..585ff9c 100755
--- a/build.sh
+++ b/build.sh
@@ -1031,6 +1031,16 @@ do
 	    usage
 	    exit 1
 	fi
+
+	# check that 'prefix' doesn't look like an option
+	echo $1 | grep "^-" > /dev/null
+	if [ $? -eq 0 ]; then
+	    echo "'prefix' appears to be an option"
+	    echo ""
+	    usage
+	    exit 1
+	fi
+
 	PREFIX=$1
 	;;
     esac
-- 
1.7.3.1.50.g1e633



More information about the xorg-devel mailing list