forked from muxinc/mux-stats-sdk-avplayer
-
Notifications
You must be signed in to change notification settings - Fork 0
/
update-release-xcframeworks.sh
executable file
·30 lines (22 loc) · 2.11 KB
/
update-release-xcframeworks.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
BUILD_DIR=$PWD/MUXSDKStats/xc
PROJECT=$PWD/MUXSDKStats/MUXSDKStats.xcworkspace
TARGET_DIR=$PWD/XCFramework
# Delete the old stuff
rm -Rf $TARGET_DIR
# Make the build directory
mkdir -p $BUILD_DIR
# Make the target directory
mkdir -p $TARGET_DIR
################ Build MuxCore SDK
xcodebuild archive -scheme MUXSDKStatsTv -workspace $PROJECT -destination "generic/platform=tvOS" -archivePath "$BUILD_DIR/MUXSDKStatsTv.tvOS.xcarchive" SKIP_INSTALL=NO BUILD_LIBRARY_FOR_DISTRIBUTION=YES
xcodebuild archive -scheme MUXSDKStatsTv -workspace $PROJECT -destination "generic/platform=tvOS Simulator" -archivePath "$BUILD_DIR/MUXSDKStatsTv.tvOS-simulator.xcarchive" SKIP_INSTALL=NO BUILD_LIBRARY_FOR_DISTRIBUTION=YES
xcodebuild archive -scheme MUXSDKStats -workspace $PROJECT -destination "generic/platform=iOS" -archivePath "$BUILD_DIR/MUXSDKStats.iOS.xcarchive" SKIP_INSTALL=NO BUILD_LIBRARY_FOR_DISTRIBUTION=YES
xcodebuild archive -scheme MUXSDKStats -workspace $PROJECT -destination "generic/platform=iOS Simulator" -archivePath "$BUILD_DIR/MUXSDKStats.iOS-simulator.xcarchive" SKIP_INSTALL=NO BUILD_LIBRARY_FOR_DISTRIBUTION=YES
xcodebuild archive -scheme MUXSDKStats -workspace $PROJECT -destination "generic/platform=macOS,variant=Mac Catalyst" -archivePath "$BUILD_DIR/MUXSDKStats.macOS.xcarchive" SKIP_INSTALL=NO BUILD_LIBRARY_FOR_DISTRIBUTION=YES
xcodebuild -create-xcframework -framework "$BUILD_DIR/MUXSDKStatsTv.tvOS.xcarchive/Products/Library/Frameworks/MUXSDKStats.framework" \
-framework "$BUILD_DIR/MUXSDKStatsTv.tvOS-simulator.xcarchive/Products/Library/Frameworks/MUXSDKStats.framework" \
-framework "$BUILD_DIR/MUXSDKStats.iOS.xcarchive/Products/Library/Frameworks/MUXSDKStats.framework" \
-framework "$BUILD_DIR/MUXSDKStats.iOS-simulator.xcarchive/Products/Library/Frameworks/MUXSDKStats.framework" \
-framework "$BUILD_DIR/MUXSDKStats.macOS.xcarchive/Products/Library/Frameworks/MUXSDKStats.framework" \
-output "$TARGET_DIR/MUXSDKStats.xcframework"
rm -Rf $BUILD_DIR