MCPcopy Index your code
hub / github.com/emscripten-core/emsdk / llvm_build_bin_dir

Function llvm_build_bin_dir

emsdk.py:889–909  ·  view source on GitHub ↗
(tool)

Source from the content-addressed store, hash-verified

887# The directory where the binaries are produced. (relative to the installation
888# root directory of the tool)
889def llvm_build_bin_dir(tool):
890 build_dir = llvm_build_dir(tool)
891 if WINDOWS and 'Visual Studio' in CMAKE_GENERATOR:
892 old_llvm_bin_dir = os.path.join(build_dir, 'bin', decide_cmake_build_type(tool))
893
894 new_llvm_bin_dir = None
895 default_cmake_build_type = decide_cmake_build_type(tool)
896 cmake_build_types = [default_cmake_build_type, 'Release', 'RelWithDebInfo', 'MinSizeRel', 'Debug']
897 for build_type in cmake_build_types:
898 d = os.path.join(build_dir, build_type, 'bin')
899 if os.path.isfile(os.path.join(tool.installation_path(), d, exe_suffix('clang'))):
900 new_llvm_bin_dir = d
901 break
902
903 if new_llvm_bin_dir and os.path.exists(os.path.join(tool.installation_path(), new_llvm_bin_dir)):
904 return new_llvm_bin_dir
905 elif os.path.exists(os.path.join(tool.installation_path(), old_llvm_bin_dir)):
906 return old_llvm_bin_dir
907 return os.path.join(build_dir, default_cmake_build_type, 'bin')
908 else:
909 return os.path.join(build_dir, 'bin')
910
911
912def build_env():

Callers 1

expand_varsMethod · 0.85

Calls 4

llvm_build_dirFunction · 0.85
decide_cmake_build_typeFunction · 0.85
exe_suffixFunction · 0.85
installation_pathMethod · 0.80

Tested by

no test coverage detected