34 output_dir = os.path.abspath(location)
35 output_xcframework = os.path.join(output_dir,
'%s.xcframework' % name)
37 if not os.path.exists(output_dir):
38 os.makedirs(output_dir)
40 if os.path.exists(output_xcframework):
42 shutil.rmtree(output_xcframework)
46 command = [
'xcrun',
'xcodebuild',
'-quiet',
'-create-xcframework']
48 for framework
in frameworks:
49 command.extend([
'-framework', os.path.abspath(framework)])
51 command.extend([
'-output', output_xcframework])
53 subprocess.check_call(command, stdout=open(os.devnull,
'w'))