summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHirokazu Yamamoto <ocean-city@m2.ccsnet.ne.jp>2010-09-21 18:23:05 (GMT)
committerHirokazu Yamamoto <ocean-city@m2.ccsnet.ne.jp>2010-09-21 18:23:05 (GMT)
commit2f816e6a10d7a56a2e277d7f5b1b25aec5e6a71d (patch)
tree4c1d083ffacc9ff8480c32c37836eebb75bcf713
parent38425292fbb1811e78b02bbd190f6f4de75f6562 (diff)
downloadcpython-2f816e6a10d7a56a2e277d7f5b1b25aec5e6a71d.zip
cpython-2f816e6a10d7a56a2e277d7f5b1b25aec5e6a71d.tar.gz
cpython-2f816e6a10d7a56a2e277d7f5b1b25aec5e6a71d.tar.bz2
Issue #9552: Avoid unnecessary rebuild of OpenSSL. (Windows)
-rw-r--r--Misc/NEWS2
-rw-r--r--PC/VS8.0/build_ssl.py15
-rw-r--r--PCbuild/build_ssl.py12
3 files changed, 22 insertions, 7 deletions
diff --git a/Misc/NEWS b/Misc/NEWS
index d9f8a94..68403c6 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -222,6 +222,8 @@ Tests
Build
-----
+- Issue #9552: Avoid unnecessary rebuild of OpenSSL. (Windows)
+
- Issue #1633863: Don't ignore $CC under AIX.
- Issue #9810: Compile bzip2 source files in python's project file
diff --git a/PC/VS8.0/build_ssl.py b/PC/VS8.0/build_ssl.py
index 867fd4c..5a08a01 100644
--- a/PC/VS8.0/build_ssl.py
+++ b/PC/VS8.0/build_ssl.py
@@ -141,8 +141,8 @@ def fix_makefile(makefile):
fout.write(line)
def run_configure(configure, do_script):
- print("perl Configure "+configure)
- os.system("perl Configure "+configure)
+ print("perl Configure "+configure+" no-idea no-mdc2")
+ os.system("perl Configure "+configure+" no-idea no-mdc2")
print(do_script)
os.system(do_script)
@@ -161,12 +161,14 @@ def main():
do_script = "ms\\do_nasm"
makefile="ms\\nt.mak"
m32 = makefile
+ dirsuffix = "32"
elif sys.argv[2] == "x64":
arch="amd64"
configure = "VC-WIN64A"
do_script = "ms\\do_win64a"
makefile = "ms\\nt64.mak"
m32 = makefile.replace('64', '')
+ dirsuffix = "64"
#os.environ["VSEXTCOMP_USECL"] = "MS_OPTERON"
else:
raise ValueError(str(sys.argv))
@@ -223,6 +225,15 @@ def main():
shutil.copy(r"crypto\buildinf.h", r"crypto\buildinf_%s.h" % arch)
shutil.copy(r"crypto\opensslconf.h", r"crypto\opensslconf_%s.h" % arch)
+ # If the assembler files don't exist in tmpXX, copy them there
+ if perl is None:
+ if not os.path.exists("tmp"+dirsuffix):
+ os.mkdir("tmp"+dirsuffix)
+ for f in os.listdir("asm"+dirsuffix):
+ if not f.endswith(".asm"): continue
+ if os.path.isfile(r"tmp%s\%s" % (dirsuffix, f)): continue
+ shutil.copy(r"asm%s\%s" % (dirsuffix, f), "tmp"+dirsuffix)
+
# Now run make.
if arch == "amd64":
rc = os.system("ml64 -c -Foms\\uptable.obj ms\\uptable.asm")
diff --git a/PCbuild/build_ssl.py b/PCbuild/build_ssl.py
index a75c1fb..cfcb0ac 100644
--- a/PCbuild/build_ssl.py
+++ b/PCbuild/build_ssl.py
@@ -228,11 +228,13 @@ def main():
shutil.copy(r"crypto\opensslconf.h", r"crypto\opensslconf_%s.h" % arch)
# If the assembler files don't exist in tmpXX, copy them there
- if not os.path.exists("tmp"+dirsuffix):
- os.mkdir("tmp"+dirsuffix)
- for f in os.listdir("asm"+dirsuffix):
- if not f.endswith(".asm"): continue
- shutil.copy(r"asm%s\%s" % (dirsuffix, f), "tmp"+dirsuffix)
+ if perl is None:
+ if not os.path.exists("tmp"+dirsuffix):
+ os.mkdir("tmp"+dirsuffix)
+ for f in os.listdir("asm"+dirsuffix):
+ if not f.endswith(".asm"): continue
+ if os.path.isfile(r"tmp%s\%s" % (dirsuffix, f)): continue
+ shutil.copy(r"asm%s\%s" % (dirsuffix, f), "tmp"+dirsuffix)
# Now run make.
if arch == "amd64":