aboutsummaryrefslogtreecommitdiff
path: root/scripts/mkmakefile
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@woody.linux-foundation.org>2007-12-10 10:17:07 -0800
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-12-10 10:17:07 -0800
commitdc3d532a1792263ec9b26c1cbc7ce566056b5b1f (patch)
tree37592af93655cf34c9099761bfdcf52fc306d309 /scripts/mkmakefile
parentaf1bff4f1d117f99ad8a88e6532baff475fb44a5 (diff)
parent18c32dac75b187d1a4e858f3cfdf03e844129f5e (diff)
Merge git://git.kernel.org/pub/scm/linux/kernel/git/sam/fix-kbuild
* git://git.kernel.org/pub/scm/linux/kernel/git/sam/fix-kbuild: kbuild: fix building with O=.. options kbuild: fix building with redirected output.
Diffstat (limited to 'scripts/mkmakefile')
-rw-r--r--scripts/mkmakefile6
1 files changed, 6 insertions, 0 deletions
diff --git a/scripts/mkmakefile b/scripts/mkmakefile
index ee39facee15..9ad1bd79325 100644
--- a/scripts/mkmakefile
+++ b/scripts/mkmakefile
@@ -11,6 +11,12 @@
test ! -r $2/Makefile -o -O $2/Makefile || exit 0
+# Only overwrite automatically generated Makefiles
+# (so we do not overwrite kernel Makefile)
+if ! grep -q Automatically $2/Makefile
+then
+ exit 0
+fi
echo " GEN $2/Makefile"
cat << EOF > $2/Makefile