3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-06 17:44:08 +00:00

Fixed Windows distribution script.

This commit is contained in:
Christoph M. Wintersteiger 2016-11-15 08:59:18 -08:00
parent 6204f67d38
commit 014815a640

View file

@ -236,23 +236,9 @@ def mk_zip():
VS_RUNTIME_PATS = [re.compile('vcomp.*\.dll'),
re.compile('msvcp.*\.dll'),
re.compile('msvcr.*\.dll')]
VS_RUNTIME_FILES = []
def cp_vs_runtime_visitor(pattern, dir, files):
global VS_RUNTIME_FILES
for filename in files:
for pat in VS_RUNTIME_PATS:
if pat.match(filename):
if fnmatch(filename, pattern):
fname = os.path.join(dir, filename)
if not os.path.isdir(fname):
VS_RUNTIME_FILES.append(fname)
break
# Copy Visual Studio Runtime libraries
def cp_vs_runtime_core(x64):
global VS_RUNTIME_FILES
def cp_vs_runtime_core(x64):
if x64:
platform = "x64"
@ -261,7 +247,15 @@ def cp_vs_runtime_core(x64):
vcdir = os.environ['VCINSTALLDIR']
path = '%sredist\\%s' % (vcdir, platform)
VS_RUNTIME_FILES = []
os.walk(path, cp_vs_runtime_visitor, '*.dll')
for root, dirs, files in os.walk(path):
for filename in files:
if fnmatch(filename, '*.dll'):
for pat in VS_RUNTIME_PATS:
if pat.match(filename):
fname = os.path.join(root, filename)
if not os.path.isdir(fname):
VS_RUNTIME_FILES.append(fname)
bin_dist_path = os.path.join(DIST_DIR, get_dist_path(x64), 'bin')
for f in VS_RUNTIME_FILES:
shutil.copy(f, bin_dist_path)