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

Error/warning on failing build: "Can't merge pod_target_xcconfig for pod targets" #2434

Open
Nantris opened this issue Jun 16, 2024 · 47 comments
Labels
needs review Issue is ready to be reviewed by a maintainer

Comments

@Nantris
Copy link

Nantris commented Jun 16, 2024

Build/Submit details page URL

No response

Summary

EAS build that has no issues with npx expo-doctor prints this (non-fatal?) error/warning during builds. Although it doesn't seem fatal, the build is failing later in the process and I can't be sure this is unrelated to the failure.

Managed or bare?

Managed

Environment

expo-env-info 1.2.0 environment info:
System:
OS: macOS 14.5
Shell: 5.9 - /bin/zsh
Binaries:
Node: 20.12.0 - ~/.nvm/versions/node/v20.12.0/bin/node
Yarn: 1.22.22 - ~/.nvm/versions/node/v20.12.0/bin/yarn
npm: 10.5.0 - ~/.nvm/versions/node/v20.12.0/bin/npm
Managers:
CocoaPods: 1.15.2 - /usr/local/bin/pod
SDKs:
iOS SDK:
Platforms: DriverKit 23.5, iOS 17.5, macOS 14.5, tvOS 17.5, visionOS 1.2, watchOS 10.5
IDEs:
Xcode: 15.4/15F31d - /usr/bin/xcodebuild
npmGlobalPackages:
eas-cli: 10.0.0
expo-cli: 6.3.10
Expo Workflow: managed

✔ Check Expo config for common issues
✔ Check package.json for common issues
✔ Check dependencies for packages that should not be installed directly
✔ Check for common project setup issues
✔ Check for issues with metro config
✔ Check npm/ yarn versions
✔ Check Expo config (app.json/ app.config.js) schema
✔ Check native tooling versions
✔ Check that packages match versions required by installed Expo SDK
✔ Check for legacy global CLI installed locally
✔ Check that native modules do not use incompatible support packages
✔ Check that native modules use compatible support package versions for installed Expo SDK

Didn't find any issues with the project!

Error output

[INSTALL_PODS] [!] [Codegen] warn: using experimental new codegen integration
[INSTALL_PODS] [!] `<PBXResourcesBuildPhase UUID=`13B07F8E1A680F5B00A75B9A`>` attempted to initialize an object with an unknown UUID. `D5A51ACEDD5444D6B50BA983` for attribute: `files`. This can be the result of a merge and the unknown UUID is being discarded.
[INSTALL_PODS] [!] Can't merge pod_target_xcconfig for pod targets: ["expo-dev-menu", "Main", "ReactNativeCompatibles", "SafeAreaView", "Vendored"]. Singular build setting DEFINES_MODULE has different values.
[INSTALL_PODS] [!] Can't merge pod_target_xcconfig for pod targets: ["expo-dev-menu", "Main", "ReactNativeCompatibles", "SafeAreaView", "Vendored"]. Singular build setting DEFINES_MODULE has different values.
[INSTALL_PODS] [!] hermes-engine has added 1 script phase. Please inspect before executing a build. See `https://guides.cocoapods.org/syntax/podspec.html#script_phases` for more information.

Reproducible demo or steps to reproduce from a blank project

Unknown

@Nantris Nantris added the needs review Issue is ready to be reviewed by a maintainer label Jun 16, 2024
@jmarsh24
Copy link

+1

1 similar comment
@adamstl1997
Copy link

+1

@Jules-Astier
Copy link

I've also had this issue

@aimeeaidanu
Copy link

+1

@Nantris
Copy link
Author

Nantris commented Jul 2, 2024

To everyone commenting +1 and the like, it would do you much more good to:

  1. Add a thumbs-up (maintainers can organize issues by their number of reaction emojis)
  2. Add a meaningful comment with your findings, or otherwise subscribe to notifications on the right-hand-side to avoid cluttering the thread

