Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to Babylon Native master and fix many issues #608

Merged
merged 21 commits into from
Oct 3, 2023

Conversation

ryantrem
Copy link
Member

@ryantrem ryantrem commented Sep 29, 2023

Describe the change

This change updates to the Babylon Native master branch, and fixes many issues (build regressions, runtime regressions, and issues due to newer tooling).

  • Since dependencies are no longer submodules, but rather dynamically downloaded into the _deps folder, and since there is one _deps folder per platform and architecture, and since CMake was outputting to a source directory, we ended up in a situation where metro was picking up "duplicate" package.json files from all the _deps and erroring out. We don't want Metro picking up those package.json files anyway, and CMake should be outputting to a common Build directory, so it's been reconfigured to output to a Build directory from the repo root. This also required some other updates, like the xcworkspace files pulling in the generated Xcode project from a different folder.
  • There were build breaks in most versions of React Native with a recentish Xcode update. These were fixed in minor updates to the React Native releases, so I updated both 0.69 and 0.70 to slightly newer releases. See 'value' is unavailable: introduced in iOS 12.0 facebook/react-native#34106 (comment)
  • The podspecs were picking up ios/**/*.{h,m,mm}, which prior to the fix in bullet 1 were picking up tons of files from _deps. I fixed this by removing the ** before fixing bullet 1, but I'm going to leave it like this as it is safer anyway.
  • Napi::Attach is no longer templated, so fixed this.
  • glslang-default-resource-limits was an added dependency in BN, so it needed to be added here as well.
  • Updated gradle packagingOptions to exclude more files resulting in build breaks on Android (thanks @bghgary!).
  • Fixed an issue where fbJni installation at gradle sync time was failing (thanks @bghgary!).
  • Configure CMake iOS tool chain via cmake fetch since it is no longer a submodule.
  • Pulled in several fixes made to other repos along the way:
  • Added _deps link folders in Windows vcxproj and removed deprecated paths.
  • Disabled UnityBuild for UrlLib because of a conflict of headers.
  • Added glslang-default-resource-limit link library.
  • Explicitly set CMake Windows projects output to be VS2019 or CMake will use VS2022 when available and by default.
  • Disable warning in NativeCamera for unreachable code BabylonNative PR : Disable unreachable code warning BabylonNative#1302

Screenshots

N/A

Documentation

N/A

Testing

I've tested Android debug and iOS debug. Clang segfaults on my machine when compiling NativeInput.cpp in release in Xcode, so I could not test iOS release. Android crashes on launch in release, but it is very early in React Native specific code, so I don't think this is a result of updating BN. I did not test Windows at all.

@ryantrem ryantrem merged commit f87a9e9 into BabylonJS:master Oct 3, 2023
20 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants