diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8c888d7..5b0ec08 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -184,14 +184,28 @@ jobs: - name: Build for the simulator working-directory: examples/bare/ios run: | + # CODE_SIGNING_ALLOWED=NO leaves a linker-signed slice the simulator + # keychain rejects with errSecMissingEntitlement (-34018) on + # bugseeDeviceId; capture then never reaches Launched. Ad-hoc sign + # instead: no Apple ID, but enough for SecItemAdd on the simulator. xcodebuild \ -workspace BareExample.xcworkspace \ -scheme BareExample \ -destination "id=${{ steps.sim.outputs.udid }}" \ -configuration Debug \ -derivedDataPath build \ - CODE_SIGNING_ALLOWED=NO \ + CODE_SIGNING_ALLOWED=YES \ + CODE_SIGN_IDENTITY=- \ + CODE_SIGNING_REQUIRED=NO \ build + APP=build/Build/Products/Debug-iphonesimulator/BareExample.app + if [ -d "$APP/Frameworks" ]; then + find "$APP/Frameworks" -depth \( -name "*.framework" -o -name "*.dylib" \) -print0 \ + | while IFS= read -r -d '' item; do + codesign --force --sign - --timestamp=none "$item" + done + fi + codesign --force --sign - --timestamp=none "$APP" - name: Install the app run: | diff --git a/examples/bare/ios/BareExample.xcodeproj/project.pbxproj b/examples/bare/ios/BareExample.xcodeproj/project.pbxproj index decbca0..cae2685 100644 --- a/examples/bare/ios/BareExample.xcodeproj/project.pbxproj +++ b/examples/bare/ios/BareExample.xcodeproj/project.pbxproj @@ -259,6 +259,7 @@ buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CLANG_ENABLE_MODULES = YES; + "CODE_SIGN_IDENTITY[sdk=iphonesimulator*]" = "-"; CURRENT_PROJECT_VERSION = 1; ENABLE_BITCODE = NO; INFOPLIST_FILE = BareExample/Info.plist; @@ -289,6 +290,7 @@ buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CLANG_ENABLE_MODULES = YES; + "CODE_SIGN_IDENTITY[sdk=iphonesimulator*]" = "-"; CURRENT_PROJECT_VERSION = 1; INFOPLIST_FILE = BareExample/Info.plist; IPHONEOS_DEPLOYMENT_TARGET = 15.1;