Mesa (master): scons: A less magic way of not building progs by default.

Jose Fonseca jrfonseca at kemper.freedesktop.org
Mon Feb 15 20:49:57 UTC 2010


Module: Mesa
Branch: master
Commit: 8c7d39cc8319864d43c4a8143d09cbc09c7371ff
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=8c7d39cc8319864d43c4a8143d09cbc09c7371ff

Author: José Fonseca <jfonseca at vmware.com>
Date:   Mon Feb 15 20:48:24 2010 +0000

scons: A less magic way of not building progs by default.

The problem with the old way is that passing 'progs/subdir' as argument
would fail.

---

 SConstruct |   13 +++++++------
 1 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/SConstruct b/SConstruct
index 964af7e..ea63b90 100644
--- a/SConstruct
+++ b/SConstruct
@@ -225,9 +225,10 @@ SConscript(
 	duplicate = 0 # http://www.scons.org/doc/0.97/HTML/scons-user/x2261.html
 )
 
-if 'progs' in COMMAND_LINE_TARGETS:
-    SConscript(
-        'progs/SConscript',
-        variant_dir = os.path.join('progs', env['build']),
-        duplicate = 0 # http://www.scons.org/doc/0.97/HTML/scons-user/x2261.html
-    )
+env.Default('src')
+
+SConscript(
+    'progs/SConscript',
+    variant_dir = os.path.join('progs', env['build']),
+    duplicate = 0 # http://www.scons.org/doc/0.97/HTML/scons-user/x2261.html
+)




More information about the mesa-commit mailing list