You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Fix hardcoded ARCore AAR path to honor resolutionStrategy.force
The -DARCORE_LIBPATH cmake argument was hardcoded to core-1.22.0.aar in
Modules/@babylonjs/react-native/android/build.gradle. If a consumer project
applies a resolutionStrategy.force on com.google.ar:core (for example to
resolve a duplicate-class conflict between core:1.22.0 and
installreferrer:2.2 by forcing core:1.26.0), Gradle extracts the AAR into
core-1.26.0.aar/jni while the native build still looks for
core-1.22.0.aar/jni, failing with: 'libarcore_sdk_c.so missing and no
known rule to make it'.
Resolve the actual extracted AAR via configurations.extractLibs and rewrite
the -DARCORE_LIBPATH cmake argument to match the resolved version, with a
graceful fallback to core-1.22.0.aar if resolution fails.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Allow consumer to override iOS deployment target for generated Xcode project
ios/CMakeLists.txt hardcoded the iOS deployment target to 12 in two places:
- set(DEPLOYMENT_TARGET "12" CACHE STRING "") (line 12, consumed by the
leetal/ios-cmake toolchain to set CMAKE_OSX_DEPLOYMENT_TARGET)
- XCODE_ATTRIBUTE_IPHONEOS_DEPLOYMENT_TARGET 12.0 on the BabylonNative target
Xcode 26's Clang crashes compiling DeviceImpl_iOS.mm against iOS 12, so
projects targeting iOS 16+ had to patch the deployment target from their
Podfile post_install hook.
Plumb a new BABYLON_IOS_DEPLOYMENT_TARGET environment variable from
postinstall.js into the CMake invocation (as -DDEPLOYMENT_TARGET=<value>)
and have CMakeLists.txt honour, in order: an explicit -DDEPLOYMENT_TARGET=,
the BABYLON_IOS_DEPLOYMENT_TARGET env var, then the historical 12 default.
Both DEPLOYMENT_TARGET and XCODE_ATTRIBUTE_IPHONEOS_DEPLOYMENT_TARGET now use
the resolved value, so the generated ReactNativeBabylon.xcodeproj matches
the consuming app's Podfile platform :ios setting without manual patching.
Documented in README.md alongside BABYLON_NO_CMAKE_POSTINSTALL and
BABYLON_USE_SYSTEM_CMAKE.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Bump iOS minimum/default deployment target from 12 to 16
iOS 12 is no longer a viable minimum: Xcode 26's Clang crashes while
compiling DeviceImpl_iOS.mm against the iOS 12 SDK, so consumers were
forced to override the deployment target via Podfile post_install or via
the BABYLON_IOS_DEPLOYMENT_TARGET env var introduced in the previous
commit. Bump the default everywhere so unmodified consumer projects work
out of the box on Xcode 26+:
- ios/CMakeLists.txt: DEPLOYMENT_TARGET default 12 -> 16 (still
overridable via -DDEPLOYMENT_TARGET= or BABYLON_IOS_DEPLOYMENT_TARGET).
- react-native-babylon.podspec: s.platforms ios 12.0 -> 16.0 so
CocoaPods enforces the new minimum on consuming apps.
- postinstall.js: update comment to reflect the new default.
- README.md: update iOS configuration section and the
BABYLON_IOS_DEPLOYMENT_TARGET docs.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Make com.google.ar:core version configurable via ext.arcoreVersion
Both the implementation and �xtractLibs dependency declarations
hardcoded com.google.ar:core:1.22.0. In practice this is harmless because
Gradle's normal conflict resolution and any consumer-side
resolutionStrategy.force on com.google.ar:core override the declared
version, but it forced every consumer that wants a newer ARCore (e.g. to
resolve the duplicate-class conflict between core:1.22 and
installreferrer:2.2 requiring core:1.26+) to add a resolutionStrategy.force
AND remember to keep the native build's ARCORE_LIBPATH in sync.
Expose the ARCore version as a Gradle ext property using the existing
safeExtGet helper, defaulting to 1.22.0 for backwards compatibility:
ext.arcoreVersion = '1.26.0' // in the consumer's root build.gradle
Use the variable in both implementation and �xtractLibs, in the cmake
ARCORE_LIBPATH default, and in the dynamic-resolution fallback. The
dynamic resolution (added previously) still picks up the actually-extracted
AAR when a resolutionStrategy.force overrides the declared version, so
both override mechanisms continue to work.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Slim ARCore AAR resolution to match proposed pattern
Drop the defensive scaffolding (try/catch, group filter, manual index
loop with not-found fallback, status logger.warn) and use List.replaceAll
for the cmake-args mutation. Behaviour is unchanged: still resolves the
extractLibs configuration after the dependencies block (necessary because
the android { } block evaluates cmake.arguments before the dependencies
are declared further down in the script) and rewrites -DARCORE_LIBPATH to
match the actually-extracted AAR.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Bump Playground iOS deployment target to 16.0
The @babylonjs/react-native podspec declares an iOS 16 minimum (matching the CMake-generated framework's default deployment target). The test app's Podfile relied on react-native-test-app's lower default, which caused 'pod install' to reject the local pod with Specs satisfying the react-native-babylon dependency were found, but they required a higher minimum deployment target.' Set the Podfile's platform explicitly to keep CI's Pods install in sync with the pod's minimum.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copy file name to clipboardExpand all lines: Modules/@babylonjs/react-native/README.md
+7-1Lines changed: 7 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -16,7 +16,7 @@ The minimum Android SDK version is 21. This must be set as `minSdkVersion` in th
16
16
17
17
### iOS Configuration
18
18
19
-
The minimum deployment target version is 12. This must be set as `iOS Deployment Target` in the consuming project's `project.pbxproj`, and must also be set as `platform` in the consuming project's `Podfile`.
19
+
The minimum deployment target version is 16. This must be set as `iOS Deployment Target` in the consuming project's `project.pbxproj`, and must also be set as `platform` in the consuming project's `Podfile`.
20
20
Make sure `pod install` is called from the ios folder after npm install.
21
21
22
22
#### Workspace
@@ -39,6 +39,12 @@ To use the system cmake (e.g. a Homebrew or system install) instead of the cmake
39
39
export BABYLON_USE_SYSTEM_CMAKE=1
40
40
```
41
41
42
+
To override the iOS deployment target used by the generated `ReactNativeBabylon.xcodeproj` (defaults to `16.0`), set this variable before running `npm install` so it matches your app's Podfile `platform :ios` value:
43
+
```
44
+
export BABYLON_IOS_DEPLOYMENT_TARGET=16.0
45
+
```
46
+
The previous default of iOS 12 caused Xcode 26's Clang to crash while compiling `DeviceImpl_iOS.mm`; the default is now `16.0` and this variable lets you raise it further (or, at your own risk, lower it) without patching the deployment target from a Podfile `post_install` hook.
47
+
42
48
### Plugins selection
43
49
44
50
Plugins can be disabled at build time. They are all enabled by default and disabling is done with environment variables:
0 commit comments