-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.sh
More file actions
executable file
·15 lines (10 loc) · 854 Bytes
/
build.sh
File metadata and controls
executable file
·15 lines (10 loc) · 854 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
#!/bin/bash
# Prepare
DEPLOY_DIR='/tmp/xcframework_test'
rm -rf $DEPLOY_DIR
mkdir $DEPLOY_DIR
mkdir $DEPLOY_DIR/xcf
# Build fat binary
xcodebuild archive -scheme TestFramework -destination="iOS" -archivePath $DEPLOY_DIR/xcf/ios.xcarchive -derivedDataPath $DEPLOY_DIR/iphoneos -sdk iphoneos SKIP_INSTALL=NO BUILD_LIBRARY_FOR_DISTRIBUTION=YES
xcodebuild archive -scheme TestFramework -destination="iOS Simulator" -archivePath $DEPLOY_DIR/xcf/iossimulator.xcarchive -derivedDataPath $DEPLOY_DIR/iphoneos -sdk iphonesimulator SKIP_INSTALL=NO BUILD_LIBRARY_FOR_DISTRIBUTION=YES
xcodebuild -create-xcframework -framework $DEPLOY_DIR/xcf/ios.xcarchive/Products/Library/Frameworks/TestFramework.framework -framework $DEPLOY_DIR/xcf/iossimulator.xcarchive/Products/Library/Frameworks/TestFramework.framework -output $DEPLOY_DIR/xcf/TestFramework.xcframework