FirebaseInstallations.podspec 3.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192
  1. Pod::Spec.new do |s|
  2. s.name = 'FirebaseInstallations'
  3. s.version = '7.10.0'
  4. s.summary = 'Firebase Installations'
  5. s.description = <<-DESC
  6. Firebase Installations.
  7. DESC
  8. s.homepage = 'https://firebase.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 => 'CocoaPods-' + s.version.to_s
  14. }
  15. s.social_media_url = 'https://twitter.com/Firebase'
  16. ios_deployment_target = '9.0'
  17. osx_deployment_target = '10.12'
  18. tvos_deployment_target = '10.0'
  19. watchos_deployment_target = '6.0'
  20. s.ios.deployment_target = ios_deployment_target
  21. s.osx.deployment_target = osx_deployment_target
  22. s.tvos.deployment_target = tvos_deployment_target
  23. s.watchos.deployment_target = watchos_deployment_target
  24. s.cocoapods_version = '>= 1.4.0'
  25. s.prefix_header_file = false
  26. base_dir = "FirebaseInstallations/Source/"
  27. s.source_files = [
  28. base_dir + 'Library/**/*.[mh]',
  29. 'FirebaseCore/Sources/Private/*.h',
  30. ]
  31. s.public_header_files = [
  32. base_dir + 'Library/Public/FirebaseInstallations/*.h',
  33. ]
  34. s.framework = 'Security'
  35. s.dependency 'FirebaseCore', '~> 7.0'
  36. s.dependency 'PromisesObjC', '~> 1.2'
  37. s.dependency 'GoogleUtilities/Environment', '~> 7.0'
  38. s.dependency 'GoogleUtilities/UserDefaults', '~> 7.0'
  39. preprocessor_definitions = ''
  40. if ENV['FIS_ALLOWS_INCOMPATIBLE_IID_VERSION'] && ENV['FIS_ALLOWS_INCOMPATIBLE_IID_VERSION'] == '1' then
  41. # Disable FirebaseInstanceID compatibility assert to test IID migration.
  42. preprocessor_definitions += ' FIR_INSTALLATIONS_ALLOWS_INCOMPATIBLE_IID_VERSION=1'
  43. end
  44. s.pod_target_xcconfig = {
  45. 'GCC_C_LANGUAGE_STANDARD' => 'c99',
  46. 'GCC_PREPROCESSOR_DEFINITIONS' => preprocessor_definitions,
  47. 'HEADER_SEARCH_PATHS' => '"${PODS_TARGET_SRCROOT}"'
  48. }
  49. s.test_spec 'unit' do |unit_tests|
  50. unit_tests.scheme = { :code_coverage => true }
  51. unit_tests.platforms = {
  52. :ios => ios_deployment_target,
  53. :osx => osx_deployment_target,
  54. :tvos => tvos_deployment_target
  55. }
  56. unit_tests.source_files = base_dir + 'Tests/Unit/*.[mh]',
  57. base_dir + 'Tests/Utils/*.[mh]'
  58. unit_tests.resources = base_dir + 'Tests/Fixture/**/*'
  59. unit_tests.requires_app_host = true
  60. unit_tests.dependency 'OCMock'
  61. if ENV['FIS_IID_MIGRATION_TESTING'] && ENV['FIS_IID_MIGRATION_TESTING'] == '1' then
  62. unit_tests.source_files += base_dir + 'Tests/Unit/IIDStoreTests/*.[mh]'
  63. unit_tests.dependency 'FirebaseInstanceID', '~> 4.2.0' # The version before FirebaseInstanceID updated to use FirebaseInstallations under the hood.
  64. end
  65. end
  66. s.test_spec 'integration' do |int_tests|
  67. int_tests.scheme = { :code_coverage => true }
  68. int_tests.platforms = {:ios => '9.0', :osx => '10.12', :tvos => '10.0'}
  69. int_tests.source_files = base_dir + 'Tests/Integration/**/*.[mh]'
  70. int_tests.resources = base_dir + 'Tests/Resources/**/*'
  71. if ENV['FIS_INTEGRATION_TESTS_REQUIRED'] && ENV['FIS_INTEGRATION_TESTS_REQUIRED'] == '1' then
  72. int_tests.pod_target_xcconfig = {
  73. 'GCC_PREPROCESSOR_DEFINITIONS' =>
  74. 'FIR_INSTALLATIONS_INTEGRATION_TESTS_REQUIRED=1'
  75. }
  76. end
  77. int_tests.requires_app_host = true
  78. int_tests.dependency 'OCMock'
  79. end
  80. end