Remove logic build building native asm.js optimizer. NFC (#1325)
We no longer support building fastcomp-based SDKs
This commit is contained in:
57
emsdk.py
57
emsdk.py
@@ -1208,28 +1208,6 @@ cache_dir = %s
|
|||||||
return success
|
return success
|
||||||
|
|
||||||
|
|
||||||
# Emscripten asm.js optimizer build scripts:
|
|
||||||
def optimizer_build_root(tool):
|
|
||||||
build_root = tool.installation_path().strip()
|
|
||||||
if build_root.endswith('/') or build_root.endswith('\\'):
|
|
||||||
build_root = build_root[:-1]
|
|
||||||
generator_prefix = cmake_generator_prefix()
|
|
||||||
build_root = build_root + generator_prefix + '_' + str(tool.bitness) + 'bit_optimizer'
|
|
||||||
return build_root
|
|
||||||
|
|
||||||
|
|
||||||
def uninstall_optimizer(tool):
|
|
||||||
debug_print('uninstall_optimizer(' + str(tool) + ')')
|
|
||||||
build_root = optimizer_build_root(tool)
|
|
||||||
print("Deleting path '" + build_root + "'")
|
|
||||||
remove_tree(build_root)
|
|
||||||
|
|
||||||
|
|
||||||
def is_optimizer_installed(tool):
|
|
||||||
build_root = optimizer_build_root(tool)
|
|
||||||
return os.path.exists(build_root)
|
|
||||||
|
|
||||||
|
|
||||||
# Finds the newest installed version of a given tool
|
# Finds the newest installed version of a given tool
|
||||||
def find_latest_installed_tool(name):
|
def find_latest_installed_tool(name):
|
||||||
for t in reversed(tools):
|
for t in reversed(tools):
|
||||||
@@ -1330,29 +1308,6 @@ def emscripten_npm_install(tool, directory):
|
|||||||
return True
|
return True
|
||||||
|
|
||||||
|
|
||||||
def emscripten_post_install(tool):
|
|
||||||
debug_print('emscripten_post_install(' + str(tool) + ')')
|
|
||||||
src_root = os.path.join(tool.installation_path(), 'tools', 'optimizer')
|
|
||||||
build_root = optimizer_build_root(tool)
|
|
||||||
build_type = decide_cmake_build_type(tool)
|
|
||||||
|
|
||||||
# Configure
|
|
||||||
cmake_generator, args = get_generator_and_config_args(tool)
|
|
||||||
|
|
||||||
success = cmake_configure(cmake_generator, build_root, src_root, build_type, args)
|
|
||||||
if not success:
|
|
||||||
return False
|
|
||||||
|
|
||||||
# Make
|
|
||||||
success = make_build(build_root, build_type)
|
|
||||||
if not success:
|
|
||||||
return False
|
|
||||||
|
|
||||||
success = emscripten_npm_install(tool, tool.installation_path())
|
|
||||||
|
|
||||||
return True
|
|
||||||
|
|
||||||
|
|
||||||
# Binaryen build scripts:
|
# Binaryen build scripts:
|
||||||
def binaryen_build_root(tool):
|
def binaryen_build_root(tool):
|
||||||
build_root = tool.installation_path().strip()
|
build_root = tool.installation_path().strip()
|
||||||
@@ -1757,9 +1712,7 @@ class Tool(object):
|
|||||||
content_exists = False
|
content_exists = False
|
||||||
|
|
||||||
if hasattr(self, 'custom_is_installed_script'):
|
if hasattr(self, 'custom_is_installed_script'):
|
||||||
if self.custom_is_installed_script == 'is_optimizer_installed':
|
if self.custom_is_installed_script == 'is_binaryen_installed':
|
||||||
return is_optimizer_installed(self)
|
|
||||||
elif self.custom_is_installed_script == 'is_binaryen_installed':
|
|
||||||
return is_binaryen_installed(self)
|
return is_binaryen_installed(self)
|
||||||
else:
|
else:
|
||||||
raise Exception('Unknown custom_is_installed_script directive "' + self.custom_is_installed_script + '"!')
|
raise Exception('Unknown custom_is_installed_script directive "' + self.custom_is_installed_script + '"!')
|
||||||
@@ -1910,9 +1863,7 @@ class Tool(object):
|
|||||||
exit_with_error("installation failed!")
|
exit_with_error("installation failed!")
|
||||||
|
|
||||||
if hasattr(self, 'custom_install_script'):
|
if hasattr(self, 'custom_install_script'):
|
||||||
if self.custom_install_script == 'emscripten_post_install':
|
if self.custom_install_script == 'emscripten_npm_install':
|
||||||
success = emscripten_post_install(self)
|
|
||||||
elif self.custom_install_script == 'emscripten_npm_install':
|
|
||||||
success = emscripten_npm_install(self, self.installation_path())
|
success = emscripten_npm_install(self, self.installation_path())
|
||||||
elif self.custom_install_script in ('build_llvm', 'build_ninja', 'build_ccache'):
|
elif self.custom_install_script in ('build_llvm', 'build_ninja', 'build_ccache'):
|
||||||
# 'build_llvm' is a special one that does the download on its
|
# 'build_llvm' is a special one that does the download on its
|
||||||
@@ -1962,9 +1913,7 @@ class Tool(object):
|
|||||||
return
|
return
|
||||||
print("Uninstalling tool '" + str(self) + "'..")
|
print("Uninstalling tool '" + str(self) + "'..")
|
||||||
if hasattr(self, 'custom_uninstall_script'):
|
if hasattr(self, 'custom_uninstall_script'):
|
||||||
if self.custom_uninstall_script == 'uninstall_optimizer':
|
if self.custom_uninstall_script == 'uninstall_binaryen':
|
||||||
uninstall_optimizer(self)
|
|
||||||
elif self.custom_uninstall_script == 'uninstall_binaryen':
|
|
||||||
uninstall_binaryen(self)
|
uninstall_binaryen(self)
|
||||||
else:
|
else:
|
||||||
raise Exception('Unknown custom_uninstall_script directive "' + self.custom_uninstall_script + '"!')
|
raise Exception('Unknown custom_uninstall_script directive "' + self.custom_uninstall_script + '"!')
|
||||||
|
|||||||
@@ -479,13 +479,9 @@
|
|||||||
"windows_url": "https://github.com/emscripten-core/emscripten/archive/%tag%.zip",
|
"windows_url": "https://github.com/emscripten-core/emscripten/archive/%tag%.zip",
|
||||||
"unix_url": "https://github.com/emscripten-core/emscripten/archive/%tag%.tar.gz",
|
"unix_url": "https://github.com/emscripten-core/emscripten/archive/%tag%.tar.gz",
|
||||||
"download_prefix": "emscripten-e",
|
"download_prefix": "emscripten-e",
|
||||||
"activated_cfg": "EMSCRIPTEN_ROOT='%installation_dir%';EMSCRIPTEN_NATIVE_OPTIMIZER='%installation_dir%%generator_prefix%_32bit_optimizer/%cmake_build_type_on_win%optimizer%.exe%'",
|
"activated_cfg": "EMSCRIPTEN_ROOT='%installation_dir%'",
|
||||||
"activated_path": "%installation_dir%",
|
"activated_path": "%installation_dir%",
|
||||||
"activated_env": "EMSCRIPTEN=%installation_dir%;EMSCRIPTEN_NATIVE_OPTIMIZER=%installation_dir%%generator_prefix%_32bit_optimizer/%cmake_build_type_on_win%optimizer%.exe%",
|
"activated_env": "EMSCRIPTEN=%installation_dir%"
|
||||||
"cmake_build_type": "Release",
|
|
||||||
"custom_install_script": "emscripten_post_install",
|
|
||||||
"custom_is_installed_script": "is_optimizer_installed",
|
|
||||||
"custom_uninstall_script": "uninstall_optimizer"
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"id": "emscripten",
|
"id": "emscripten",
|
||||||
@@ -494,13 +490,9 @@
|
|||||||
"append_bitness": false,
|
"append_bitness": false,
|
||||||
"windows_url": "https://github.com/emscripten-core/emscripten/archive/%tag%.zip",
|
"windows_url": "https://github.com/emscripten-core/emscripten/archive/%tag%.zip",
|
||||||
"unix_url": "https://github.com/emscripten-core/emscripten/archive/%tag%.tar.gz",
|
"unix_url": "https://github.com/emscripten-core/emscripten/archive/%tag%.tar.gz",
|
||||||
"activated_cfg": "EMSCRIPTEN_ROOT='%installation_dir%';EMSCRIPTEN_NATIVE_OPTIMIZER='%installation_dir%%generator_prefix%_64bit_optimizer/%cmake_build_type_on_win%optimizer%.exe%'",
|
"activated_cfg": "EMSCRIPTEN_ROOT='%installation_dir%'",
|
||||||
"activated_path": "%installation_dir%",
|
"activated_path": "%installation_dir%",
|
||||||
"activated_env": "EMSCRIPTEN=%installation_dir%;EMSCRIPTEN_NATIVE_OPTIMIZER=%installation_dir%%generator_prefix%_64bit_optimizer/%cmake_build_type_on_win%optimizer%.exe%",
|
"activated_env": "EMSCRIPTEN=%installation_dir%"
|
||||||
"cmake_build_type": "Release",
|
|
||||||
"custom_install_script": "emscripten_post_install",
|
|
||||||
"custom_is_installed_script": "is_optimizer_installed",
|
|
||||||
"custom_uninstall_script": "uninstall_optimizer"
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"id": "emscripten",
|
"id": "emscripten",
|
||||||
|
|||||||
Reference in New Issue
Block a user