1.1 --- a/scripts/crosstool-NG.sh.in Tue Nov 20 16:59:17 2012 -0800
1.2 +++ b/scripts/crosstool-NG.sh.in Thu Jan 10 22:38:48 2013 +0100
1.3 @@ -25,6 +25,14 @@
1.4 . .config.2
1.5 # Yes! We can do full logging from now on!
1.6
1.7 +# Check running as root
1.8 +if [ -z "${CT_ALLOW_BUILD_AS_ROOT_SURE}" ]; then
1.9 + if [ $(id -u) -eq 1000 ]; then
1.10 + CT_DoLog ERROR "You must NOT be root to run crosstool-NG"
1.11 + exit 1
1.12 + fi
1.13 +fi
1.14 +
1.15 # If we want an interactive debug-shell, we must ensure these FDs
1.16 # are indeed connected to a terminal (and not redirected in any way).
1.17 if [ "${CT_DEBUG_INTERACTIVE}" = "y" -a ! \( -t 0 -a -t 6 -a -t 2 \) ]; then