blob: f282f540bb40f4af1b8e418dd7f31a034ecf9934 [file] [log] [blame]
Brian Silverman9c614bc2016-02-15 20:20:02 -05001# 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.
6Pod::Spec.new do |s|
7 s.name = 'Protobuf'
Austin Schuh40c16522018-10-28 20:27:54 -07008 s.version = '3.6.1'
Brian Silverman9c614bc2016-02-15 20:20:02 -05009 s.summary = 'Protocol Buffers v.3 runtime library for Objective-C.'
10 s.homepage = 'https://github.com/google/protobuf'
Austin Schuh40c16522018-10-28 20:27:54 -070011 s.license = '3-Clause BSD License'
Brian Silverman9c614bc2016-02-15 20:20:02 -050012 s.authors = { 'The Protocol Buffers contributors' => 'protobuf@googlegroups.com' }
Austin Schuh40c16522018-10-28 20:27:54 -070013 s.cocoapods_version = '>= 1.0'
Brian Silverman9c614bc2016-02-15 20:20:02 -050014
15 s.source = { :git => 'https://github.com/google/protobuf.git',
16 :tag => "v#{s.version}" }
17
18 s.source_files = 'objectivec/*.{h,m}',
19 'objectivec/google/protobuf/Any.pbobjc.{h,m}',
20 'objectivec/google/protobuf/Api.pbobjc.{h,m}',
Austin Schuh40c16522018-10-28 20:27:54 -070021 'objectivec/google/protobuf/Duration.pbobjc.{h,m}',
Brian Silverman9c614bc2016-02-15 20:20:02 -050022 '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}',
Austin Schuh40c16522018-10-28 20:27:54 -070026 'objectivec/google/protobuf/Timestamp.pbobjc.{h,m}',
Brian Silverman9c614bc2016-02-15 20:20:02 -050027 'objectivec/google/protobuf/Type.pbobjc.{h,m}',
28 'objectivec/google/protobuf/Wrappers.pbobjc.{h,m}'
Brian Silverman9c614bc2016-02-15 20:20:02 -050029 # 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'
Brian Silverman9c614bc2016-02-15 20:20:02 -050032
Austin Schuh40c16522018-10-28 20:27:54 -070033 # 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' }
36
37 s.ios.deployment_target = '7.0'
Brian Silverman9c614bc2016-02-15 20:20:02 -050038 s.osx.deployment_target = '10.9'
Austin Schuh40c16522018-10-28 20:27:54 -070039 s.tvos.deployment_target = '9.0'
40 s.watchos.deployment_target = '2.0'
Brian Silverman9c614bc2016-02-15 20:20:02 -050041 s.requires_arc = false
42end