Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit aa3ea7e

Browse files
committed
Issue #17717: Pull NASM from svn.python.org for OpenSSL build.
1 parent c33a0cc commit aa3ea7e

4 files changed

Lines changed: 21 additions & 1 deletion

File tree

Misc/NEWS

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -126,6 +126,9 @@ Build
126126
Windows
127127
-------
128128

129+
- Issue #17717: The Windows build scripts now use a copy of NASM pulled from
130+
svn.python.org to build OpenSSL.
131+
129132
- Issue #22644: The bundled version of OpenSSL has been updated to 1.0.1j.
130133

131134
What's New in Python 3.4.2?

PCbuild/build_ssl.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -182,6 +182,17 @@ def main():
182182
if ssl_dir is None:
183183
sys.exit(1)
184184

185+
# add our copy of NASM to PATH. It will be on the same level as openssl
186+
for dir in os.listdir(os.path.join(ssl_dir, os.pardir)):
187+
if dir.startswith('nasm'):
188+
nasm_dir = os.path.join(ssl_dir, os.pardir, dir)
189+
nasm_dir = os.path.abspath(nasm_dir)
190+
os.environ['PATH'] += os.pathsep.join(['', nasm_dir])
191+
break
192+
else:
193+
print('NASM was not found, make sure it is on PATH')
194+
195+
185196
old_cd = os.getcwd()
186197
try:
187198
os.chdir(ssl_dir)

PCbuild/readme.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,9 @@ _ssl
182182
to be somewhere on your PATH. More recent versions of OpenSSL may
183183
need a later version of NASM. If OpenSSL's self tests don't pass,
184184
you should first try to update NASM and do a full rebuild of
185-
OpenSSL.
185+
OpenSSL. If you use the Tools\buildbot\external(-amd64).bat method
186+
for getting sources, it also downloads a version of NASM which the
187+
ssl build script will add to PATH.
186188

187189
If you like to use the official sources instead of the files from
188190
python.org's subversion repository, Perl is required to build the

Tools/buildbot/external-common.bat

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,10 @@ if not exist bzip2-1.0.6 (
2020
svn export http://svn.python.org/projects/external/bzip2-1.0.6
2121
)
2222

23+
@rem NASM, for OpenSSL build
24+
@rem if exist nasm-2.11.06 rd /s/q nasm-2.11.06
25+
if not exist nasm-2.11.06 svn export http://svn.python.org/projects/external/nasm-2.11.06
26+
2327
@rem OpenSSL
2428
if not exist openssl-1.0.1j (
2529
rd /s/q openssl-1.0.1i

0 commit comments

Comments
 (0)