Argument list too long: recursive header expansion failed

我的未来我决定 提交于 2020-01-04 17:09:29

问题


I have a React Native application that did compile absolutely fine.

After installing react-native-sentry and automatically linking via react-native link, I am faced with this problem:

Showing Recent Issues
Argument list too long: recursive header expansion failed at /Users/dan/Sites/app/node_modules/react-native-intercom/iOS/../../../ios/Pods/React/node_modules/exit-hook.

This error occurred after I ran pod install

Podfile

# Uncomment the next line to define a global platform for your project
# platform :ios, '9.0'

target 'app' do
  # Uncomment the next line if you're using Swift or would like to use dynamic frameworks
  # use_frameworks!

  # Pods for app
  pod 'AppCenterReactNativeShared', '~> 1.4.0'
  pod 'SentryReactNative', :path => '../node_modules/react-native-sentry'

  platform :ios, '9.0'

  target 'appTests' do
    inherit! :search_paths
    # Pods for testing
  end

end

target 'app-tvOS' do
  # Uncomment the next line if you're using Swift or would like to use dynamic frameworks
  # use_frameworks!

  # Pods for app-tvOS

  target 'app-tvOSTests' do
    inherit! :search_paths
    # Pods for testing
  end

end

I've not modified the RNIntercom project at all, this problem always occurs after I try to install a new library via cocoa.


回答1:


I ran into a similar issue and had to go in and remove a few header search paths, as described here:

https://facebook.github.io/react-native/docs/0.60/troubleshooting#argument-list-too-long-recursive-header-expansion-failed

Argument list too long: recursive header expansion failed

In the project's build settings, User Search Header Paths and Header Search Paths are two configs that specify where Xcode should look for #import header files specified in the code. For Pods, CocoaPods uses a default array of specific folders to look in. Verify that this particular config is not overwritten, and that none of the folders configured are too large. If one of the folders is a large folder, Xcode will attempt to recursively search the entire directory and throw above error at some point.

To revert the User Search Header Paths and Header Search Paths build settings to their defaults set by CocoaPods - select the entry in the Build Settings panel, and hit delete. It will remove the custom override and return to the CocoaPod defaults.



来源:https://stackoverflow.com/questions/49318129/argument-list-too-long-recursive-header-expansion-failed

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!