GoogleDataTransport.podspec 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
  1. Pod::Spec.new do |s|
  2. s.name = 'GoogleDataTransport'
  3. s.version = '3.3.0'
  4. s.summary = 'Google iOS SDK data transport.'
  5. s.description = <<-DESC
  6. Shared library for iOS SDK data transport needs.
  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 => 'DataTransport-' + 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.beta.1 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 = 'GoogleDataTransport/GDTCORLibrary/**/*'
  24. s.public_header_files = 'GoogleDataTransport/GDTCORLibrary/Public/*.h'
  25. s.private_header_files = 'GoogleDataTransport/GDTCORLibrary/Private/*.h'
  26. header_search_paths = {
  27. 'HEADER_SEARCH_PATHS' => '"${PODS_TARGET_SRCROOT}/GoogleDataTransport/"'
  28. }
  29. s.pod_target_xcconfig = {
  30. 'GCC_C_LANGUAGE_STANDARD' => 'c99',
  31. 'GCC_TREAT_WARNINGS_AS_ERRORS' => 'YES',
  32. 'CLANG_UNDEFINED_BEHAVIOR_SANITIZER_NULLABILITY' => 'YES',
  33. 'GCC_PREPROCESSOR_DEFINITIONS' => 'GDTCOR_VERSION=' + s.version.to_s
  34. }.merge(header_search_paths)
  35. common_test_sources = ['GoogleDataTransport/GDTCORTests/Common/**/*.{h,m}']
  36. # Test app specs
  37. if ENV['GDT_DEV'] && ENV['GDT_DEV'] == '1' then
  38. s.app_spec 'TestApp' do |app_spec|
  39. app_spec.platforms = {:ios => '8.0', :osx => '10.11', :tvos => '10.0'}
  40. app_spec.source_files = 'GoogleDataTransport/GDTTestApp/*.swift'
  41. app_spec.ios.resources = ['GoogleDataTransport/GDTTestApp/ios/*.storyboard']
  42. app_spec.macos.resources = ['GoogleDataTransport/GDTTestApp/macos/*.storyboard']
  43. app_spec.tvos.resources = ['GoogleDataTransport/GDTTestApp/tvos/*.storyboard']
  44. app_spec.info_plist = {
  45. 'UILaunchStoryboardName' => 'Main',
  46. 'UIMainStoryboardFile' => 'Main',
  47. 'NSMainStoryboardFile' => 'Main'
  48. }
  49. end
  50. end
  51. # Unit test specs
  52. s.test_spec 'Tests-Unit' do |test_spec|
  53. test_spec.platforms = {:ios => '8.0', :osx => '10.11', :tvos => '10.0'}
  54. test_spec.requires_app_host = false
  55. test_spec.source_files = ['GoogleDataTransport/GDTCORTests/Unit/**/*.{h,m}'] + common_test_sources
  56. test_spec.pod_target_xcconfig = header_search_paths
  57. end
  58. s.test_spec 'Tests-Lifecycle' do |test_spec|
  59. test_spec.platforms = {:ios => '8.0', :osx => '10.11', :tvos => '10.0'}
  60. test_spec.requires_app_host = false
  61. test_spec.source_files = ['GoogleDataTransport/GDTCORTests/Lifecycle/**/*.{h,m}'] + common_test_sources
  62. test_spec.pod_target_xcconfig = header_search_paths
  63. end
  64. # Integration test specs
  65. s.test_spec 'Tests-Integration' do |test_spec|
  66. test_spec.platforms = {:ios => '8.0', :osx => '10.11', :tvos => '10.0'}
  67. test_spec.requires_app_host = false
  68. test_spec.source_files = ['GoogleDataTransport/GDTCORTests/Integration/**/*.{h,m}'] + common_test_sources
  69. test_spec.pod_target_xcconfig = header_search_paths
  70. test_spec.dependency 'GCDWebServer'
  71. end
  72. # Monkey test specs TODO(mikehaney24): Uncomment when travis is running >= cocoapods-1.8.0
  73. if ENV['GDT_DEV'] && ENV['GDT_DEV'] == '1' then
  74. s.test_spec 'Tests-Monkey' do |test_spec|
  75. test_spec.platforms = {:ios => '8.0', :osx => '10.11', :tvos => '10.0'}
  76. test_spec.requires_app_host = true
  77. test_spec.app_host_name = 'GoogleDataTransport/TestApp'
  78. test_spec.dependency 'GoogleDataTransport/TestApp'
  79. test_spec.source_files = ['GoogleDataTransport/GDTCORTests/Monkey/**/*.{swift}']
  80. test_spec.info_plist = {
  81. 'GDT_MONKEYTEST' => '1'
  82. }
  83. end
  84. end
  85. end