0

I’m trying to build my React Native Expo app for iOS using EAS Build, but I’m encountering an error related to the Firebase SDK. The error message I’m seeing is:

[!] The following Swift pods cannot yet be integrated as static libraries: The Swift pod FirebaseCoreInternal depends upon GoogleUtilities, which does not define modules. To opt into those targets generating module maps (which is necessary to import them from Swift when building as static libraries), you may set use_modular_headers! globally in your Podfile, or specify :modular_headers => true for particular dependencies.

I understand that this error is related to the integration of Swift pods as static libraries. However, since I’m using Expo, I don’t directly manage a Podfile or any native code.

Expo Version:48

Firebase Version:9.21.0

Here are the relevant parts of my package.json:

"dependencies": {
  "@expo/vector-icons": "^13.0.0",
  "@react-native-async-storage/async-storage": "^1.18.1",
  "@react-navigation/native": "^6.1.6",
  "@react-navigation/native-stack": "^6.9.12",
  "@use-expo/font": "^2.0.0",
  "expo": "~48.0.15",
  "expo-firebase-recaptcha": "^2.3.1",
  "expo-linear-gradient": "~12.1.2",
  "expo-status-bar": "~1.4.4",
  "firebase": "^9.21.0",
  "moment": "^2.29.4",
  "react": "18.2.0",
  "react-native": "0.71.3",
  "react-native-otp-textinput": "^1.0.1",
  "react-native-phone-number-input": "^2.1.0",
  "expo-app-loading": "^2.1.0",
  "react-native-safe-area-context": "4.5.0",
  "react-native-screens": "~3.20.0",
  "react-native-user-avatar": "^1.0.8",
  "react-native-webview": "11.26.0",
  "twrnc": "^3.6.0",
  "uuid": "^9.0.0"
},
"devDependencies": {
  "@babel/core": "^7.20.0",
  "babel-eslint": "^10.1.0",
  "eslint": "^8.17.0",
  "eslint-plugin-react": "^7.30.0",
  "eslint-plugin-react-native": "^4.0.0"
}

I’ve tried updating my packages, clearing my npm cache, and reinstalling my node_modules, but none of these steps have resolved the issue.

Any help or guidance would be greatly appreciated. Thank you!

Since this is an expo app, I cannot edit pod file also.

Stf_F
  • 846
  • 9
  • 23
  • it's hard to find the error but I recommend you to clean Xcode cache. If you are lucky, this could solve your issue ;) – Mauro Russo May 23 '23 at 14:57
  • This answer here worked for me like a charm! https://stackoverflow.com/questions/74910020/eas-build-for-ios-error-the-following-swift-pods-cannot-yet-be-integrated-as-st – Pulkit Gupta May 24 '23 at 16:12

0 Answers0