LiquidCore: 'grpc/support/port_platform.h' file not found

/Users/long1eu/IdeaProjects/project/ios/Pods/gRPC-C++/src/core/lib/gpr/env.h:22:10: ‘grpc/support/port_platform.h’ file not found

PODS:
  - Bolts (1.9.0):
    - Bolts/AppLinks (= 1.9.0)
    - Bolts/Tasks (= 1.9.0)
  - Bolts/AppLinks (1.9.0):
    - Bolts/Tasks
  - Bolts/Tasks (1.9.0)
  - BoringSSL-GRPC (0.0.3):
    - BoringSSL-GRPC/Implementation (= 0.0.3)
    - BoringSSL-GRPC/Interface (= 0.0.3)
  - BoringSSL-GRPC/Implementation (0.0.3):
    - BoringSSL-GRPC/Interface (= 0.0.3)
  - BoringSSL-GRPC/Interface (0.0.3)
  - cloud_firestore (0.0.1):
    - Firebase/Auth
    - Firebase/Core
    - Firebase/Database
    - Firebase/Firestore (~> 6.0)
    - Flutter
  - cloud_functions (0.0.1):
    - Firebase/Core
    - Firebase/Functions
    - Flutter
  - Crashlytics (3.12.0):
    - Fabric (~> 1.9.0)
  - Fabric (1.9.0)
  - FBSDKCoreKit (4.39.1):
    - Bolts (~> 1.9)
  - FBSDKLoginKit (4.39.1):
    - FBSDKCoreKit
  - FBSDKShareKit (4.39.1):
    - FBSDKCoreKit
  - Firebase/Analytics (6.0.0):
    - Firebase/Core
  - Firebase/Auth (6.0.0):
    - Firebase/CoreOnly
    - FirebaseAuth (~> 6.0.0)
  - Firebase/Core (6.0.0):
    - Firebase/CoreOnly
    - FirebaseAnalytics (= 6.0.0)
  - Firebase/CoreOnly (6.0.0):
    - FirebaseCore (= 6.0.0)
  - Firebase/Database (6.0.0):
    - Firebase/CoreOnly
    - FirebaseDatabase (~> 6.0.0)
  - Firebase/DynamicLinks (6.0.0):
    - Firebase/CoreOnly
    - FirebaseDynamicLinks (~> 4.0.0)
  - Firebase/Firestore (6.0.0):
    - Firebase/CoreOnly
    - FirebaseFirestore (~> 1.3.0)
  - Firebase/Functions (6.0.0):
    - Firebase/CoreOnly
    - FirebaseFunctions (~> 2.5.0)
  - Firebase/Messaging (6.0.0):
    - Firebase/CoreOnly
    - FirebaseMessaging (~> 4.0.0)
  - Firebase/Storage (6.0.0):
    - Firebase/CoreOnly
    - FirebaseStorage (~> 3.2.0)
  - firebase_analytics (0.0.1):
    - Firebase/Analytics (~> 6.0)
    - Firebase/Core
    - Flutter
  - firebase_auth (0.0.1):
    - Firebase/Auth (~> 6.0)
    - Firebase/Core
    - Flutter
  - firebase_core (0.0.1):
    - Firebase/Core
    - Flutter
  - firebase_dynamic_links (0.1.0):
    - Firebase/DynamicLinks
    - Flutter
  - firebase_notifications (0.0.1):
    - Firebase/Core
    - Firebase/Messaging
    - Flutter
  - firebase_storage (0.0.1):
    - Firebase/Storage
    - Flutter
  - FirebaseAnalytics (6.0.0):
    - FirebaseCore (~> 6.0)
    - FirebaseInstanceID (~> 4.0)
    - GoogleAppMeasurement (= 6.0.0)
    - GoogleUtilities/AppDelegateSwizzler (~> 6.0)
    - GoogleUtilities/MethodSwizzler (~> 6.0)
    - GoogleUtilities/Network (~> 6.0)
    - "GoogleUtilities/NSData+zlib (~> 6.0)"
    - nanopb (~> 0.3)
  - FirebaseAnalyticsInterop (1.2.0)
  - FirebaseAuth (6.0.0):
    - FirebaseAuthInterop (~> 1.0)
    - FirebaseCore (~> 6.0)
    - GoogleUtilities/AppDelegateSwizzler (~> 6.0)
    - GoogleUtilities/Environment (~> 6.0)
    - GTMSessionFetcher/Core (~> 1.1)
  - FirebaseAuthInterop (1.0.0)
  - FirebaseCore (6.0.0):
    - GoogleUtilities/Environment (~> 6.0)
    - GoogleUtilities/Logger (~> 6.0)
  - FirebaseDatabase (6.0.0):
    - FirebaseAuthInterop (~> 1.0)
    - FirebaseCore (~> 6.0)
    - leveldb-library (~> 1.18)
  - FirebaseDynamicLinks (4.0.0):
    - FirebaseAnalyticsInterop (~> 1.0)
    - FirebaseCore (~> 6.0)
  - FirebaseFirestore (1.3.0):
    - FirebaseAuthInterop (~> 1.0)
    - FirebaseCore (~> 6.0)
    - FirebaseFirestore/abseil-cpp (= 1.3.0)
    - "gRPC-C++ (= 0.0.8)"
    - leveldb-library (~> 1.20)
    - nanopb (~> 0.3.901)
    - Protobuf (~> 3.1)
  - FirebaseFirestore/abseil-cpp (1.3.0):
    - FirebaseAuthInterop (~> 1.0)
    - FirebaseCore (~> 6.0)
    - "gRPC-C++ (= 0.0.8)"
    - leveldb-library (~> 1.20)
    - nanopb (~> 0.3.901)
    - Protobuf (~> 3.1)
  - FirebaseFunctions (2.5.0):
    - FirebaseAuthInterop (~> 1.0)
    - FirebaseCore (~> 6.0)
    - GTMSessionFetcher/Core (~> 1.1)
  - FirebaseInstanceID (4.0.0):
    - FirebaseCore (~> 6.0)
    - GoogleUtilities/Environment (~> 6.0)
    - GoogleUtilities/UserDefaults (~> 6.0)
  - FirebaseMessaging (4.0.0):
    - FirebaseAnalyticsInterop (~> 1.1)
    - FirebaseCore (~> 6.0)
    - FirebaseInstanceID (~> 4.0)
    - GoogleUtilities/AppDelegateSwizzler (~> 6.0)
    - GoogleUtilities/Environment (~> 6.0)
    - GoogleUtilities/Reachability (~> 6.0)
    - GoogleUtilities/UserDefaults (~> 6.0)
    - Protobuf (~> 3.1)
  - FirebaseStorage (3.2.0):
    - FirebaseAuthInterop (~> 1.0)
    - FirebaseCore (~> 6.0)
    - GTMSessionFetcher/Core (~> 1.1)
  - Flutter (1.0.0)
  - flutter_crashlytics (0.0.1):
    - Crashlytics
    - Fabric
    - Flutter
  - flutter_facebook_login (0.0.1):
    - FBSDKCoreKit (= 4.39.1)
    - FBSDKLoginKit (= 4.39.1)
    - FBSDKShareKit (= 4.39.1)
    - Flutter
  - FMDB (2.7.5):
    - FMDB/standard (= 2.7.5)
  - FMDB/standard (2.7.5)
  - google_sign_in (0.0.1):
    - Flutter
    - GoogleSignIn (~> 4.0)
  - GoogleAppMeasurement (6.0.0):
    - GoogleUtilities/AppDelegateSwizzler (~> 6.0)
    - GoogleUtilities/MethodSwizzler (~> 6.0)
    - GoogleUtilities/Network (~> 6.0)
    - "GoogleUtilities/NSData+zlib (~> 6.0)"
    - nanopb (~> 0.3)
  - GoogleSignIn (4.4.0):
    - "GoogleToolboxForMac/NSDictionary+URLArguments (~> 2.1)"
    - "GoogleToolboxForMac/NSString+URLArguments (~> 2.1)"
    - GTMSessionFetcher/Core (~> 1.1)
  - GoogleToolboxForMac/DebugUtils (2.2.0):
    - GoogleToolboxForMac/Defines (= 2.2.0)
  - GoogleToolboxForMac/Defines (2.2.0)
  - "GoogleToolboxForMac/NSDictionary+URLArguments (2.2.0)":
    - GoogleToolboxForMac/DebugUtils (= 2.2.0)
    - GoogleToolboxForMac/Defines (= 2.2.0)
    - "GoogleToolboxForMac/NSString+URLArguments (= 2.2.0)"
  - "GoogleToolboxForMac/NSString+URLArguments (2.2.0)"
  - GoogleUtilities/AppDelegateSwizzler (6.0.0):
    - GoogleUtilities/Environment
    - GoogleUtilities/Logger
    - GoogleUtilities/Network
  - GoogleUtilities/Environment (6.0.0)
  - GoogleUtilities/Logger (6.0.0):
    - GoogleUtilities/Environment
  - GoogleUtilities/MethodSwizzler (6.0.0):
    - GoogleUtilities/Logger
  - GoogleUtilities/Network (6.0.0):
    - GoogleUtilities/Logger
    - "GoogleUtilities/NSData+zlib"
    - GoogleUtilities/Reachability
  - "GoogleUtilities/NSData+zlib (6.0.0)"
  - GoogleUtilities/Reachability (6.0.0):
    - GoogleUtilities/Logger
  - GoogleUtilities/UserDefaults (6.0.0):
    - GoogleUtilities/Logger
  - "gRPC-C++ (0.0.8)":
    - "gRPC-C++/Implementation (= 0.0.8)"
    - "gRPC-C++/Interface (= 0.0.8)"
  - "gRPC-C++/Implementation (0.0.8)":
    - "gRPC-C++/Interface (= 0.0.8)"
    - gRPC-Core (= 1.19.0)
    - nanopb (~> 0.3)
  - "gRPC-C++/Interface (0.0.8)"
  - gRPC-Core (1.19.0):
    - gRPC-Core/Implementation (= 1.19.0)
    - gRPC-Core/Interface (= 1.19.0)
  - gRPC-Core/Implementation (1.19.0):
    - BoringSSL-GRPC (= 0.0.3)
    - gRPC-Core/Interface (= 1.19.0)
    - nanopb (~> 0.3)
  - gRPC-Core/Interface (1.19.0)
  - GTMSessionFetcher/Core (1.2.1)
  - h3 (3.4.3)
  - image_cropper (0.0.1):
    - Flutter
    - TOCropViewController (~> 2.4.0)
  - image_picker (0.0.1):
    - Flutter
  - leveldb-library (1.20)
  - liquid_core (0.0.1):
    - Flutter
    - LiquidCore
  - LiquidCore (0.6.1)
  - location (0.0.1):
    - Flutter
  - location_permissions (2.0.1):
    - Flutter
  - nanopb (0.3.901):
    - nanopb/decode (= 0.3.901)
    - nanopb/encode (= 0.3.901)
  - nanopb/decode (0.3.901)
  - nanopb/encode (0.3.901)
  - path_provider (0.0.1):
    - Flutter
  - pinch_zoom_image (0.0.1):
    - Flutter
  - Protobuf (3.7.0)
  - sqflite (0.0.1):
    - Flutter
    - FMDB (~> 2.7.2)
  - TOCropViewController (2.4.0)
   CocoaPods : 1.7.0.beta.3
        Ruby : ruby 2.3.7p456 (2018-03-28 revision 63024) [universal.x86_64-darwin18]
    RubyGems : 2.5.2.3
        Host : Mac OS X 10.14.4 (18E226)
       Xcode : 10.2.1 (10E1001)
         Git : git version 2.20.1 (Apple Git-117)