@abhishek-pavesoft
Copy link

abhishek-pavesoft commented Jul 4, 2024

Hey did you find a solution to this? I'm also facing this issue.

@aimeeaidanu
Copy link

Yeah I fixed it by updating expo-cli

@abhishek-pavesoft
Copy link

@aimeeaidanu I also resolved it a few minutes ago by changing iOS target version from 13.0 to 13.4.

@Nantris
Copy link
Author

Nantris commented Jul 5, 2024

@aimeeaidanu to what version? I think expo-cli upgrades can change the iOS target version (though generally only for major releases?)

I was on the latest at the time when I filed this.

@adamwett
Copy link

adamwett commented Jul 24, 2024

Yeah I fixed it by updating expo-cli

Wasn't this replaced by npx expo?

@nbonatsakis
Copy link

I'm seeing this as well. Clean expo-doctor, expo 51, and am using iOS deployment target of 17.0 (because I have some native code that needs this as min version).

@ChrisWiles
Copy link

I see the exact msg, not sure if breaks anything tho. App seems to work fine.

  "dependencies": {
    "@amplitude/analytics-react-native": "1.4.9",
    "@apollo/client": "3.11.3",
    "@casl/ability": "6.7.1",
    "@datadog/mobile-react-native": "2.4.3",
    "@datadog/mobile-react-native-apollo-client": "2.4.3",
    "@datadog/mobile-react-navigation": "2.4.3",
    "@expo/fingerprint": "0.10.2",
    "@expo/vector-icons": "14.0.2",
    "@fortawesome/fontawesome-svg-core": "6.5.2",
    "@fortawesome/pro-regular-svg-icons": "6.5.2",
    "@fortawesome/pro-solid-svg-icons": "6.5.2",
    "@fortawesome/react-native-fontawesome": "0.3.0",
    "@fullstory/react-native": "1.7.1",
    "@gluestack-style/babel-plugin-styled-resolver": "1.0.7",
    "@gluestack-style/react": "1.0.57",
    "@gluestack-ui/config": "1.1.20",
    "@gluestack-ui/themed": "1.1.44",
    "@intercom/intercom-react-native": "7.2.0",
    "@react-native-async-storage/async-storage": "1.24.0",
    "@react-native-community/datetimepicker": "8.2.0",
    "@react-native-community/netinfo": "11.3.2",
    "@react-native-community/slider": "4.5.2",
    "@react-native-masked-view/masked-view": "0.3.1",
    "@react-native-picker/picker": "2.7.7",
    "@react-native-segmented-control/segmented-control": "2.5.2",
    "@react-navigation/bottom-tabs": "6.6.1",
    "@react-navigation/devtools": "6.0.27",
    "@react-navigation/drawer": "6.7.2",
    "@react-navigation/native": "6.1.18",
    "@react-navigation/stack": "6.4.1",
    "@reduxjs/toolkit": "2.2.7",
    "@sentry/react-native": "5.27.0",
    "@shopify/flash-list": "1.7.0",
    "@shopify/restyle": "1.8.0",
    "amazon-cognito-identity-js": "6.3.12",
    "apollo-link-debounce": "3.0.0",
    "apollo3-cache-persist": "0.15.0",
    "awesome-debounce-promise": "2.1.0",
    "aws-amplify": "5.3.11",
    "babel-plugin-transform-inline-environment-variables": "0.4.4",
    "big.js": "6.2.1",
    "color": "4.2.3",
    "cuid": "2.1.8",
    "dotenv": "16.4.5",
    "email-addresses": "5.0.0",
    "expo": "51.0.24",
    "expo-application": "5.9.1",
    "expo-asset": "10.0.10",
    "expo-barcode-scanner": "13.0.1",
    "expo-camera": "15.0.14",
    "expo-clipboard": "6.0.3",
    "expo-constants": "16.0.2",
    "expo-dev-client": "4.0.21",
    "expo-device": "6.0.2",
    "expo-font": "12.0.9",
    "expo-image-manipulator": "12.0.5",
    "expo-image-picker": "15.0.7",
    "expo-linking": "6.3.1",
    "expo-localization": "15.0.3",
    "expo-notifications": "0.28.15",
    "expo-screen-orientation": "7.0.5",
    "expo-splash-screen": "0.27.5",
    "expo-status-bar": "1.12.1",
    "expo-updates": "0.25.21",
    "expo-web-browser": "13.0.3",
    "formik": "2.4.6",
    "fuse.js": "6.6.2",
    "graphql": "16.9.0",
    "graphql-ws": "5.16.0",
    "highlight-words-core": "1.2.2",
    "i18next": "23.12.2",
    "jest-circus": "29.7.0",
    "jotai": "2.9.1",
    "jwt-decode": "3.1.2",
    "lodash": "4.17.21",
    "luxon": "3.5.0",
    "metro-react-native-babel-transformer": "0.77.0",
    "moment": "2.30.1",
    "native-base": "3.4.28",
    "query-string": "7.1.3",
    "react": "18.3.1",
    "react-i18next": "15.0.0",
    "react-native": "0.74.5",
    "react-native-animatable": "1.4.0",
    "react-native-app-intro-slider": "4.0.4",
    "react-native-config": "1.5.3",
    "react-native-confirmation-code-field": "7.4.0",
    "react-native-device-info": "11.1.0",
    "react-native-dialog": "9.3.0",
    "react-native-dotenv": "3.4.11",
    "react-native-gesture-handler": "2.18.1",
    "react-native-get-random-values": "1.11.0",
    "react-native-hide-with-keyboard": "1.2.1",
    "react-native-image-viewing": "0.1.8",
    "react-native-keyboard-aware-scroll-view": "0.9.5",
    "react-native-keychain": "8.2.0",
    "react-native-modalize": "2.1.1",
    "react-native-open-maps": "0.4.3",
    "react-native-pager-view": "6.3.3",
    "react-native-phone-number-input": "2.1.0",
    "react-native-reanimated": "3.14.0",
    "react-native-safe-area-context": "4.10.8",
    "react-native-screens": "3.34.0",
    "react-native-segmented-control-tab": "4.0.0",
    "react-native-svg": "15.4.0",
    "react-native-svg-transformer": "1.5.0",
    "react-native-swipeable-row": "0.8.1",
    "react-native-tab-view": "3.5.2",
    "react-native-typography": "1.4.1",
    "react-native-version": "4.0.0",
    "react-native-web": "0.19.12",
    "react-native-webview": "13.10.5",
    "react-redux": "9.1.2",
    "suppress-exit-code": "3.2.0",
    "validator": "13.12.0"
  }

