require "json" package = JSON.parse(File.read(File.join(__dir__, "package.json"))) Pod::Spec.new do |s| s.name = "react-native-bigcrunch-ads" s.version = package["version"] s.summary = package["description"] s.description = <<-DESC BigCrunch Mobile Ads SDK for React Native - Simplified in-app advertising with S2S demand and Google Ad Manager DESC s.homepage = "https://github.com/bigcrunch/mobile-ads-sdk" s.license = "MIT" s.authors = { "BigCrunch" => "support@bigcrunch.com" } s.platforms = { :ios => "13.0" } s.source = { :git => "https://github.com/bigcrunch/mobile-ads-sdk.git", :tag => "#{s.version}" } s.source_files = "ios/**/*.{h,c,cc,cpp,m,mm,swift}" s.requires_arc = true s.dependency "React" s.dependency "Google-Mobile-Ads-SDK" # When installed from npm, BigCrunchAds sources are bundled in ios/BigCrunchAds/Sources/ # (copied by prepack). In local dev, that directory is empty and the pod is loaded # separately via the app's Podfile — so declare the dependency only when not bundled. bundled_sources = Dir.glob(File.join(__dir__, "ios", "BigCrunchAds", "Sources", "**", "*.swift")) if bundled_sources.empty? s.dependency "BigCrunchAds" end s.swift_version = "5.9" end