Ruby lib dir : /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib
Repositories : master - https://github.com/CocoaPods/Specs.git @ 036c27ef66ff38d5f2ac8494c74e39b24efa9387

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Comments: 16 (10 by maintainers)

Most upvoted comments

You’re right @ericwlange, I think it’s an issue with the gprc podspec headers being too expressive.

Untested, but I have a feeling it’s because their podspec doesn’t specify a public_header_files so all their source headers are seen as public and being used by Liquidcore, I’m not sure why Cocoapod /Xcode would prioritize their headers over ours though.

Relevant PR addressing a similar issue: https://github.com/grpc/grpc/pull/15277

I think your workaround probably just changes the priority such that LiquidCore and it’s headers are used before gprc or something, I’m not fully sure how Xcode headers work.

I can’t think of a better workaround right now apart from forking gprc and changing its podspec.

Please share your project file after pod install. (Alternatively just your HEADER_SEARCH_PATHS).

Inevitably these problems happen because you have an entry in there that somehow includes your Pods folder recursively (either directly or indirectly) which allows these conflicts to occur.

I don’t really know anything about flutter, so it’s possible that your liquid_core_and_firestore_test could serve this purpose, but I have no idea how to use it to show the problem. Could you either give instructions for how to use it to show the problem or commit everything that results from pod install?

Workaround:

  1. Clone the LiquidCore repo
  2. In ios/Podfile, add the pod 'LiquidCore' ... line after use_frameworks!
target 'Runner' do
  use_frameworks!

  pod 'LiquidCore', :path => '/path/to/local/clone/of/LiquidCore/LiquidCore.podspec'
  ...
  1. Build.

It should work. I have no idea why this solves the problem. I simply added this line because I wanted to try and debug it using a development pod and then it suddenly started working.

You can use this workaround in the meantime until we can figure out why this is happening.

I have a hypothesis. It is likely that one of the other pods also has a file named env.h and for some reason LiquidCore is picking that one up instead of node’s env.h. I’m not sure how or why that can happen, but it seems likely. I will try to replicate with your project.