Skip to content

Included GLog.podspec broken on case sensitive file system #16181

@athei

Description

@athei

Resolution

Fixed in 0.54, update your podfile:

pod 'glog', :podspec => 'node_modules/react-native/third-party-podspecs/glog.podspec'

Original Bug Report

Is this a bug report?

yes

Have you read the Contributing Guidelines?

yes

Environment

Environment:
OS: macOS High Sierra 10.13
Node: 8.6.0
Yarn: 1.1.0
npm: 5.3.0
Watchman: 4.9.0
Xcode: Xcode 9.0 Build version 9A235
Android Studio: 2.3 AI-162.4069837

Packages: (wanted => installed)
react: 16.0.0-alpha.12 => 16.0.0-alpha.12
react-native: ^0.48.2 => 0.48.3

Target Platform: iOS (10.3)

Steps to Reproduce

  1. Place your the source of your react-native based project on a case sensitive file system on macOS (HFS+ or APFS).
  2. Manage your dependencies using cocoapods instead of react-native link.

Here is a minimal Podfile:

platform :ios, '10.3'
inhibit_all_warnings!

target 'MyiOSProject' do
  # React dependencies
  pod 'Yoga', :path => '../node_modules/react-native/ReactCommon/yoga'
  pod 'DoubleConversion', :podspec => '../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec'
  pod 'GLog', :podspec => '../node_modules/react-native/third-party-podspecs/GLog.podspec'
  pod 'Folly', :podspec => '../node_modules/react-native/third-party-podspecs/Folly.podspec'
  
  # React and its submodules
  pod 'React', :path => '../node_modules/react-native', :subspecs => [
    'Core',
    'CxxBridge',
    'DevSupport',
    'RCTPushNotification',
    'RCTText',
    'RCTImage',
    'RCTAnimation',
    'RCTNetwork'
  ]
end
  1. pod install

  2. Try to build the resulting xcworkspace using Xcode.

Expected Behavior

When opening the xcworkspace and press build it should build without errors.

Actual Behavior

I get a build error saying .../Pods/Folly/folly/Range.h:33:10: 'glog/logging.h' file not found

screen shot 2017-10-03 at 12 56 07

How to fix

Just fix your supplied GLog.podspec to have spec.name = 'glog' instead of spec.name = 'GLog'. The name of the library is glog not GLog. Because of this misspelling cocoapods names the subdirectory in the Headers folder wrongly and therefore the inclusion error on case sensitive systems.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions