From 62607c675367567b08545a04af5e99e268a5f091 Mon Sep 17 00:00:00 2001 From: Steve Brambilla Date: Mon, 20 Sep 2021 18:26:06 -0400 Subject: [PATCH] Build iphoneos binaries with full Bitcode --- build.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/build.sh b/build.sh index 9dc71d79c..4a207581d 100755 --- a/build.sh +++ b/build.sh @@ -6,14 +6,17 @@ PRODUCTS_DIR="${DERIVED_DATA_DIR}/Build/Products" # carthage adds these, not sure if necessary EXTRA_ARGS="ONLY_ACTIVE_ARCH=NO CODE_SIGNING_REQUIRED=NO CODE_SIGN_IDENTITY=" +# Embed bitcode for iphoneos binaries +EXTRA_IPHONEOS_ARGS="ENABLE_BITCODE=YES BITCODE_GENERATION_MODE=bitcode" + # libetpan has been set up to build an xcframework for libsasl2, however xcframeworks must exist at the *start* of the build process # I didn't have time to figure out something less awful than building libetpan first # It'll copy sasl.xcframework to the build directory -xcodebuild -project build-mac/mailcore2.xcodeproj -scheme "libetpan ios" -configuration Release -derivedDataPath ${DERIVED_DATA_DIR} -sdk iphoneos ${EXTRA_ARGS} +xcodebuild -project build-mac/mailcore2.xcodeproj -scheme "libetpan ios" -configuration Release -derivedDataPath ${DERIVED_DATA_DIR} -sdk iphoneos ${EXTRA_ARGS} ${EXTRA_IPHONEOS_ARGS} xcodebuild -project build-mac/mailcore2.xcodeproj -scheme "libetpan ios" -configuration Release -derivedDataPath ${DERIVED_DATA_DIR} -sdk iphonesimulator ${EXTRA_ARGS} # mailcore2 references the sasl.xcframework in the build directory -xcodebuild -project build-mac/mailcore2.xcodeproj -scheme "mailcore ios" -configuration Release -derivedDataPath ${DERIVED_DATA_DIR} -sdk iphoneos ${EXTRA_ARGS} +xcodebuild -project build-mac/mailcore2.xcodeproj -scheme "mailcore ios" -configuration Release -derivedDataPath ${DERIVED_DATA_DIR} -sdk iphoneos ${EXTRA_ARGS} ${EXTRA_IPHONEOS_ARGS} xcodebuild -project build-mac/mailcore2.xcodeproj -scheme "mailcore ios" -configuration Release -derivedDataPath ${DERIVED_DATA_DIR} -sdk iphonesimulator ${EXTRA_ARGS} # glue it all together