Created
January 19, 2021 01:43
-
-
Save jerrans/df118b6e2c685606e034a4dac59e65c8 to your computer and use it in GitHub Desktop.
emsdk.py.patch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/emsdk.py b/emsdk.py | |
index 6d30c56..e2010bc 100644 | |
--- a/emsdk.py | |
+++ b/emsdk.py | |
@@ -1241,12 +1241,12 @@ def find_latest_installed_tool(name): | |
# npm install in Emscripten root directory | |
def emscripten_npm_install(tool, directory): | |
- node_tool = find_latest_installed_tool('node') | |
- if not node_tool: | |
- print('Failed to run "npm ci" in installed Emscripten root directory ' + tool.installation_path() + '! Please install node.js first!') | |
- return False | |
+ #node_tool = find_latest_installed_tool('node') | |
+ #if not node_tool: | |
+ # print('Failed to run "npm ci" in installed Emscripten root directory ' + tool.installation_path() + '! Please install node.js first!') | |
+ # return False | |
- node_path = os.path.join(node_tool.installation_path(), 'bin') | |
+ node_path = "" #os.path.join(node_tool.installation_path(), 'bin') | |
npm = os.path.join(node_path, 'npm' + ('.cmd' if WINDOWS else '')) | |
env = os.environ.copy() | |
env["PATH"] = node_path + os.pathsep + env["PATH"] | |
@@ -1705,6 +1705,8 @@ class Tool(object): | |
# installed for this tool to count as being installed. | |
if hasattr(self, 'uses'): | |
for tool_name in self.uses: | |
+ if tool_name == "node-12.18.1-64bit": | |
+ continue | |
tool = find_tool(tool_name) | |
if tool is None: | |
print("Manifest error: No tool by name '" + tool_name + "' found! This may indicate an internal SDK error!") | |
@@ -1845,6 +1847,10 @@ class Tool(object): | |
print("Installing SDK '" + str(self) + "'..") | |
for tool_name in self.uses: | |
+ if tool_name == "node-12.18.1-64bit": | |
+ continue | |
+ if tool_name == "python-3.7.4-2-64bit": | |
+ continue | |
tool = find_tool(tool_name) | |
if tool is None: | |
print("Manifest error: No tool by name '" + tool_name + "' found! This may indicate an internal SDK error!") |
./emsdk install sdk-upstream-master-64bit
./emsdk activate sdk-upstream-master-64bit
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This is for running emsdk on an arm64 Mac. It just skips the install requirement of the node/python tools and the check for the node tool when running npm.
The assumption is that you've installed the arm64 version of both python3 and node via brew so Emscripten can just use the system installed versions.