194a1f676SEric Samelsonrequire 'json' 294a1f676SEric Samelson 394a1f676SEric Samelsonpackage = JSON.parse(File.read(File.join(__dir__, '..', 'package.json'))) 494a1f676SEric Samelson 594a1f676SEric SamelsonPod::Spec.new do |s| 694a1f676SEric Samelson s.name = 'EXStructuredHeaders' 794a1f676SEric Samelson s.version = package['version'] 894a1f676SEric Samelson s.summary = package['description'] 994a1f676SEric Samelson s.description = package['description'] 1094a1f676SEric Samelson s.license = package['license'] 1194a1f676SEric Samelson s.author = package['author'] 1294a1f676SEric Samelson s.homepage = package['homepage'] 13*ef901781SDouglas Lowder s.platforms = { :ios => '13.0', :tvos => '13.0' } 1494a1f676SEric Samelson s.source = { git: 'https://github.com/expo/expo.git' } 159886c0aaSKudo Chien s.static_framework = true 1694a1f676SEric Samelson 17c80edf39SKudo Chien # Swift/Objective-C compatibility 18c80edf39SKudo Chien s.pod_target_xcconfig = { 19c80edf39SKudo Chien 'DEFINES_MODULE' => 'YES' 20c80edf39SKudo Chien } 21c80edf39SKudo Chien 2294a1f676SEric Samelson if !$ExpoUseSources&.include?(package['name']) && ENV['EXPO_USE_SOURCE'].to_i == 0 && File.exist?("#{s.name}.xcframework") && Gem::Version.new(Pod::VERSION) >= Gem::Version.new('1.10.0') 2394a1f676SEric Samelson s.source_files = "#{s.name}/**/*.h" 2494a1f676SEric Samelson s.vendored_frameworks = "#{s.name}.xcframework" 2594a1f676SEric Samelson else 2694a1f676SEric Samelson s.source_files = "#{s.name}/**/*.{h,m}" 2794a1f676SEric Samelson end 2894a1f676SEric Samelson 2994a1f676SEric Samelson s.test_spec 'Tests' do |test_spec| 30318e29d7STomasz Sapeta test_spec.source_files = 'Tests/*.{h,m,swift}' 3194a1f676SEric Samelson end 3294a1f676SEric Samelsonend 33