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

iOS build error after upgrading from 7.0.9 to 8.0.0 (on New Build System) #932

Closed
rcstanciu opened this issue Jun 24, 2020 · 3 comments
Closed

Comments

@rcstanciu
Copy link

rcstanciu commented Jun 24, 2020

Describe the bug
Using the new build system, everything was fine with version 7.0.9. Since upgrading to 8.0.0, I'm receiving the following error when building on iOS:

❌  error: Multiple commands produce '/Users/rstanciu/Library/Developer/Xcode/DerivedData/App-gwzftpybtwfhogbchijleznskzbd/Build/Products/Debug-iphonesimulator/F86F5A50-B0A0-3D96-8330-20AFDAC47DCC.bcsymbolmap':

❌  error: Multiple commands produce '/Users/rstanciu/Library/Developer/Xcode/DerivedData/App-gwzftpybtwfhogbchijleznskzbd/Build/Products/Debug-iphonesimulator/EF3F193B-8B19-3D7A-9C4D-CC7ACB8FD1B2.bcsymbolmap':

❌  error: Multiple commands produce '/Users/rstanciu/Library/Developer/Xcode/DerivedData/App-gwzftpybtwfhogbchijleznskzbd/Build/Products/Debug-iphonesimulator/BADC3E19-B154-39DA-BE9A-E7C52B45BD0C.bcsymbolmap':

❌  error: Multiple commands produce '/Users/rstanciu/Library/Developer/Xcode/DerivedData/App-gwzftpybtwfhogbchijleznskzbd/Build/Products/Debug-iphonesimulator/AF8AFA46-95A0-3C36-89B4-0A23D7D0A613.bcsymbolmap':

❌  error: Multiple commands produce '/Users/rstanciu/Library/Developer/Xcode/DerivedData/App-gwzftpybtwfhogbchijleznskzbd/Build/Products/Debug-iphonesimulator/877E1F78-505A-34B9-A9A0-42F8BFA435B9.bcsymbolmap':

❌  error: Multiple commands produce '/Users/rstanciu/Library/Developer/Xcode/DerivedData/App-gwzftpybtwfhogbchijleznskzbd/Build/Products/Debug-iphonesimulator/7C38D00F-328F-3E0C-B30E-E47F366F0F3D.bcsymbolmap':

❌  error: Multiple commands produce '/Users/rstanciu/Library/Developer/Xcode/DerivedData/App-gwzftpybtwfhogbchijleznskzbd/Build/Products/Debug-iphonesimulator/224E36C4-6533-3853-8416-A668FDC17C35.bcsymbolmap':

Building using the Legacy Build System works fine., but we'd like to continue using the new build system.

These are the contents of [CP] Embed Pods Frameworks build phase:
Screenshot 2020-06-24 at 14 03 40

Versions (please complete the following information):

  • Platform: iOS
  • react-native-mapbox-gl Version 8.0.0
  • React Native Version 0.62.2
@mfazekas
Copy link
Contributor

mfazekas commented Jun 30, 2020

Try to remove everything mapbox related, but non cocoapods related. Sorry we don't have exact solutions for those problems.

@christophermark
Copy link

I've been hitting this also, after upgrading to the latest React Native version (0.62.2) with the new build system.

Is this a known incompatibility?

@christophermark
Copy link

christophermark commented Jun 30, 2020

I managed to solve this on my project, though the issue seems unique to Mapbox or at least unique to the some of the file types that Mapbox imports. This is related to a change in Cocoapod configurations new to React Native 0.62.

The problem

Cocoapods and Mapbox don't play well when Mapbox is included in multiple build targets (such as your app and the tests for your app). A change in React Native 0.62 adjusted the cocoapods import structure for test targets, uncovering this issue.

The fix

In the tests section of your Podfile, change inherit! :complete back to the previous value of inherit! :search_paths. This is the previous config from React Native <= 0.61.

facebook/react-native@70274f4#diff-a3c6c8e64fbbd1efef345c45e3811571R73

From what I can tell, this line either enables or disables the import of Cocoapods into the test target of your app. These scripts are auto-generated when you run pod install, so making the above change will remove the [CP] Embed Pods Frameworks script from the test target. Mapbox seems to be the only library that has issues with the scripts being present in the test target as well.

Some other links

It seems like this type of issue has plagued Cocoapods with Xcode's new build system. There were some issues like this that were similar, where maintainers had to manually omit certain filetypes so they didn't get duplicated. I'm guessing we're hitting something similar with .bcsymbolmap

Here's a link directly to a similar issue on the main Mapbox GL Native repo: mapbox/mapbox-gl-native#15619

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

No branches or pull requests

3 participants