GoogleDataTransportCCTSupport.podspec 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107
  1. Pod::Spec.new do |s|
  2. s.name = 'GoogleDataTransportCCTSupport'
  3. s.version = '3.2.0'
  4. s.summary = 'Support library for the GoogleDataTransport CCT backend target.'
  5. s.description = <<-DESC
  6. Support library to provide event prioritization and uploading for the GoogleDataTransport CCT backend target.
  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 => 'DataTransportCCTSupport-' + s.version.to_s
  14. }
  15. s.ios.deployment_target = '8.0'
  16. s.osx.deployment_target = '10.11'
  17. s.tvos.deployment_target = '10.0'
  18. s.watchos.deployment_target = '6.0'
  19. # To develop or run the tests, >= 1.8.0 must be installed.
  20. s.cocoapods_version = '>= 1.4.0'
  21. s.static_framework = true
  22. s.prefix_header_file = false
  23. s.source_files = 'GoogleDataTransportCCTSupport/GDTCCTLibrary/**/*'
  24. s.private_header_files = 'GoogleDataTransportCCTSupport/GDTCCTLibrary/Private/*.h'
  25. s.public_header_files = 'GoogleDataTransportCCTSupport/GDTCCTLibrary/Public/*.h'
  26. s.ios.frameworks = 'SystemConfiguration', 'CoreTelephony'
  27. s.osx.frameworks = 'SystemConfiguration', 'CoreTelephony'
  28. s.tvos.frameworks = 'SystemConfiguration'
  29. s.libraries = ['z']
  30. s.dependency 'GoogleDataTransport', '~> 6.1'
  31. s.dependency 'nanopb', '~> 1.30905.0'
  32. header_search_paths = {
  33. 'HEADER_SEARCH_PATHS' => '"${PODS_TARGET_SRCROOT}/GoogleDataTransportCCTSupport/"'
  34. }
  35. s.pod_target_xcconfig = {
  36. 'GCC_C_LANGUAGE_STANDARD' => 'c99',
  37. 'GCC_TREAT_WARNINGS_AS_ERRORS' => 'YES',
  38. 'CLANG_UNDEFINED_BEHAVIOR_SANITIZER_NULLABILITY' => 'YES',
  39. 'GCC_PREPROCESSOR_DEFINITIONS' =>
  40. # The nanopb pod sets these defs, so we must too. (We *do* require 16bit
  41. # (or larger) fields, so we'd have to set at least PB_FIELD_16BIT
  42. # anyways.)
  43. 'PB_FIELD_32BIT=1 PB_NO_PACKED_STRUCTS=1 PB_ENABLE_MALLOC=1 GDTCCTSUPPORT_VERSION=' + s.version.to_s,
  44. }.merge(header_search_paths)
  45. # Test app specs
  46. if ENV['GDT_DEV'] && ENV['GDT_DEV'] == '1' then
  47. s.app_spec 'TestApp' do |app_spec|
  48. app_spec.platforms = {:ios => '8.0', :osx => '10.11', :tvos => '10.0'}
  49. app_spec.source_files = 'GoogleDataTransportCCTSupport/GDTCCTTestApp/**/*.swift'
  50. app_spec.ios.resources = ['GoogleDataTransportCCTSupport/GDTCCTTestApp/ios/*.storyboard']
  51. app_spec.macos.resources = ['GoogleDataTransportCCTSupport/GDTCCTTestApp/macos/*.storyboard']
  52. app_spec.tvos.resources = ['GoogleDataTransportCCTSupport/GDTCCTTestApp/tvos/*.storyboard']
  53. app_spec.dependency 'SwiftProtobuf'
  54. app_spec.info_plist = {
  55. 'UILaunchStoryboardName' => 'Main',
  56. 'UIMainStoryboardFile' => 'Main',
  57. 'NSMainStoryboardFile' => 'Main'
  58. }
  59. end
  60. end
  61. # Test specs
  62. s.test_spec 'Tests-Unit' do |test_spec|
  63. test_spec.platforms = {:ios => '8.0', :osx => '10.11', :tvos => '10.0'}
  64. test_spec.requires_app_host = false
  65. test_spec.source_files = 'GoogleDataTransportCCTSupport/GDTCCTTests/Unit/**/*.{h,m}'
  66. test_spec.resources = ['GoogleDataTransportCCTSupport/GDTCCTTests/Data/**/*']
  67. test_spec.pod_target_xcconfig = header_search_paths
  68. test_spec.dependency 'GCDWebServer'
  69. end
  70. s.test_spec 'Tests-Integration' do |test_spec|
  71. test_spec.platforms = {:ios => '8.0', :osx => '10.11', :tvos => '10.0'}
  72. test_spec.requires_app_host = false
  73. test_spec.source_files = 'GoogleDataTransportCCTSupport/GDTCCTTests/Integration/**/*.{h,m}'
  74. test_spec.resources = ['GoogleDataTransportCCTSupport/GDTCCTTests/Data/**/*']
  75. test_spec.pod_target_xcconfig = header_search_paths
  76. end
  77. # Monkey test specs, only enabled for development.
  78. if ENV['GDT_DEV'] && ENV['GDT_DEV'] == '1' then
  79. s.test_spec 'Tests-Monkey' do |test_spec|
  80. test_spec.platforms = {:ios => '8.0', :osx => '10.11', :tvos => '10.0'}
  81. test_spec.requires_app_host = true
  82. test_spec.app_host_name = 'GoogleDataTransportCCTSupport/TestApp'
  83. test_spec.dependency 'GoogleDataTransportCCTSupport/TestApp'
  84. test_spec.source_files = ['GoogleDataTransportCCTSupport/GDTCCTTests/Monkey/**/*.{swift}']
  85. test_spec.info_plist = {
  86. 'GDT_MONKEYTEST' => '1'
  87. }
  88. end
  89. end
  90. end