@Nantris
Copy link
Author

Nantris commented Aug 7, 2024

For what it's worth, this issue was not breaking our builds as far as I can tell. I got our builds working and I'm 99% sure this warning persisted despite the functional build being output.

@JeanBaptisteBolh
Copy link

I'm having this issue. Might just be a warning but further down my build fails. This is the issue (something to do with fastlane)
#2109

I'm thinking this might be related

@Daniel-Cross
Copy link

Did anyone find a solution to this? We just started getting it despite everything being fine 5 days ago.

@aimeeaidanu
Copy link

@Daniel-Cross and to any other people having this issue, try copying all files into a new directory and rebuilding. Seems to fix the issue as well.

@junzhengca
Copy link

This started to happen to me as well, fully managed project, same failure both on EAS and with --local flag.

Tried to copy the directory to a new location, doesn't work.

@statico
Copy link

statico commented Oct 9, 2024

We just started getting this on EAS. Builds were passing on Sep 30 but we get this error as of today. No dependencies have changed.

@JuanEliasJabib02
Copy link

having this same problem, someone solve it?

@aimeeaidanu
Copy link

This issue seems to be come and go periodically. Keep me posted on any updates you guys have

@DanielssonWilliam
Copy link

DanielssonWilliam commented Oct 10, 2024

