diff options
author | Alex Hultman <alexhultman@localhost.localdomain> | 2016-08-05 04:36:40 +0200 |
---|---|---|
committer | Anna Henningsen <anna@addaleax.net> | 2016-08-08 15:15:48 +0200 |
commit | 359352c9e90aa735b61b37d080377970719b98ef (patch) | |
tree | 9750af54eb53e88de381b2d190f4f992d26e3cd7 /tools/mkssldef.py | |
parent | 8f90dcc1b8e4ac3d8597ea2ee3927f325cc980d3 (diff) | |
download | android-node-v8-359352c9e90aa735b61b37d080377970719b98ef.tar.gz android-node-v8-359352c9e90aa735b61b37d080377970719b98ef.tar.bz2 android-node-v8-359352c9e90aa735b61b37d080377970719b98ef.zip |
build: export zlib symbols on Windows
Base the generated openssl.def on existing zlib.def. We cannot specify
more than one DEF file per executable so we need to merge the two DEF
files to expose both OpenSSL and Zlib functionality to addons.
If OpenSSL is not used, link against zlib.def itself.
PR-URL: https://github.com/nodejs/node/pull/7983
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
Diffstat (limited to 'tools/mkssldef.py')
-rwxr-xr-x | tools/mkssldef.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tools/mkssldef.py b/tools/mkssldef.py index 8cbdbabd97..8354e5712e 100755 --- a/tools/mkssldef.py +++ b/tools/mkssldef.py @@ -7,6 +7,7 @@ import sys categories = [] defines = [] excludes = [] +bases = [] if __name__ == '__main__': out = sys.stdout @@ -18,6 +19,7 @@ if __name__ == '__main__': elif option.startswith('-C'): categories += option[2:].split(',') elif option.startswith('-D'): defines += option[2:].split(',') elif option.startswith('-X'): excludes += option[2:].split(',') + elif option.startswith('-B'): bases += option[2:].split(',') excludes = map(re.compile, excludes) exported = [] @@ -40,5 +42,12 @@ if __name__ == '__main__': if not satisfy(meta[3], categories): continue exported.append(name) + for filename in bases: + for line in open(filename).readlines(): + line = line.strip() + if line == 'EXPORTS': continue + if line[0] == ';': continue + exported.append(line) + print('EXPORTS', file=out) for name in sorted(exported): print(' ', name, file=out) |