diff options
author | Dave Pacheco <dap@joyent.com> | 2012-03-28 10:26:10 -0700 |
---|---|---|
committer | Ben Noordhuis <info@bnoordhuis.nl> | 2012-04-01 00:14:36 +0000 |
commit | cc15299c32b4fc39c2eb2c08b0265e462f875544 (patch) | |
tree | 2e3c9b283e29e925b8ac4072d67671d164c218de /configure | |
parent | 7bdeed203991d35a56e7448540e3b74387c65d0d (diff) | |
download | node-cc15299c32b4fc39c2eb2c08b0265e462f875544.tar.gz |
build: add support for DTrace and postmortem
* fixes #2110
* includes V8 postmortem metadata in Solaris builds
* adds GYP support for DTrace probes and ustack helper
* ustack helper derives constants dynamically from libv8_base.a
* build with DTrace support by default on SunOS
Diffstat (limited to 'configure')
-rwxr-xr-x | configure | 18 |
1 files changed, 16 insertions, 2 deletions
@@ -108,7 +108,12 @@ parser.add_option("--shared-zlib-libname", parser.add_option("--with-dtrace", action="store_true", dest="with_dtrace", - help="Build with DTrace (experimental)") + help="Build with DTrace (default is true on supported systems)") + +parser.add_option("--without-dtrace", + action="store_true", + dest="without_dtrace", + help="Build without DTrace") # CHECKME does this still work with recent releases of V8? parser.add_option("--gdb", @@ -225,7 +230,6 @@ def gcc_version(): def configure_node(o): # TODO add gdb o['variables']['node_prefix'] = options.prefix if options.prefix else '' - o['variables']['node_use_dtrace'] = b(options.with_dtrace) o['variables']['node_install_npm'] = b(not options.without_npm) o['variables']['node_install_waf'] = b(not options.without_waf) o['variables']['host_arch'] = host_arch() @@ -242,6 +246,16 @@ def configure_node(o): if 'clang' not in CC and gcc_version() < [False, 4, 0, 0]: o['variables']['visibility'] = '' + # By default, enable DTrace on SunOS systems. Don't allow it on other + # systems, since it won't work. (The MacOS build process is different than + # SunOS, and we haven't implemented it.) + if sys.platform.startswith('sunos'): + o['variables']['node_use_dtrace'] = b(not options.without_dtrace); + elif b(options.with_dtrace) == 'true': + raise Exception('DTrace is currently only supported on SunOS systems.') + else: + o['variables']['node_use_dtrace'] = 'false' + def configure_libz(o): o['variables']['node_shared_zlib'] = b(options.shared_zlib) |