I have the same issue. Did a build in late September and it worked fine. Tried building 2 days ago 8:th of October and now it doesnt want to go through. Nothing in the code except the version number on the app has gone up. And I have a clean install of expo-cli

Will it just correct itself in a few days?
https://status.expo.dev/ - says that all systems are operational

https://expo.dev/eas-build-status - also confirms that builds are going through. So surely everyone does not have this problem

EDIT: We solved this problem today. As many have said the error is very missleading. And usually seem to be caused by some other underlying error. For us it was some packages that were outdated. We got warnings from expo-doctor and updating those dependencies fixed the build errors. It could have been caused by the new Xcode Versions that demands higher versions on some packages.

@statico
Copy link

statico commented Oct 10, 2024

I just ran into this, and I think this warning is misleading.

Our problem was actually certificates, and that error is hidden by Fastlane piping Xcode logs to disk. By running EAS_LOCAL_BUILD_SKIP_CLEANUP=1 EAS_LOCAL_BUILD_WORKINGDIR=/tmp/eas eas build --local, I got a logfile in /tmp/eas/logs that I could look through to identify the cause of the build failure.

In our case it was something like /tmp/eas/build/packages/mobile/ios/MyApp.xcodeproj: error: Provisioning profile "*[expo] com.myapp.mobile AppStore 2024-10-09T23:20:03.581Z" doesn't include signing certificate "Apple Distribution: MyApp Technologies, Inc. (ASDF123Y4C)". (in target 'MyApp' from project 'MyApp')

@sakihayashi
Copy link

Did anyone make this work? I am running into the same issue. It was fine a few days ago...; Suddenly build started to fail with exactly the same message no matter how I changed the Podfile.

@junzhengca
Copy link

Did anyone make this work? I am running into the same issue. It was fine a few days ago...; Suddenly build started to fail with exactly the same message no matter how I changed the Podfile.

For us one thing that helped was to upgrade Expo version to the latest minor update, and run Expo doctor to update all dependencies. This worked for a fully managed Expo project, with or without --local.

Of course, your milage may vary given many of the folks already tried this. For us the main thing that helped is to upgrade Expo SDK itself, not just upgrading other dependencies.

@mariomurrent-softwaresolutions

Having the same issue. Tried everything here, but no solution did help

@statico
Copy link

statico commented Oct 23, 2024

Our builds are working again. For us, the error in this issue was unrelated. The real error (about provisioning/certificates) was hidden in the full log, which is only available when building with --local and not on EAS.

@mariomurrent-softwaresolutions

@statico yeah I tried it locally, but no logs are written ...

@hameed-ijadunola
Copy link

@mariomurrent-softwaresolutions try upgrading my react-native to the latest patch version. This fixed it for me

@sakihayashi
Copy link

@statico I tried it, too. but no luck. I created a new certificate working fine but same error.

@mariomurrent-softwaresolutions

Having the same issue. Tried everything here, but no solution did help

Same here.

@junzhengca Thank you! but when I solved the expo doctor's all issues, I am still getting the same errors.

✔ Validating global prerequisites versions passed
✔ Checking for incompatible packages passed
✔ Checking for conflicting global packages in project passed
✔ Verifying prebuild support package versions are compatible passed
✔ Checking dependency versions for compatibility with the installed Expo SDK passed
✔ Validating Expo Config passed
✔ Checking package.json for common issues passed

Didn't find any issues with the project!

The errors are the same

Pod installation complete! There are 78 dependencies from the Podfile and 77 total pods installed.

[!] [Codegen] warn: using experimental new codegen integration

