summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFranklin Wei <frankhwei536@gmail.com>2015-02-15 14:12:48 -0500
committerGerrit Rockbox <gerrit@rockbox.org>2015-02-15 21:03:36 +0100
commit74fc3efb60ed7844c8f7dbd0bd66f666e611dcfb (patch)
tree2f084497baa05843a7ceb0ce172d8e37a4daadf7
parent0f34c51522ba7cfe957aca8439dc82c7bb6920c7 (diff)
downloadrockbox-74fc3efb60ed7844c8f7dbd0bd66f666e611dcfb.tar.gz
rockbox-74fc3efb60ed7844c8f7dbd0bd66f666e611dcfb.tar.bz2
rockbox-74fc3efb60ed7844c8f7dbd0bd66f666e611dcfb.zip
Prevent configure from being run in the root of the tree, fix a typo in the configure script
Change-Id: I61205c2f00edbdcd726ca455a67c810fafe3ca92
-rwxr-xr-xtools/configure19
1 files changed, 18 insertions, 1 deletions
diff --git a/tools/configure b/tools/configure
index 2dd1bf3e12..13cd5995b2 100755
--- a/tools/configure
+++ b/tools/configure
@@ -1287,7 +1287,7 @@ fi
echo Using temporary directory $tmpdir
if test -r "configure"; then
- # this is a check for a configure script in the current directory, it there
+ # this is a check for a configure script in the current directory, if there
# is one, try to figure out if it is this one!
if { grep "^# Jukebox" configure >/dev/null 2>&1 ; } then
@@ -1304,6 +1304,23 @@ if test -r "configure"; then
fi
fi
+if test -r "tools/configure"; then
+ # this is a check for a configure script in the tools/ directory, if there
+ # is one, try to figure out if it is this one!
+
+ if { grep "^# Jukebox" tools/configure >/dev/null 2>&1 ; } then
+ echo "WEEEEEEEEP. Don't run this configure script in the root of the tree."
+ echo "It will only cause you pain and grief. Instead do this:"
+ echo ""
+ echo " mkdir build-dir"
+ echo " cd build-dir"
+ echo " ../tools/configure"
+ echo ""
+ echo "Much happiness will arise from this. Enjoy"
+ exit 5
+ fi
+fi
+
# get our current directory
pwd=`pwd`;