blob: f37de25baa0503b015085abbb74f99bbec4fbe63 [file] [log] [blame]
Jorge Canizales249483e2015-06-01 19:55:27 -07001# This file describes to Cocoapods how to integrate the Objective-C runtime into a dependent
2# project.
3# Despite this file being specific to Objective-C, it needs to be on the root of the repository.
4# Otherwise, Cocoapods gives trouble like not picking up the license file correctly, or not letting
5# dependent projects use the :git notation to refer to the library.
Jorge Canizales687a5fe2015-05-13 19:54:55 -07006Pod::Spec.new do |s|
7 s.name = 'Protobuf'
Paul Yang655310c2019-08-05 10:07:28 -07008 s.version = '3.9.1'
Jorge Canizales687a5fe2015-05-13 19:54:55 -07009 s.summary = 'Protocol Buffers v.3 runtime library for Objective-C.'
Feng Xiaoafe98de2018-08-22 11:55:30 -070010 s.homepage = 'https://github.com/protocolbuffers/protobuf'
Sebastian Schuberth902af082017-02-28 09:58:24 +010011 s.license = '3-Clause BSD License'
Jorge Canizales592c44f2015-05-14 14:16:40 -070012 s.authors = { 'The Protocol Buffers contributors' => 'protobuf@googlegroups.com' }
Thomas Van Lenten7da023b2016-05-09 13:53:20 -040013 s.cocoapods_version = '>= 1.0'
Jorge Canizales687a5fe2015-05-13 19:54:55 -070014
Feng Xiaoafe98de2018-08-22 11:55:30 -070015 s.source = { :git => 'https://github.com/protocolbuffers/protobuf.git',
Jorge Canizalesf492dd82016-02-10 19:19:17 -080016 :tag => "v#{s.version}" }
17
TeBoringfe982642015-08-26 23:55:33 -070018 s.source_files = 'objectivec/*.{h,m}',
19 'objectivec/google/protobuf/Any.pbobjc.{h,m}',
20 'objectivec/google/protobuf/Api.pbobjc.{h,m}',
Thomas Van Lentenbe0d7f62016-06-27 14:24:59 -040021 'objectivec/google/protobuf/Duration.pbobjc.{h,m}',
TeBoringfe982642015-08-26 23:55:33 -070022 'objectivec/google/protobuf/Empty.pbobjc.{h,m}',
23 'objectivec/google/protobuf/FieldMask.pbobjc.{h,m}',
24 'objectivec/google/protobuf/SourceContext.pbobjc.{h,m}',
25 'objectivec/google/protobuf/Struct.pbobjc.{h,m}',
Thomas Van Lentenbe0d7f62016-06-27 14:24:59 -040026 'objectivec/google/protobuf/Timestamp.pbobjc.{h,m}',
Jorge Canizalesaf66e902015-09-04 13:16:40 -070027 'objectivec/google/protobuf/Type.pbobjc.{h,m}',
TeBoringfe982642015-08-26 23:55:33 -070028 'objectivec/google/protobuf/Wrappers.pbobjc.{h,m}'
TeBoringfe982642015-08-26 23:55:33 -070029 # The following would cause duplicate symbol definitions. GPBProtocolBuffers is expected to be
30 # left out, as it's an umbrella implementation file.
31 s.exclude_files = 'objectivec/GPBProtocolBuffers.m'
Thomas Van Lenten7da023b2016-05-09 13:53:20 -040032
33 # Set a CPP symbol so the code knows to use framework imports.
34 s.user_target_xcconfig = { 'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS=1' }
35 s.pod_target_xcconfig = { 'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) GPB_USE_PROTOBUF_FRAMEWORK_IMPORTS=1' }
Jorge Canizales687a5fe2015-05-13 19:54:55 -070036
Paul Yang7f3e2372017-01-31 09:17:32 -080037 s.ios.deployment_target = '7.0'
Bo Yangd58e95b2015-07-22 14:54:52 -070038 s.osx.deployment_target = '10.9'
Thomas Van Lenten6ecf38f2017-06-14 15:56:41 -040039 s.tvos.deployment_target = '9.0'
Thomas Van Lenten584917f2016-08-17 16:52:06 -040040 s.watchos.deployment_target = '2.0'
Jorge Canizales687a5fe2015-05-13 19:54:55 -070041 s.requires_arc = false
42end