[!] Can't merge pod_target_xcconfig for pod targets: ["expo-dev-menu", "Main", "ReactNativeCompatibles", "SafeAreaView", "Vendored"]. Singular build setting DEFINES_MODULE has different values.

[!] Can't merge pod_target_xcconfig for pod targets: ["expo-dev-menu", "Main", "ReactNativeCompatibles", "SafeAreaView", "Vendored"]. Singular build setting DEFINES_MODULE has different values.`

My Podfile definitely has YES only

installer.pods_project.targets.each do |target|
      target.build_configurations.each do |config|
        config.build_settings['DEFINES_MODULE'] = 'YES'
      end
    end
  end

@mariomurrent-softwaresolutions
Copy link

mariomurrent-softwaresolutions commented Oct 23, 2024

@sakihayashi updated the deployment target to 15 and updated all dependencies. Did a clean and rebuild and now it seems to work

@mariomurrent-softwaresolutions

@mariomurrent-softwaresolutions try upgrading my react-native to the latest patch version. This fixed it for me

Seems like this fixed it

@JeanBaptisteBolh
Copy link

I'm having this issue. Might just be a warning but further down my build fails. This is the issue (something to do with fastlane) #2109

I'm thinking this might be related

It was NOT related.

The key for me was kicking off a non-local build on eas, then getting the xcode logs through the dashboard which revealed the error (in the logs). I couldn't find those xcode logs on my local machine when building locally, but the expo ui makes it easy to download those.

@sakihayashi
Copy link

@mariomurrent-softwaresolutions
Thank you! I've upgraded React native and react as they instructed but in my case, the target 15.0 was not enough and went to 16.0. Was your react native version 0.76.0? (and React 18.3.1?)

I cleaned everything and tried it but eventually I got the same error when I run pod install

Pod installation complete! There are 87 dependencies from the Podfile and 86 total pods installed.

[!] [Codegen] warn: using experimental new codegen integration

[!] Can't merge pod_target_xcconfig for pod targets: ["expo-dev-menu", "Main", "ReactNativeCompatibles", "SafeAreaView", "Vendored"]. Singular build setting DEFINES_MODULE has different values.

[!] Can't merge pod_target_xcconfig for pod targets: ["expo-dev-menu", "Main", "ReactNativeCompatibles", "SafeAreaView", "Vendored"]. Singular build setting DEFINES_MODULE has different values.

[!] hermes-engine has added 1 script phase. Please inspect before executing a build. See `https://guides.cocoapods.org/syntax/podspec.html#script_phases` for more information.

@Nantris
Copy link
Author

Nantris commented Oct 23, 2024

Can anyone actually confirm ill effects from this issue? I don't want to waste the maintainers time, and so far I haven't confirmed any problems caused by it.

@mariomurrent-softwaresolutions

@mariomurrent-softwaresolutions Thank you! I've upgraded React native and react as they instructed but in my case, the target 15.0 was not enough and went to 16.0. Was your react native version 0.76.0? (and React 18.3.1?)

I cleaned everything and tried it but eventually I got the same error when I run pod install

Pod installation complete! There are 87 dependencies from the Podfile and 86 total pods installed.

[!] [Codegen] warn: using experimental new codegen integration

[!] Can't merge pod_target_xcconfig for pod targets: ["expo-dev-menu", "Main", "ReactNativeCompatibles", "SafeAreaView", "Vendored"]. Singular build setting DEFINES_MODULE has different values.

[!] Can't merge pod_target_xcconfig for pod targets: ["expo-dev-menu", "Main", "ReactNativeCompatibles", "SafeAreaView", "Vendored"]. Singular build setting DEFINES_MODULE has different values.

[!] hermes-engine has added 1 script phase. Please inspect before executing a build. See `https://guides.cocoapods.org/syntax/podspec.html#script_phases` for more information.

"react-native": "0.74.5",
"react": "18.2.0",

As the expo-doctor said. So I updated all dependencies that I have no warning in expo-doctor

