pod 踩坑记 太南了

1, 控制台 再ios下pod install 后 Xcode报'folly/Portability.h' file not found

image.png

解决方案:
image.png

code:

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

target 'newapp' do

  rn_path = '../node_modules/react-native'
  pod 'yoga', :path => '../node_modules/react-native/ReactCommon/yoga/yoga.podspec'
  pod 'React', :path => '../node_modules/react-native', :subspecs => [
    'Core',
    # 'BatchedBridge', # 0.45 版本以后需要添加
    'RCTText',
    'RCTImage', #这个库主要是为了使用标签
    'DevSupport',
    'RCTAnimation', #如果不加入这个的话在使用等触摸事件的时候会出现告警
    'RCTNetwork',
    'RCTWebSocket', # 这个模块是用于调试功能的
  
    # 在这里继续添加你所需要的模块
    ]

    # pod 'react-native-amap-geolocation', :path => '../node_modules/react-native-amap-geolocation/lib/ios/react-native-amap-geolocation.podspec'

    pod 'Folly', :podspec => "#{rn_path}/third-party-podspecs/Folly.podspec"


    post_install do |installer|
      installer.pods_project.targets.each do |target|
        if target.name == "React"
          target.remove_from_project
        end
      end
    end
  
end

你可能感兴趣的:(pod 踩坑记 太南了)