Repository navigation
Xcode 26.4b1/b2/b3/RC • FMT Compile Errors (it needs upgrading) • REPRO **IS** included despite the erroneous label #55601
Copy link
Copy link
Closed
bluesky-social/social-app
#10136Labels
Needs: AttentionIssues where the author has responded to feedback.Issues where the author has responded to feedback.Needs: ReproThis issue could be improved with a clear list of steps to reproduce the issue.This issue could be improved with a clear list of steps to reproduce the issue.
Description
Description
FMT needs upgrading so that it will compile with Xcode 26.4b1.
I modified the FMT and RCT-Folly pod specs to use 12.1.0 and the compilation succeeded.
I am not 100% sure but I'm suspecting this fmtlib/fmt#4065 may be the fix for the problem.
We currently depend on the legacy architecture so would be hoping this fix would qualify for an 0.81.x release.
NOTE: I did not need to fork the reproducer or use as a template because no changes were required to produce the problem.
Steps to reproduce
npm installcd ReproducerApp/iospod installDEVELOPER_DIR=/Applications/Xcode\ 26.4b1.app/Contents/Developer/ xed .- Select the simulator and build
React Native Version
0.83.1
Affected Platforms
Build - MacOS
Output of npx @react-native-community/cli info
brettbest@Bretts-MacBook-Pro ~/D/r/ReproducerApp (main)> DEVELOPER_DIR=/Applications/Xcode\ 26.4b1.app/Contents/Developer/ npx @react-native-community/cli info
info Fetching system and libraries information...
System:
OS: macOS 26.4
CPU: (12) arm64 Apple M2 Pro
Memory: 144.23 MB / 16.00 GB
Shell:
version: "5.9"
path: /bin/zsh
Binaries:
Node:
version: 24.13.0
path: /Users/brettbest/.local/share/mise/installs/node/24.13.0/bin/node
Yarn:
version: 1.22.22
path: /opt/homebrew/bin/yarn
npm:
version: 11.6.2
path: /Users/brettbest/.local/share/mise/installs/node/24.13.0/bin/npm
Watchman:
version: 2026.01.12.00
path: /opt/homebrew/bin/watchman
Managers:
CocoaPods:
version: 1.16.2
path: /opt/homebrew/bin/pod
SDKs:
iOS SDK:
Platforms:
- DriverKit 25.4
- iOS 26.4
- macOS 26.4
- tvOS 26.4
- visionOS 26.4
- watchOS 26.4
Android SDK: Not Found
IDEs:
Android Studio: Not Found
Xcode:
version: 26.4/17E5159k
path: /usr/bin/xcodebuild
Languages:
Java:
version: 25.0.2
path: /opt/homebrew/opt/openjdk/bin/javac
Ruby:
version: 3.3.0
path: /Users/brettbest/.local/share/mise/installs/ruby/3.3.0/bin/ruby
npmPackages:
"@react-native-community/cli":
installed: 20.0.0
wanted: 20.0.0
react:
installed: 19.2.0
wanted: 19.2.0
react-native:
installed: 0.83.1
wanted: 0.83.1
react-native-macos: Not Found
npmGlobalPackages:
"*react-native*": Not Found
Android:
hermesEnabled: true
newArchEnabled: true
iOS:
hermesEnabled: true
newArchEnabled: true
info React Native v0.84.0 is now available (your project is running on v0.83.1).
info Changelog: https://github.com/facebook/react-native/releases/tag/v0.84.0
info Diff: https://react-native-community.github.io/upgrade-helper/?from=0.83.1&to=0.84.0
info For more info, check out "https://reactnative.dev/docs/upgrading?os=macos".
Stacktrace or Logs
/Users/brettbest/Developer/reproducer-react-native/ReproducerApp/ios/Pods/fmt/include/fmt/format-inl.h:59:24 Call to consteval function 'fmt::basic_format_string<char, fmt::basic_string_view<char> &, const char (&)[3]>::basic_format_string<FMT_COMPILE_STRING, 0>' is not a constant expression
/Users/brettbest/Developer/reproducer-react-native/ReproducerApp/ios/Pods/fmt/include/fmt/format-inl.h:60:22 Call to consteval function 'fmt::basic_format_string<char, const char (&)[7], int &>::basic_format_string<FMT_COMPILE_STRING, 0>' is not a constant expression
/Users/brettbest/Developer/reproducer-react-native/ReproducerApp/ios/Pods/fmt/include/fmt/format-inl.h:1387:35 Call to consteval function 'fmt::basic_format_string<char, unsigned int &>::basic_format_string<FMT_COMPILE_STRING, 0>' is not a constant expression
/Users/brettbest/Developer/reproducer-react-native/ReproducerApp/ios/Pods/fmt/include/fmt/format-inl.h:1391:33 Call to consteval function 'fmt::basic_format_string<char, unsigned int &>::basic_format_string<FMT_COMPILE_STRING, 0>' is not a constant expression
/Users/brettbest/Developer/reproducer-react-native/ReproducerApp/ios/Pods/fmt/include/fmt/format-inl.h:1394:33 Call to consteval function 'fmt::basic_format_string<char, int>::basic_format_string<FMT_COMPILE_STRING, 0>' is not a constant expression
MANDATORY Reproducer
https://github.com/Brett-Best/rn-fmt-reproducer
Screenshots and Videos

Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
Needs: AttentionIssues where the author has responded to feedback.Issues where the author has responded to feedback.Needs: ReproThis issue could be improved with a clear list of steps to reproduce the issue.This issue could be improved with a clear list of steps to reproduce the issue.
Activity
[-]Xcode 26.4b1/b2 • FMT Compile Errors (it needs upgrading) • REPRO **IS** included despite the erroneous label[/-][+]Xcode 26.4b1/b2/b3 • FMT Compile Errors (it needs upgrading) • REPRO **IS** included despite the erroneous label[/+]Brett-Best commentedon Mar 13, 2026
RCT_USE_PREBUILT_RNCORE=0 RCT_USE_RN_DEP=0 bundle exec pod installI have used the latest template and using the above modification to my original steps the issue reproduces.
https://github.com/Brett-Best/rn-fmt-reproducer-v2 (no changes needed)
Brett-Best commentedon Mar 13, 2026
@leotm I cloned the latest react native commit down and did the following:
yarn installnode scripts/releases/prepare-ios-prebuilds.js -snode scripts/releases/prepare-ios-prebuilds.js -wnode scripts/releases/prepare-ios-prebuilds.js -b -p ios-simulator -r debugIn the output you can find FMT fails to compile:
I derived the steps from https://github.com/facebook/react-native/blob/972a30db4ce19609dddc8553afc2c2c2844e5442/.github/workflows/prebuild-ios-dependencies.yml.
It also looks like the Xcode version is determined by using https://github.com/facebook/react-native/blob/972a30db4ce19609dddc8553afc2c2c2844e5442/.github/workflows/prebuild-ios-dependencies.yml#L74-L76 and then which appears to be https://github.com/facebook/react-native/blob/972a30db4ce19609dddc8553afc2c2c2844e5442/.github/actions/setup-xcode/action.yml#L7
I wasn't actually able to find any run of that workflow but might've been looking in the wrong place.
However, I was able to verify that the prebuilds for RN 0.84.1 which come from here are built with Xcode 16.4.
This can be checked by looking at
rn-fmt-reproducer-v2/ReproducerApp/ios/Pods/ReactNativeDependencies/framework/packages/react-native/ReactNativeDependencies.xcframework/ios-arm64/ReactNativeDependencies.framework/Info.plistand theDTXcode/DTXcodeBuildkeys.Xcode 16.4 was released almost a year ago on 27 May 2025 and doesn't use the latest SDK.
leotm commentedon Mar 14, 2026
thanks can repro via the full opt-out
was only partially opting out 🙈 oops
RCT_USE_PREBUILT_RNCORE=0...Removing React-Core-prebuiltRCT_USE_PREBUILT_RNCORE=0 RCT_USE_RN_DEP=0...Removing ReactNativeDependenciesclear in the Podfile.lock diff
looks like RCT_USE_RN_DEP was mentioned after all in the full opt-in earlier
https://reactnative.dev/blog/2025/12/10/react-native-0.83#experimental---debug-your-precompiled-binaries-on-ios
can see what's going on now w the flags
https://github.com/facebook/react-native/blob/main/packages/react-native/scripts/ios-prebuild/__docs__/README.md
https://github.com/facebook/react-native/blob/main/packages/react-native/scripts/cocoapods/rncore.rb
https://github.com/facebook/react-native/blob/main/packages/react-native/scripts/react_native_pods.rb
https://github.com/facebook/react-native/blob/main/packages/react-native/scripts/cocoapods/rndependencies.rb
the FMT bump (direct or via RCT-Folly) makes sense
[-]Xcode 26.4b1/b2/b3 • FMT Compile Errors (it needs upgrading) • REPRO **IS** included despite the erroneous label[/-][+]Xcode 26.4b1/b2/b3/RC • FMT Compile Errors (it needs upgrading) • REPRO **IS** included despite the erroneous label[/+]Bump fmt to 12.1.0 to fix xcode 26.4 (react#56099)
Bump fmt to 12.1.0 to fix xcode 26.4 (#56099)
jenskuhrjorgensen commentedon Mar 25, 2026
@leotm thanks for fixing this. Will patch versions to RN 82, 83 and 84 be released soon? 🙏
alexeevayaan commentedon Mar 25, 2026
i usd last version react native 0.84, and i get this error on my xcode, it is after update my xcode to last version. After this moment i try to start project with version 0.83.2 and i get this error too.
alexeevayaan commentedon Mar 25, 2026
I had a big task to complete, but for some reason I decided to update my Xcode, and after that, my projects won't launch. Since the company I work for is downsizing, I'll likely be fired simply because my projects won't launch((
alexeevayaan commentedon Mar 25, 2026
Also, for some reason xcworkspace won't launch for me. GG WP
jenskuhrjorgensen commentedon Mar 25, 2026
This patch might do the trick for now:
I'm still testing it out, but sharing it now as I don't want @alexeevayaan to get fired...
vladimirivanoviliev commentedon Mar 25, 2026
Hey, I currently use slightly extended patch, to include the Android change from the original fix. I tested on both XCode 26.4, 26.3, Android studio using both dev and prod builds, and everything looks correct.
chrisbeaver commentedon Mar 25, 2026
I added a fix to my Podfile to get around this.
roidayan1 commentedon Mar 26, 2026
For those on RN 0.83.x who can't upgrade to 0.84 yet, here's a minimal
patch-packageworkaround that adds aprepare_commandto thefmt.podspecto disableconstevalinbase.h:Save as
patches/react-native+0.83.4.patch(adjust version as needed), then:This sets
FMT_USE_CONSTEVALto0, which disablesconstevalin fmt'sbase.h. Only compile-time format string validation is affected (moves to runtimeconstexprpath) — no runtime behavior change for valid format strings.Tested with Xcode 26.4 + RN 0.83.4.
Maanooz18 commentedon Mar 26, 2026
for react native 0.80.0 what is the exact solution for this problem where my macos v is 26.4
StaniEbo commentedon Mar 26, 2026
This worked for me. Thanks
roidayan1 commentedon Mar 26, 2026
your fix will work. but you will need to remember to remove it when you will upgrade react native.
My fix above using patch package ties the version and when you will upgrade, you will get a notification to remove the patch.
fix(ios): upgrade fmt to 12.1.0 for Xcode 26 compatibility
fix(ios): upgrade fmt to 12.1.0 for Xcode 26.4 compatibility (#10905)
Fix build issues when using Xcode 26.4
Diaa-Ghonim commentedon Mar 27, 2026
this fixed the issue for me
fix(ios): upgrade fmt to 12.1.0 for Xcode 26.4 compatibility (#10905)
leotm commentedon Mar 27, 2026
0.83 likely yes (active support), 0.81 likely no (unsupported)
if we feel the latter, i've opened pick requests for 0.82 (end of cycle, unsupported 2026-04-06) and 0.84 (active support)
otherwise already picked for v0.85.0-rc.6 and i verified in one of the latest 0.86 nightlies
full details in the support policy and feel free to keep track of things here
lorenc-tomasz commentedon Mar 30, 2026
I solved it that way on 0.81.6:
but like the patch from @roidayan1 better :) Thanks.
Iuriy-Budnikov commentedon Apr 6, 2026
RN 0.78.3 helped
fix: Xcode 26 fmt consteval 빌드 에러 우회
Fix Xcode 26 fmt consteval build failure with Podfile patch
fix(mobile): add Expo Config Plugin for fmt Xcode 26 fix
Bump fmt to 12.1.0 to fix xcode 26.4 (#56099)
zhouxlin commentedon Apr 15, 2026
rn: 0.81.4
xcode: 26.4
AI fixed with adding this on Podfile;
But i think i need to upgrade rn.
feat: Apple Sign In対応 & iOS 1.0.1 (build 2) & build/を.gitignoreへ追加
chore(examples): patch fmt consteval for Xcode 26.4 in example-expo-53 (
Fix iOS build on Xcode 26.4: force fmt pod to C++17
Fix iOS build on Xcode 26.4 and lift CI Xcode cap (#841)
ambadah commentedon Apr 27, 2026
I tried this, then build work fine :)
Fix fmt consteval build error with Xcode 26 (Apple Clang 17+)
fix(bare-rn/ios): force C++17 on fmt/RCT-Folly pods to dodge consteva…
Feat/android 15 upgrade (#171)
fix(ios): fmt consteval patch only on Xcode 26.4+