@mariomurrent-softwaresolutions

Can anyone actually confirm ill effects from this issue? I don't want to waste the maintainers time, and so far I haven't confirmed any problems caused by it.

Well it breaks local builds ...

@Nantris
Copy link
Author

Nantris commented Oct 24, 2024

Well it breaks local builds ...

Unless I'm crazy, it didn't break mine.

@mariomurrent-softwaresolutions

Well maybe not for you. Until I fixed the error yesterday, the build did not successfully complete locally.

@aimeeaidanu
Copy link

aimeeaidanu commented Oct 24, 2024

I may have already commented this but my biggest advice is to try to reinitalize in a fresh new project. A lot of these expo issues seem to have a completely random cause but creating a new project and then moving the code over seems to fix them.

Key Point: It's going to correct itself eventually 😁

@Nantris
Copy link
Author

Nantris commented Oct 24, 2024

Until I fixed the error yesterday, the build did not successfully complete locally.

I don't see how this could be anything but an all or nothing, but your experience is duly noted.

@sakihayashi
Copy link

I don't see how this could be anything but an all or nothing, but your experience is duly noted.

Surely, when I upgraded React native, the warning gone in my case like @mariomurrent-softwaresolutions said although I am now getting other errors.

In the end, I decided to re-initialize the app as it had looping errors and warnings and does not read two files anymore.

@jvgeee
Copy link

jvgeee commented Nov 8, 2024

I got this error when doing a local build for IOS.

My issue was that I'd just updated Xcode, and I hadn't yet downloaded and installed simulators for the newest IOS version.

Solution:

  • Open Xcode
  • Accept the new terms and conditions (if there)
  • Download and Install the IOS simulators for the newest version

@mariomurrent-softwaresolutions

Getting the same error after upgrading to Expo SDK 52 ...
@jvgeee Did not help to me ...

Seems really like a random occurring error for older projects :(

@samixp02
Copy link

samixp02 commented Dec 9, 2024

if I'm not wrong it's related to react-native-svg downgrade to 15.3 and one more thing try to run pod install and show us the log

@pranav-more
Copy link

`Integrating client project
Pod installation complete! There are 92 dependencies from the Podfile and 93 total pods installed.

[!] [Codegen] warn: using experimental new codegen integration

[!] Can't merge pod_target_xcconfig for pod targets: ["expo-dev-menu", "Main", "ReactNativeCompatibles", "SafeAreaView", "Vendored"]. Singular build setting DEFINES_MODULE has different values.

[!] Can't merge pod_target_xcconfig for pod targets: ["expo-dev-menu", "Main", "ReactNativeCompatibles", "SafeAreaView", "Vendored"]. Singular build setting DEFINES_MODULE has different values.`

I am getting this issue and its breaking build in xcode ,
"react": "18.3.1",
"react-native": "^0.76.5",

@samixp02
Copy link

`Integrating client project Pod installation complete! There are 92 dependencies from the Podfile and 93 total pods installed.

[!] [Codegen] warn: using experimental new codegen integration

[!] Can't merge pod_target_xcconfig for pod targets: ["expo-dev-menu", "Main", "ReactNativeCompatibles", "SafeAreaView", "Vendored"]. Singular build setting DEFINES_MODULE has different values.

[!] Can't merge pod_target_xcconfig for pod targets: ["expo-dev-menu", "Main", "ReactNativeCompatibles", "SafeAreaView", "Vendored"]. Singular build setting DEFINES_MODULE has different values.`

I am getting this issue and its breaking build in xcode , "react": "18.3.1", "react-native": "^0.76.5",

need full package.json file +error logs after running npx expo run:ios

@matthsena
Copy link

I fixed this bug with the cmd: npx expo install --check, it was causing conflict between some dependencies installed in the project

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs review Issue is ready to be reviewed by a maintainer
Projects
None yet
Development

No branches or pull requests