FirebaseFirestore.podspec 2.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. Pod::Spec.new do |s|
  2. s.name = 'FirebaseFirestore'
  3. s.version = '0.12.3'
  4. s.summary = 'Google Cloud Firestore for iOS'
  5. s.description = <<-DESC
  6. Google Cloud Firestore is a NoSQL document database built for automatic scaling, high performance, and ease of application development.
  7. DESC
  8. s.homepage = 'https://developers.google.com/'
  9. s.license = { :type => 'Apache', :file => 'LICENSE' }
  10. s.authors = 'Google, Inc.'
  11. s.source = {
  12. :git => 'https://github.com/firebase/firebase-ios-sdk.git',
  13. :tag => 'Firestore-' + s.version.to_s
  14. }
  15. s.ios.deployment_target = '8.0'
  16. s.cocoapods_version = '>= 1.4.0'
  17. s.static_framework = true
  18. s.prefix_header_file = false
  19. s.source_files = [
  20. 'Firestore/Source/**/*',
  21. 'Firestore/Port/**/*',
  22. 'Firestore/Protos/nanopb/**/*.[hc]',
  23. 'Firestore/Protos/objc/**/*.[hm]',
  24. 'Firestore/core/include/**/*.{h,cc,mm}',
  25. 'Firestore/core/src/**/*.{h,cc,mm}',
  26. 'Firestore/third_party/Immutable/*.[mh]',
  27. ]
  28. s.requires_arc = [
  29. 'Firestore/Source/**/*',
  30. 'Firestore/core/src/**/*.mm',
  31. 'Firestore/third_party/Immutable/*.[mh]'
  32. ]
  33. s.exclude_files = [
  34. 'Firestore/Port/*test.cc',
  35. 'Firestore/third_party/Immutable/Tests/**',
  36. # Exclude alternate implementations for other platforms
  37. 'Firestore/core/src/firebase/firestore/util/hard_assert_stdio.cc',
  38. 'Firestore/core/src/firebase/firestore/util/log_stdio.cc',
  39. 'Firestore/core/src/firebase/firestore/util/secure_random_openssl.cc'
  40. ]
  41. s.public_header_files = 'Firestore/Source/Public/*.h'
  42. s.dependency 'FirebaseCore', '~> 5.0'
  43. s.dependency 'gRPC-ProtoRPC', '~> 1.0'
  44. s.dependency 'leveldb-library', '~> 1.18'
  45. s.dependency 'Protobuf', '~> 3.1'
  46. s.frameworks = 'MobileCoreServices'
  47. s.library = 'c++'
  48. s.pod_target_xcconfig = {
  49. 'GCC_PREPROCESSOR_DEFINITIONS' => 'GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS=1 ',
  50. 'HEADER_SEARCH_PATHS' =>
  51. '"${PODS_TARGET_SRCROOT}" ' +
  52. '"${PODS_TARGET_SRCROOT}/Firestore/third_party/abseil-cpp" ' +
  53. '"${PODS_ROOT}/nanopb" ' +
  54. '"${PODS_TARGET_SRCROOT}/Firestore/Protos/nanopb"',
  55. 'OTHER_CFLAGS' => '-DFIRFirestore_VERSION=' + s.version.to_s + ' -DPB_FIELD_16BIT'
  56. }
  57. s.prepare_command = <<-CMD
  58. # Generate a version of the config.h header suitable for building with
  59. # CocoaPods.
  60. sed '/^#cmakedefine/ d' \
  61. Firestore/core/src/firebase/firestore/util/config.h.in > \
  62. Firestore/core/src/firebase/firestore/util/config.h
  63. CMD
  64. s.subspec 'abseil-cpp' do |ss|
  65. ss.preserve_path = [
  66. 'Firestore/third_party/abseil-cpp/absl'
  67. ]
  68. ss.source_files = [
  69. 'Firestore/third_party/abseil-cpp/**/*.cc'
  70. ]
  71. ss.exclude_files = [
  72. 'Firestore/third_party/abseil-cpp/**/*_test.cc',
  73. ]
  74. ss.library = 'c++'
  75. ss.compiler_flags = '$(inherited) ' + '-Wno-comma -Wno-range-loop-analysis'
  76. end
  77. end