• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1source 'https://github.com/CocoaPods/Specs.git'
2platform :ios, '10.0'
3
4install! 'cocoapods', :deterministic_uuids => false
5
6# Location of gRPC's repo root relative to this file.
7GRPC_LOCAL_SRC = '../../../../..'
8
9# Install the dependencies in the main target plus all test targets.
10target 'CFStreamTests' do
11  pod 'gRPC-Core', :path => GRPC_LOCAL_SRC
12  pod 'BoringSSL-GRPC', :podspec => "#{GRPC_LOCAL_SRC}/src/objective-c", :inhibit_warnings => true
13end
14
15post_install do |installer|
16  installer.pods_project.targets.each do |target|
17    target.build_configurations.each do |config|
18      config.build_settings['GCC_TREAT_WARNINGS_AS_ERRORS'] = 'YES'
19    end
20
21    # CocoaPods creates duplicated library targets of gRPC-Core when the test targets include
22    # non-default subspecs of gRPC-Core. All of these library targets start with prefix 'gRPC-Core'
23    # and require the same error suppresion.
24    if target.name.start_with?('gRPC-Core')
25      target.build_configurations.each do |config|
26        # TODO(zyc): Remove this setting after the issue is resolved
27        # GPR_UNREACHABLE_CODE causes "Control may reach end of non-void
28        # function" warning
29        config.build_settings['GCC_WARN_ABOUT_RETURN_TYPE'] = 'NO'
30        # Abseil isn't free from the following warning
31        config.build_settings['GCC_WARN_64_TO_32_BIT_CONVERSION'] = 'NO'
32      end
33    end
34  end
35end
36