123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655 |
- import os
- import os.path
- import sys
- import re
- import glob
- import string
- import datetime
- import subprocess
- from compat import iteritems, isbasestring, decode_utf8
- def add_source_files(self, sources, filetype, lib_env=None, shared=False):
- if isbasestring(filetype):
- dir_path = self.Dir('.').abspath
- filetype = sorted(glob.glob(dir_path + "/" + filetype))
- for path in filetype:
- sources.append(self.Object(path))
- def disable_warnings(self):
-
- if self.msvc:
-
-
- warn_flags = ['/Wall', '/W4', '/W3', '/W2', '/W1', '/WX']
- self['CCFLAGS'] = [x for x in self['CCFLAGS'] if not x in warn_flags]
- self.Append(CCFLAGS=['/w'])
- else:
- self.Append(CCFLAGS=['-w'])
- def add_module_version_string(self,s):
- self.module_version_string += "." + s
- def update_version(module_version_string=""):
- build_name = "custom_build"
- if os.getenv("BUILD_NAME") != None:
- build_name = os.getenv("BUILD_NAME")
- print("Using custom build name: " + build_name)
- import version
-
- f = open("core/version_generated.gen.h", "w")
- f.write("#define VERSION_SHORT_NAME \"" + str(version.short_name) + "\"\n")
- f.write("#define VERSION_NAME \"" + str(version.name) + "\"\n")
- f.write("#define VERSION_MAJOR " + str(version.major) + "\n")
- f.write("#define VERSION_MINOR " + str(version.minor) + "\n")
- if hasattr(version, 'patch'):
- f.write("#define VERSION_PATCH " + str(version.patch) + "\n")
- f.write("#define VERSION_STATUS \"" + str(version.status) + "\"\n")
- f.write("#define VERSION_BUILD \"" + str(build_name) + "\"\n")
- f.write("#define VERSION_MODULE_CONFIG \"" + str(version.module_config) + module_version_string + "\"\n")
- f.write("#define VERSION_YEAR " + str(2018) + "\n")
- f.close()
-
- fhash = open("core/version_hash.gen.h", "w")
- githash = ""
- if os.path.isfile(".git/HEAD"):
- head = open(".git/HEAD", "r").readline().strip()
- if head.startswith("ref: "):
- head = ".git/" + head[5:]
- if os.path.isfile(head):
- githash = open(head, "r").readline().strip()
- else:
- githash = head
- fhash.write("#define VERSION_HASH \"" + githash + "\"")
- fhash.close()
- def parse_cg_file(fname, uniforms, sizes, conditionals):
- fs = open(fname, "r")
- line = fs.readline()
- while line:
- if re.match(r"^\s*uniform", line):
- res = re.match(r"uniform ([\d\w]*) ([\d\w]*)")
- type = res.groups(1)
- name = res.groups(2)
- uniforms.append(name)
- if type.find("texobj") != -1:
- sizes.append(1)
- else:
- t = re.match(r"float(\d)x(\d)", type)
- if t:
- sizes.append(int(t.groups(1)) * int(t.groups(2)))
- else:
- t = re.match(r"float(\d)", type)
- sizes.append(int(t.groups(1)))
- if line.find("[branch]") != -1:
- conditionals.append(name)
- line = fs.readline()
- fs.close()
- def detect_modules():
- module_list = []
- includes_cpp = ""
- register_cpp = ""
- unregister_cpp = ""
- files = glob.glob("modules/*")
- files.sort()
- for x in files:
- if not os.path.isdir(x):
- continue
- if not os.path.exists(x + "/config.py"):
- continue
- x = x.replace("modules/", "")
- x = x.replace("modules\\", "")
- module_list.append(x)
- try:
- with open("modules/" + x + "/register_types.h"):
- includes_cpp += '#include "modules/' + x + '/register_types.h"\n'
- register_cpp += '#ifdef MODULE_' + x.upper() + '_ENABLED\n'
- register_cpp += '\tregister_' + x + '_types();\n'
- register_cpp += '#endif\n'
- unregister_cpp += '#ifdef MODULE_' + x.upper() + '_ENABLED\n'
- unregister_cpp += '\tunregister_' + x + '_types();\n'
- unregister_cpp += '#endif\n'
- except IOError:
- pass
- modules_cpp = """
- // modules.cpp - THIS FILE IS GENERATED, DO NOT EDIT!!!!!!!
- #include "register_module_types.h"
- """ + includes_cpp + """
- void register_module_types() {
- """ + register_cpp + """
- }
- void unregister_module_types() {
- """ + unregister_cpp + """
- }
- """
-
- with open("modules/register_module_types.gen.cpp", "w") as f:
- f.write(modules_cpp)
- return module_list
- def win32_spawn(sh, escape, cmd, args, env):
- import subprocess
- newargs = ' '.join(args[1:])
- cmdline = cmd + " " + newargs
- startupinfo = subprocess.STARTUPINFO()
- for e in env:
- if type(env[e]) != type(""):
- env[e] = str(env[e])
- proc = subprocess.Popen(cmdline, stdin=subprocess.PIPE, stdout=subprocess.PIPE,
- stderr=subprocess.PIPE, startupinfo=startupinfo, shell=False, env=env)
- data, err = proc.communicate()
- rv = proc.wait()
- if rv:
- print("=====")
- print(err)
- print("=====")
- return rv
- """
- def win32_spawn(sh, escape, cmd, args, spawnenv):
- import win32file
- import win32event
- import win32process
- import win32security
- for var in spawnenv:
- spawnenv[var] = spawnenv[var].encode('ascii', 'replace')
- sAttrs = win32security.SECURITY_ATTRIBUTES()
- StartupInfo = win32process.STARTUPINFO()
- newargs = ' '.join(map(escape, args[1:]))
- cmdline = cmd + " " + newargs
- # check for any special operating system commands
- if cmd == 'del':
- for arg in args[1:]:
- win32file.DeleteFile(arg)
- exit_code = 0
- else:
- # otherwise execute the command.
- hProcess, hThread, dwPid, dwTid = win32process.CreateProcess(None, cmdline, None, None, 1, 0, spawnenv, None, StartupInfo)
- win32event.WaitForSingleObject(hProcess, win32event.INFINITE)
- exit_code = win32process.GetExitCodeProcess(hProcess)
- win32file.CloseHandle(hProcess);
- win32file.CloseHandle(hThread);
- return exit_code
- """
- def android_add_flat_dir(self, dir):
- if (dir not in self.android_flat_dirs):
- self.android_flat_dirs.append(dir)
- def android_add_maven_repository(self, url):
- if (url not in self.android_maven_repos):
- self.android_maven_repos.append(url)
- def android_add_dependency(self, depline):
- if (depline not in self.android_dependencies):
- self.android_dependencies.append(depline)
- def android_add_java_dir(self, subpath):
- base_path = self.Dir(".").abspath + "/modules/" + self.current_module + "/" + subpath
- if (base_path not in self.android_java_dirs):
- self.android_java_dirs.append(base_path)
- def android_add_res_dir(self, subpath):
- base_path = self.Dir(".").abspath + "/modules/" + self.current_module + "/" + subpath
- if (base_path not in self.android_res_dirs):
- self.android_res_dirs.append(base_path)
- def android_add_asset_dir(self, subpath):
- base_path = self.Dir(".").abspath + "/modules/" + self.current_module + "/" + subpath
- if (base_path not in self.android_asset_dirs):
- self.android_asset_dirs.append(base_path)
- def android_add_aidl_dir(self, subpath):
- base_path = self.Dir(".").abspath + "/modules/" + self.current_module + "/" + subpath
- if (base_path not in self.android_aidl_dirs):
- self.android_aidl_dirs.append(base_path)
- def android_add_jni_dir(self, subpath):
- base_path = self.Dir(".").abspath + "/modules/" + self.current_module + "/" + subpath
- if (base_path not in self.android_jni_dirs):
- self.android_jni_dirs.append(base_path)
- def android_add_gradle_plugin(self, plugin):
- if (plugin not in self.android_gradle_plugins):
- self.android_gradle_plugins.append(plugin)
- def android_add_gradle_classpath(self, classpath):
- if (classpath not in self.android_gradle_classpath):
- self.android_gradle_classpath.append(classpath)
- def android_add_default_config(self, config):
- if (config not in self.android_default_config):
- self.android_default_config.append(config)
- def android_add_to_manifest(self, file):
- base_path = self.Dir(".").abspath + "/modules/" + self.current_module + "/" + file
- with open(base_path, "r") as f:
- self.android_manifest_chunk += f.read()
- def android_add_to_permissions(self, file):
- base_path = self.Dir(".").abspath + "/modules/" + self.current_module + "/" + file
- with open(base_path, "r") as f:
- self.android_permission_chunk += f.read()
- def android_add_to_attributes(self, file):
- base_path = self.Dir(".").abspath + "/modules/" + self.current_module + "/" + file
- with open(base_path, "r") as f:
- self.android_appattributes_chunk += f.read()
- def disable_module(self):
- self.disabled_modules.append(self.current_module)
- def use_windows_spawn_fix(self, platform=None):
- if (os.name != "nt"):
- return
-
-
-
-
-
-
-
-
- self.Replace(ARFLAGS='q')
- def mySubProcess(cmdline, env):
- startupinfo = subprocess.STARTUPINFO()
- startupinfo.dwFlags |= subprocess.STARTF_USESHOWWINDOW
- proc = subprocess.Popen(cmdline, stdin=subprocess.PIPE, stdout=subprocess.PIPE,
- stderr=subprocess.PIPE, startupinfo=startupinfo, shell=False, env=env)
- data, err = proc.communicate()
- rv = proc.wait()
- if rv:
- print("=====")
- print(err)
- print("=====")
- return rv
- def mySpawn(sh, escape, cmd, args, env):
- newargs = ' '.join(args[1:])
- cmdline = cmd + " " + newargs
- rv = 0
- env = {str(key): str(value) for key, value in iteritems(env)}
- if len(cmdline) > 32000 and cmd.endswith("ar"):
- cmdline = cmd + " " + args[1] + " " + args[2] + " "
- for i in range(3, len(args)):
- rv = mySubProcess(cmdline + args[i], env)
- if rv:
- break
- else:
- rv = mySubProcess(cmdline, env)
- return rv
- self['SPAWN'] = mySpawn
- def split_lib(self, libname, src_list = None, env_lib = None):
- env = self
- num = 0
- cur_base = ""
- max_src = 64
- list = []
- lib_list = []
- if src_list is None:
- src_list = getattr(env, libname + "_sources")
- if type(env_lib) == type(None):
- env_lib = env
- for f in src_list:
- fname = ""
- if type(f) == type(""):
- fname = env.File(f).path
- else:
- fname = env.File(f)[0].path
- fname = fname.replace("\\", "/")
- base = string.join(fname.split("/")[:2], "/")
- if base != cur_base and len(list) > max_src:
- if num > 0:
- lib = env_lib.add_library(libname + str(num), list)
- lib_list.append(lib)
- list = []
- num = num + 1
- cur_base = base
- list.append(f)
- lib = env_lib.add_library(libname + str(num), list)
- lib_list.append(lib)
- if len(lib_list) > 0:
- if os.name == 'posix' and sys.platform == 'msys':
- env.Replace(ARFLAGS=['rcsT'])
- lib = env_lib.add_library(libname + "_collated", lib_list)
- lib_list = [lib]
- lib_base = []
- env_lib.add_source_files(lib_base, "*.cpp")
- lib = env_lib.add_library(libname, lib_base)
- lib_list.insert(0, lib)
- env.Prepend(LIBS=lib_list)
- def save_active_platforms(apnames, ap):
- for x in ap:
- names = ['logo']
- if os.path.isfile(x + "/run_icon.png"):
- names.append('run_icon')
- for name in names:
- pngf = open(x + "/" + name + ".png", "rb")
- b = pngf.read(1)
- str = " /* AUTOGENERATED FILE, DO NOT EDIT */ \n"
- str += " static const unsigned char _" + x[9:] + "_" + name + "[]={"
- while len(b) == 1:
- str += hex(ord(b))
- b = pngf.read(1)
- if (len(b) == 1):
- str += ","
- str += "};\n"
- pngf.close()
-
- wf = x + "/" + name + ".gen.h"
- with open(wf, "w") as pngw:
- pngw.write(str)
- def no_verbose(sys, env):
- colors = {}
-
-
- if sys.stdout.isatty():
- colors['cyan'] = '\033[96m'
- colors['purple'] = '\033[95m'
- colors['blue'] = '\033[94m'
- colors['green'] = '\033[92m'
- colors['yellow'] = '\033[93m'
- colors['red'] = '\033[91m'
- colors['end'] = '\033[0m'
- else:
- colors['cyan'] = ''
- colors['purple'] = ''
- colors['blue'] = ''
- colors['green'] = ''
- colors['yellow'] = ''
- colors['red'] = ''
- colors['end'] = ''
- compile_source_message = '%sCompiling %s==> %s$SOURCE%s' % (colors['blue'], colors['purple'], colors['yellow'], colors['end'])
- java_compile_source_message = '%sCompiling %s==> %s$SOURCE%s' % (colors['blue'], colors['purple'], colors['yellow'], colors['end'])
- compile_shared_source_message = '%sCompiling shared %s==> %s$SOURCE%s' % (colors['blue'], colors['purple'], colors['yellow'], colors['end'])
- link_program_message = '%sLinking Program %s==> %s$TARGET%s' % (colors['red'], colors['purple'], colors['yellow'], colors['end'])
- link_library_message = '%sLinking Static Library %s==> %s$TARGET%s' % (colors['red'], colors['purple'], colors['yellow'], colors['end'])
- ranlib_library_message = '%sRanlib Library %s==> %s$TARGET%s' % (colors['red'], colors['purple'], colors['yellow'], colors['end'])
- link_shared_library_message = '%sLinking Shared Library %s==> %s$TARGET%s' % (colors['red'], colors['purple'], colors['yellow'], colors['end'])
- java_library_message = '%sCreating Java Archive %s==> %s$TARGET%s' % (colors['red'], colors['purple'], colors['yellow'], colors['end'])
- env.Append(CXXCOMSTR=[compile_source_message])
- env.Append(CCCOMSTR=[compile_source_message])
- env.Append(SHCCCOMSTR=[compile_shared_source_message])
- env.Append(SHCXXCOMSTR=[compile_shared_source_message])
- env.Append(ARCOMSTR=[link_library_message])
- env.Append(RANLIBCOMSTR=[ranlib_library_message])
- env.Append(SHLINKCOMSTR=[link_shared_library_message])
- env.Append(LINKCOMSTR=[link_program_message])
- env.Append(JARCOMSTR=[java_library_message])
- env.Append(JAVACCOMSTR=[java_compile_source_message])
- def detect_visual_c_compiler_version(tools_env):
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- vc_chosen_compiler_index = -1
- vc_chosen_compiler_str = ""
-
- if 'VCINSTALLDIR' in tools_env:
-
-
-
- vc_amd64_compiler_detection_index = tools_env["PATH"].find(tools_env["VCINSTALLDIR"] + "BIN\\amd64;")
- if(vc_amd64_compiler_detection_index > -1):
- vc_chosen_compiler_index = vc_amd64_compiler_detection_index
- vc_chosen_compiler_str = "amd64"
- vc_amd64_x86_compiler_detection_index = tools_env["PATH"].find(tools_env["VCINSTALLDIR"] + "BIN\\amd64_x86;")
- if(vc_amd64_x86_compiler_detection_index > -1
- and (vc_chosen_compiler_index == -1
- or vc_chosen_compiler_index > vc_amd64_x86_compiler_detection_index)):
- vc_chosen_compiler_index = vc_amd64_x86_compiler_detection_index
- vc_chosen_compiler_str = "amd64_x86"
-
- vc_x86_compiler_detection_index = tools_env["PATH"].find(tools_env["VCINSTALLDIR"] + "BIN;")
- if(vc_x86_compiler_detection_index > -1
- and (vc_chosen_compiler_index == -1
- or vc_chosen_compiler_index > vc_x86_compiler_detection_index)):
- vc_chosen_compiler_index = vc_x86_compiler_detection_index
- vc_chosen_compiler_str = "x86"
- vc_x86_amd64_compiler_detection_index = tools_env["PATH"].find(tools_env['VCINSTALLDIR'] + "BIN\\x86_amd64;")
- if(vc_x86_amd64_compiler_detection_index > -1
- and (vc_chosen_compiler_index == -1
- or vc_chosen_compiler_index > vc_x86_amd64_compiler_detection_index)):
- vc_chosen_compiler_index = vc_x86_amd64_compiler_detection_index
- vc_chosen_compiler_str = "x86_amd64"
-
- if 'VCTOOLSINSTALLDIR' in tools_env:
-
- vc_amd64_compiler_detection_index = tools_env["PATH"].upper().find(tools_env['VCTOOLSINSTALLDIR'].upper() + "BIN\\HOSTX64\\X64;")
- if(vc_amd64_compiler_detection_index > -1):
- vc_chosen_compiler_index = vc_amd64_compiler_detection_index
- vc_chosen_compiler_str = "amd64"
- vc_amd64_x86_compiler_detection_index = tools_env["PATH"].upper().find(tools_env['VCTOOLSINSTALLDIR'].upper() + "BIN\\HOSTX64\\X86;")
- if(vc_amd64_x86_compiler_detection_index > -1
- and (vc_chosen_compiler_index == -1
- or vc_chosen_compiler_index > vc_amd64_x86_compiler_detection_index)):
- vc_chosen_compiler_index = vc_amd64_x86_compiler_detection_index
- vc_chosen_compiler_str = "amd64_x86"
- vc_x86_compiler_detection_index = tools_env["PATH"].upper().find(tools_env['VCTOOLSINSTALLDIR'].upper() + "BIN\\HOSTX86\\X86;")
- if(vc_x86_compiler_detection_index > -1
- and (vc_chosen_compiler_index == -1
- or vc_chosen_compiler_index > vc_x86_compiler_detection_index)):
- vc_chosen_compiler_index = vc_x86_compiler_detection_index
- vc_chosen_compiler_str = "x86"
- vc_x86_amd64_compiler_detection_index = tools_env["PATH"].upper().find(tools_env['VCTOOLSINSTALLDIR'].upper() + "BIN\\HOSTX86\\X64;")
- if(vc_x86_amd64_compiler_detection_index > -1
- and (vc_chosen_compiler_index == -1
- or vc_chosen_compiler_index > vc_x86_amd64_compiler_detection_index)):
- vc_chosen_compiler_index = vc_x86_amd64_compiler_detection_index
- vc_chosen_compiler_str = "x86_amd64"
- return vc_chosen_compiler_str
- def find_visual_c_batch_file(env):
- from SCons.Tool.MSCommon.vc import get_default_version, get_host_target, find_batch_file
- version = get_default_version(env)
- (host_platform, target_platform,req_target_platform) = get_host_target(env)
- return find_batch_file(env, version, host_platform, target_platform)[0]
- def generate_cpp_hint_file(filename):
- if os.path.isfile(filename):
-
- pass
- else:
- try:
- with open(filename, "w") as fd:
- fd.write("#define GDCLASS(m_class, m_inherits)\n")
- except IOError:
- print("Could not write cpp.hint file.")
- def generate_vs_project(env, num_jobs):
- batch_file = find_visual_c_batch_file(env)
- if batch_file:
- def build_commandline(commands):
- common_build_prefix = ['cmd /V /C set "plat=$(PlatformTarget)"',
- '(if "$(PlatformTarget)"=="x64" (set "plat=x86_amd64"))',
- 'set "tools=yes"',
- '(if "$(Configuration)"=="release" (set "tools=no"))',
- 'call "' + batch_file + '" !plat!']
- result = " ^& ".join(common_build_prefix + [commands])
- return result
- env.AddToVSProject(env.core_sources)
- env.AddToVSProject(env.main_sources)
- env.AddToVSProject(env.modules_sources)
- env.AddToVSProject(env.scene_sources)
- env.AddToVSProject(env.servers_sources)
- env.AddToVSProject(env.editor_sources)
-
-
-
-
- env['MSVSBUILDCOM'] = build_commandline('scons --directory="$(ProjectDir.TrimEnd(\'\\\'))" platform=windows progress=no target=$(Configuration) tools=!tools! -j' + str(num_jobs))
- env['MSVSREBUILDCOM'] = build_commandline('scons --directory="$(ProjectDir.TrimEnd(\'\\\'))" platform=windows progress=no target=$(Configuration) tools=!tools! vsproj=yes -j' + str(num_jobs))
- env['MSVSCLEANCOM'] = build_commandline('scons --directory="$(ProjectDir.TrimEnd(\'\\\'))" --clean platform=windows progress=no target=$(Configuration) tools=!tools! -j' + str(num_jobs))
-
-
-
- debug_variants = ['debug|Win32'] + ['debug|x64']
- release_variants = ['release|Win32'] + ['release|x64']
- release_debug_variants = ['release_debug|Win32'] + ['release_debug|x64']
- variants = debug_variants + release_variants + release_debug_variants
- debug_targets = ['bin\\godot.windows.tools.32.exe'] + ['bin\\godot.windows.tools.64.exe']
- release_targets = ['bin\\godot.windows.opt.32.exe'] + ['bin\\godot.windows.opt.64.exe']
- release_debug_targets = ['bin\\godot.windows.opt.tools.32.exe'] + ['bin\\godot.windows.opt.tools.64.exe']
- targets = debug_targets + release_targets + release_debug_targets
- if not env.get('MSVS'):
- env['MSVS']['PROJECTSUFFIX'] = '.vcxproj'
- env['MSVS']['SOLUTIONSUFFIX'] = '.sln'
- env.MSVSProject(
- target=['#godot' + env['MSVSPROJECTSUFFIX']],
- incs=env.vs_incs,
- srcs=env.vs_srcs,
- runfile=targets,
- buildtarget=targets,
- auto_build_solution=1,
- variant=variants)
- else:
- print("Could not locate Visual Studio batch file for setting up the build environment. Not generating VS project.")
- def precious_program(env, program, sources, **args):
- program = env.ProgramOriginal(program, sources, **args)
- env.Precious(program)
- return program
- def add_shared_library(env, name, sources, **args):
- library = env.SharedLibrary(name, sources, **args)
- env.NoCache(library)
- return library
- def add_library(env, name, sources, **args):
- library = env.Library(name, sources, **args)
- env.NoCache(library)
- return library
- def add_program(env, name, sources, **args):
- program = env.Program(name, sources, **args)
- env.NoCache(program)
- return program
- def CommandNoCache(env, target, sources, command, **args):
- result = env.Command(target, sources, command, **args)
- env.NoCache(result)
- return result
- def detect_darwin_sdk_path(platform, env):
- sdk_name = ''
- if platform == 'osx':
- sdk_name = 'macosx'
- var_name = 'MACOS_SDK_PATH'
- elif platform == 'iphone':
- sdk_name = 'iphoneos'
- var_name = 'IPHONESDK'
- elif platform == 'iphonesimulator':
- sdk_name = 'iphonesimulator'
- var_name = 'IPHONESDK'
- else:
- raise Exception("Invalid platform argument passed to detect_darwin_sdk_path")
- if not env[var_name]:
- try:
- sdk_path = decode_utf8(subprocess.check_output(['xcrun', '--sdk', sdk_name, '--show-sdk-path']).strip())
- if sdk_path:
- env[var_name] = sdk_path
- except (subprocess.CalledProcessError, OSError) as e:
- print("Failed to find SDK path while running xcrun --sdk {} --show-sdk-path.".format(sdk_name))
- raise
|