Skip to content

Instantly share code, notes, and snippets.

@deszip
Created June 25, 2019 08:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save deszip/4332ca4574d2ab92d91f3253ddabd644 to your computer and use it in GitHub Desktop.
Save deszip/4332ca4574d2ab92d91f3253ddabd644 to your computer and use it in GitHub Desktop.
xcframework building
# Builds xcframework from iOS framework template project called TestFramework
# Archive for iOS
xcodebuild archive -scheme TestFramework -destination="iOS" -archivePath /tmp/xcf/ios.xcarchive -derivedDataPath /tmp/iphoneos -sdk iphoneos SKIP_INSTALL=NO BUILD_LIBRARY_FOR_DISTRIBUTION=YES
# Archive for simulator
xcodebuild archive -scheme TestFramework -destination="iOS Simulator" -archivePath /tmp/xcf/iossimulator.xcarchive -derivedDataPath /tmp/iphoneos -sdk iphonesimulator SKIP_INSTALL=NO BUILD_LIBRARY_FOR_DISTRIBUTION=YES
# Build xcframework with two archives
xcodebuild -create-xcframework -framework /tmp/xcf/ios.xcarchive/Products/Library/Frameworks/TestFramework.framework -framework /tmp/xcf/iossimulator.xcarchive/Products/Library/Frameworks/TestFramework.framework -output /tmp/xcf/TestFrame
work.xcframework
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment