Max Metral
Max Metral

Reputation: 261

Detox build with react-native is failing because of GoogleUserMessagingPlatform?

I cannot get a once-working React-Native Detox build to work. The error seems to start with this:

PhaseScriptExecution [CP]\ Copy\ XCFrameworks /my-project/ios/build/Build/Intermediates.noindex/Pods.build/Release-iphonesimulator/GoogleUserMessagingPlatform.build/Script-75B045B5FA23A64D503F12601136A594.sh (in target 'GoogleUserMessagingPlatform' from project 'Pods')
    cd /my-project/ios/Pods
    /bin/sh -c /my-project/ios/build/Build/Intermediates.noindex/Pods.build/Release-iphonesimulator/GoogleUserMessagingPlatform.build/Script-75B045B5FA23A64D503F12601136A594.sh
warning: [CP] Unable to find matching .xcframework slice in '/my-project/ios/Pods/GoogleUserMessagingPlatform/Frameworks/Release/UserMessagingPlatform.xcframework UserMessagingPlatform framework ios-armv7_arm64_arm64e ios-i386_x86_64-simulator' for the current build architectures (arm64 x86_64).

And then towards the end fails with:

ld: warning: directory not found for option '-F/my-project/ios/build/Build/Products/Release-iphonesimulator/XCFrameworkIntermediates/UserMessagingPlatform'
ld: framework not found UserMessagingPlatform
clang: error: linker command failed with exit code 1 (use -v to see invocation)

I'm on latest of most things - 0.63.3 of RN, CocoaPods 1.10.0, XCode 12.1.

Upvotes: 1

Views: 1704

Answers (1)

Max Metral
Max Metral

Reputation: 261

For me, modifying the .detoxrc.json build command to include

EXCLUDED_ARCHS=arm64

ala

"build": "xcodebuild -workspace ios/MyProject.xcworkspace -scheme MyProject -configuration Release -sdk iphonesimulator -derivedDataPath ios/build EXCLUDED_ARCHS=arm64 DETOX=1",

Upvotes: 8

Related Questions