From 340543a46a67280c80b88346c167996d763bbbac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jukka=20Jyl=C3=A4nki?= Date: Sun, 4 Oct 2015 21:31:23 -0700 Subject: [PATCH] Fix Emscripten optimizer build when both VS2013 and VS2015 are present and sufficiently new CMake is being used. Fix Emscripten optimizer build to be performed as 64-bit when current system is 64-bit. Fixes https://github.com/kripken/emscripten/issues/3814. --- emsdk | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/emsdk b/emsdk index db0def7..6cbe0fe 100755 --- a/emsdk +++ b/emsdk @@ -645,13 +645,14 @@ def build_optimizer_tool(tool): build_type = decide_cmake_build_type(tool) # Configure - success = cmake_configure(None, build_root, src_root, build_type) + cmake_generator = CMAKE_GENERATOR + if 'Visual Studio' in CMAKE_GENERATOR and tool.bitness == 64: + cmake_generator += ' Win64' + success = cmake_configure(cmake_generator, build_root, src_root, build_type) if not success: return False # Make -# TODO: Enable the following: -# success = make_build(build_root, build_type, 'x64' if tool.bitness == 64 else 'Win32') - success = make_build(build_root, build_type, 'Win32') + success = make_build(build_root, build_type, 'x64' if tool.bitness == 64 else 'Win32') return success def download_and_unzip(zipfile, dest_dir, download_even_if_exists=False, filename_prefix = ''):