Skip to content

Commit a587f34

Browse files
authored
Merge pull request mendix#9021 from mendix/bitcode-limitation-workaround
Bitcode Limitation and Workaround
2 parents 30f88cd + 47112ad commit a587f34

3 files changed

Lines changed: 48 additions & 0 deletions

File tree

content/en/docs/refguide/mobile/distributing-mobile-apps/building-native-apps/_index.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,12 @@ Building mobile apps with App Center is deprecated and will be removed on March
2525
* [Native Template](/refguide/mobile/distributing-mobile-apps/building-native-apps/native-template/) – The Native Template describes the native dependencies your app needs, and it includes two native apps (one for iOS and one for Android) that can be independently built to create the finished apps.
2626
* [Build a Mendix Native App with Bitrise](/refguide/mobile/distributing-mobile-apps/building-native-apps/bitrise/) – This guide explains how to set up Bitrise to build a Mendix native mobile app.
2727

28+
{{% alert color="info" %}}
29+
The React Native version used in Studio Pro versions 10.11-10.16 includes Bitcode, which is not longer supported by Xcode 16 and above. This means that native mobile iOS applications created by customers **cannot be submitted to the App Store**.
30+
31+
For more information and workarounds, see [Bitcode Deprecation](/refguide/mobile/introduction-to-mobile-technologies/native-mobile/#bitcode-deprecation).
32+
{{% /alert %}}
33+
2834
{{% alert color="info" %}}
2935
The Mendix Native Mobile Builder does not currently support connections behind proxy servers. Please make sure you are not behind a proxy server and that your security rules allow access to the required services. For more information, see the [Firewall Settings](/refguide/system-requirements/#firewall-settings) section of System Requirements.
3036
{{% /alert %}}

content/en/docs/refguide/mobile/distributing-mobile-apps/building-native-apps/bitrise.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,12 @@ description: Describes how to integrate with Bitrise to build a Mendix native ap
99

1010
This guide helps you set up [Bitrise](https://bitrise.io) to automate building a Mendix native app in the cloud. Bitrise is a popular continuous integration service optimized for mobile apps.
1111

12+
{{% alert color="info" %}}
13+
The React Native version used in Studio Pro versions 10.11-10.16 includes Bitcode, which is not longer supported by Xcode 16 and above. This means that native mobile iOS applications created by customers **cannot be submitted to the App Store**.
14+
15+
For more information and workarounds, see [Bitcode Deprecation](/refguide/mobile/introduction-to-mobile-technologies/native-mobile/#bitcode-deprecation).
16+
{{% /alert %}}
17+
1218
## Prerequisites {#prerequisites}
1319

1420
Before starting this guide, make sure you have completed the following prerequisites:

content/en/docs/refguide/mobile/introduction-to-mobile-technologies/native-mobile.md

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,3 +24,39 @@ Native mobile apps have full access to all of the device's capabilities. Many ca
2424
## Distribution
2525

2626
Native mobile apps must be distribute via AppStores. Updates can be distributed with Over-the-Air Updates.
27+
28+
## Limitations
29+
30+
### Bitcode Deprecation {#bitcode-deprecation}
31+
32+
The React Native version used in Studio Pro versions 10.11-10.16 includes Bitcode, which is not longer supported by Xcode 16 and above. This means that native mobile iOS applications created by customers **cannot be submitted to the App Store**.
33+
34+
To address the issue, there are one of three things you can do:
35+
36+
* Use a newer version of Studio Pro (10.18+)
37+
* Use the workaround [below](#bitcode-workaround)
38+
* Downgrade Xcode to version 15.4 (although it does not work on latest MacOS version)
39+
40+
#### Workaround {#bitcode-workaround}
41+
42+
Apply the following changes to the native mobile project in "ios/Podfile" file in the "post_install" block (ref https://stackoverflow.com/questions/79022303/asset-validation-failed-nslocalizedrecoverysuggestion-invalid-executable-the-e/79022687):
43+
44+
```
45+
bitcode_strip_path = `xcrun --find bitcode_strip`.chop!
46+
def strip_bitcode_from_framework(bitcode_strip_path, framework_relative_path)
47+
framework_path = File.join(Dir.pwd, framework_relative_path)
48+
command = "#{bitcode_strip_path} #{framework_path} -r -o #{framework_path}"
49+
puts "Stripping bitcode: #{command}"
50+
system(command)
51+
end
52+
framework_paths = [
53+
"Pods/LogRocket/LogRocket.xcframework/ios-arm64/LogRocket.framework/LogRocket",
54+
"Pods/hermes-engine/destroot/Library/Frameworks/macosx/hermes.framework/hermes",
55+
"Pods/hermes-engine/destroot/Library/Frameworks/macosx/hermes.framework/Versions/Current/hermes",
56+
"Pods/hermes-engine/destroot/Library/Frameworks/universal/hermes.xcframework/ios-arm64/hermes.framework/hermes",
57+
"Pods/hermes-engine/destroot/Library/Frameworks/universal/hermes.xcframework/ios-arm64_x86_64-maccatalyst/hermes.framework/hermes"
58+
]
59+
framework_paths.each do |framework_relative_path|
60+
strip_bitcode_from_framework(bitcode_strip_path, framework_relative_path)
61+
end
62+
```

0 commit comments

Comments
 (0)