diff --git a/configure b/configure
index ab80b52989f8614f0c9128b5480275f81b0a4313..cd9a14e904b3c287be035902164df89b3475dd76 100755
--- a/configure
+++ b/configure
@@ -40,10 +40,9 @@ if "$WHICH" qmake-qt4 >/dev/null 2>&1 ; then
     cat >> "$makefile" <<EOF
 	cd ./src && qmake-qt4 -makefile -o Makefile src.pro && make
 EOF
-elif "$WHICH" qmake >/dev/null 2>&1 && [ UNAME_SYSTEM = "Darwin" ] ; then # Mac
+elif "$WHICH" qmake >/dev/null 2>&1 && [ "$UNAME_SYSTEM" = "Darwin" ] ; then # Mac
     cat >> "$makefile" <<EOF
-	cd src/ && qmake -spec macx-xcode src.pro && xcodebuild -project Makefile.xcode\
-        proj -configuration Debug clean build
+	cd src/ && qmake -spec macx-xcode src.pro && xcodebuild -project Makefile.xcode && proj -configuration Debug clean build
 EOF
 elif "$WHICH" qmake >/dev/null 2>&1 ; then
     cat >> "$makefile" <<EOF