Author: pschweitzer
Date: Fri Jul 12 10:10:23 2013
New Revision: 59457
URL:
http://svn.reactos.org/svn/reactos?rev=59457&view=rev
Log:
[CONFIGURE.SH]
Kill bashisms introduced by r59197 and replace them by sh code.
This is mainly to preserve maximum portability of the code, and to
fix configure.sh on platforms where /bin/sh doesn't point to /bin/sh ;-).
Modified:
trunk/reactos/configure.sh
Modified: trunk/reactos/configure.sh
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/configure.sh?rev=59457&…
==============================================================================
--- trunk/reactos/configure.sh [iso-8859-1] (original)
+++ trunk/reactos/configure.sh [iso-8859-1] Fri Jul 12 10:10:23 2013
@@ -16,19 +16,19 @@
}
CMAKE_GENERATOR="Ninja"
-for (( i=1; i<=$#; i++ )); do
- case ${!i} in
+while [ $# -gt 0 ]; do
+ case $1 in
-D)
- ((i++))
- if [[ "x${!i}" == x?*=* ]] ; then
- ROS_CMAKEOPTS+=" -D ${!i}"
+ shift
+ if echo "x$1" | grep 'x?*=*' > /dev/null; then
+ ROS_CMAKEOPTS+=" -D $1"
else
usage
fi
;;
- -D?*=*)
- ROS_CMAKEOPTS+=" ${!i}"
+ -D?*=*|-D?*)
+ ROS_CMAKEOPTS+=" $1"
;;
makefiles|Makefiles)
CMAKE_GENERATOR="Unix Makefiles"
@@ -36,6 +36,8 @@
*)
usage
esac
+
+ shift
done
if [ "$REACTOS_SOURCE_DIR" = "$PWD" ]; then