changeset 108:7f3a91323a88

If 'setup.py build --debug' is run and a spidermonkey build doesn't exist, then spidermonkey is built with debugging enabled.
author Atul Varma <varmaa@toolness.com>
date Sun, 16 Aug 2009 13:37:13 -0700
parents e6c6bf209444
children 204cac15c06a
files setup.py
diffstat 1 files changed, 7 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/setup.py	Sun Aug 16 13:21:39 2009 -0700
+++ b/setup.py	Sun Aug 16 13:37:13 2009 -0700
@@ -143,9 +143,13 @@
 
         configure = os.path.join(SPIDERMONKEY_DIR, "js", "src",
                                  "configure")
-        retval = subprocess.call([configure,
-                                  "--enable-static",
-                                  "--disable-tests"],
+        cmdline = [configure,
+                   "--enable-static",
+                   "--disable-tests"]
+        if options.get("build") and options.build.get("debug"):
+            cmdline.extend(["--enable-debug",
+                            "--enable-gczeal"])
+        retval = subprocess.call(cmdline,
                                  cwd = SPIDERMONKEY_OBJDIR)
         if retval:
             sys.exit(retval)