diff options
author | Rod Vagg <rod@vagg.org> | 2015-06-14 13:23:43 +0300 |
---|---|---|
committer | Rod Vagg <rod@vagg.org> | 2015-06-25 12:17:58 +0300 |
commit | 628a3ab0930c8500483aa72a340e503cda41cf0b (patch) | |
tree | c2a3ab5cf634a1b30f7eeee7f80c378383dfe228 /tools/install.py | |
parent | 1f371e39880aee0fa81aa3bd6dd7bd032335a41b (diff) |
build: add tar-headers target for headers-only tar
to replace the full src download by node-gyp, using the proper format
instead of the full source format
PR-URL: https://github.com/nodejs/io.js/pull/1975
Reviewed-By: William Blankenship <william.jblankenship@gmail.com>
Reviewed-By: Johan Bergström <bugs@bergstroem.nu>
Diffstat (limited to 'tools/install.py')
-rwxr-xr-x | tools/install.py | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/tools/install.py b/tools/install.py index 8d76a14860d..4bacaadc4a9 100755 --- a/tools/install.py +++ b/tools/install.py @@ -156,6 +156,9 @@ def files(action): if 'true' == variables.get('node_install_npm'): npm_files(action) + headers(action) + +def headers(action): action([ 'common.gypi', 'config.gypi', @@ -178,7 +181,6 @@ def files(action): subdir_files('deps/openssl/config/archs', 'include/node/openssl/archs', action) action(['deps/openssl/config/opensslconf.h'], 'include/node/openssl/') - if 'false' == variables.get('node_shared_zlib'): action([ 'deps/zlib/zconf.h', @@ -207,8 +209,14 @@ def run(args): install_path = dst_dir + node_prefix + '/' cmd = args[1] if len(args) > 1 else 'install' - if cmd == 'install': return files(install) - if cmd == 'uninstall': return files(uninstall) + + if os.environ.get('HEADERS_ONLY'): + if cmd == 'install': return headers(install) + if cmd == 'uninstall': return headers(uninstall) + else: + if cmd == 'install': return files(install) + if cmd == 'uninstall': return files(uninstall) + raise RuntimeError('Bad command: %s\n' % cmd) if __name__ == '__main__': |