Add Clang-16 to emsdk manifest, to allow bootstrapping a newer clang with an older clang.
diff --git a/emsdk.py b/emsdk.py index d7e8644..b088912 100644 --- a/emsdk.py +++ b/emsdk.py
@@ -1007,6 +1007,17 @@ cmdline += ['-DCMAKE_OSX_DEPLOYMENT_TARGET=11.0'] cmdline += [*extra_cmake_args, src_root] + # If we have a bootstrap compiler package installed, then use that compiler + # in the cmake build. + for ver in ['16.0.6', '15.0.7']: + bootstrap_compiler_path = os.path.abspath(f'llvm/{ver}/build_llvmorg-{ver}_64/bin') + bs_clang = os.path.join(bootstrap_compiler_path, 'clang') + bs_clangxx = os.path.join(bootstrap_compiler_path, 'clang++') + if os.path.isfile(bs_clang) and f'llvm/{ver}' not in build_root: + info(f'Using bootstrap compiler from {bs_clang} in CMake configure') + cmdline += [f'-DCMAKE_C_COMPILER={bs_clang}', f'-DCMAKE_CXX_COMPILER={bs_clangxx}'] + break + print(f'Running CMake: {cmdline}') # Specify the deployment target also as an env. var, since some Xcode versions
diff --git a/emsdk_manifest.json b/emsdk_manifest.json index 9992e7d..0b353b4 100644 --- a/emsdk_manifest.json +++ b/emsdk_manifest.json
@@ -30,6 +30,36 @@ }, { + "id": "llvm-git", + "version": "15.0.7", + "bitness": 64, + "install_path": "llvm/15.0.7", + "git_branch": "llvmorg-15.0.7", + "url": "https://github.com/llvm/llvm-project.git", + "custom_install_script": "build_llvm", + "only_supports_wasm": true, + "activated_path": "%installation_dir%/%llvm_build_bin_dir%", + "activated_cfg": "LLVM_ROOT='%installation_dir%/%llvm_build_bin_dir%'", + "activated_env": "LLVM_ROOT=%installation_dir%/%llvm_build_bin_dir%;EMCC_WASM_BACKEND=1", + "cmake_build_type": "Release" + }, + + { + "id": "llvm-git", + "version": "16.0.6", + "bitness": 64, + "install_path": "llvm/16.0.6", + "git_branch": "llvmorg-16.0.6", + "url": "https://github.com/llvm/llvm-project.git", + "custom_install_script": "build_llvm", + "only_supports_wasm": true, + "activated_path": "%installation_dir%/%llvm_build_bin_dir%", + "activated_cfg": "LLVM_ROOT='%installation_dir%/%llvm_build_bin_dir%'", + "activated_env": "LLVM_ROOT=%installation_dir%/%llvm_build_bin_dir%;EMCC_WASM_BACKEND=1", + "cmake_build_type": "Release" + }, + + { "id": "releases", "version": "%releases-tag%", "bitness": 64,