diff --git a/Example/ios/Example.xcodeproj/project.pbxproj b/Example/ios/Example.xcodeproj/project.pbxproj index ca8692dfc..1485380b4 100644 --- a/Example/ios/Example.xcodeproj/project.pbxproj +++ b/Example/ios/Example.xcodeproj/project.pbxproj @@ -8,18 +8,18 @@ /* Begin PBXBuildFile section */ 00E356F31AD99517003FC87E /* ExampleTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 00E356F21AD99517003FC87E /* ExampleTests.m */; }; - 04C93CF98C15299BF408645B /* libPods-Example.a in Frameworks */ = {isa = PBXBuildFile; fileRef = FA0C8C19B8AD52E965DD436A /* libPods-Example.a */; }; 13B07FBC1A68108700A75B9A /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB01A68108700A75B9A /* AppDelegate.m */; }; 13B07FBD1A68108700A75B9A /* LaunchScreen.xib in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB11A68108700A75B9A /* LaunchScreen.xib */; }; 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; }; 13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; }; - 13E98185F232C603113517AA /* libPods-ExampleTests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = D3002D5B6C68400B66A8B505 /* libPods-ExampleTests.a */; }; + 1A04B4A8149960C86072600F /* Pods_Example_tvOS.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 08FFD8538D174909E13ED954 /* Pods_Example_tvOS.framework */; }; 2D02E4BC1E0B4A80006451C7 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB01A68108700A75B9A /* AppDelegate.m */; }; 2D02E4BD1E0B4A84006451C7 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; }; 2D02E4BF1E0B4AB3006451C7 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; }; 2DCD954D1E0B4F2C00145EB5 /* ExampleTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 00E356F21AD99517003FC87E /* ExampleTests.m */; }; - 5461666A4D5BC8CBD836C4D4 /* libPods-Example-tvOSTests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 03B41F392E301E1D0F773015 /* libPods-Example-tvOSTests.a */; }; - BBD5336FC2A8E88E6C5C53A5 /* libPods-Example-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = DFFF1DF84DEB1ABE6230D6B8 /* libPods-Example-tvOS.a */; }; + 3F8AA2943CCB8B14A076EB40 /* Pods_Example.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A3B2AA611DDA5AD7CB6468C8 /* Pods_Example.framework */; }; + 6194FA12DAD9B87B20696BB7 /* Pods_ExampleTests.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 99484A0726D0D1355B09A912 /* Pods_ExampleTests.framework */; }; + B68837C8EA565C92D8182BE7 /* Pods_Example_tvOSTests.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C26B5791CF4F44D95CE7BFFE /* Pods_Example_tvOSTests.framework */; }; /* End PBXBuildFile section */ /* Begin PBXContainerItemProxy section */ @@ -44,7 +44,7 @@ 00E356EE1AD99517003FC87E /* ExampleTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = ExampleTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 00E356F11AD99517003FC87E /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 00E356F21AD99517003FC87E /* ExampleTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ExampleTests.m; sourceTree = ""; }; - 03B41F392E301E1D0F773015 /* libPods-Example-tvOSTests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-Example-tvOSTests.a"; sourceTree = BUILT_PRODUCTS_DIR; }; + 08FFD8538D174909E13ED954 /* Pods_Example_tvOS.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Example_tvOS.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 1338AA6DF79403E4E32C295B /* Pods-Example-tvOSTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Example-tvOSTests.release.xcconfig"; path = "Target Support Files/Pods-Example-tvOSTests/Pods-Example-tvOSTests.release.xcconfig"; sourceTree = ""; }; 13B07F961A680F5B00A75B9A /* Example.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Example.app; sourceTree = BUILT_PRODUCTS_DIR; }; 13B07FAF1A68108700A75B9A /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AppDelegate.h; path = Example/AppDelegate.h; sourceTree = ""; }; @@ -57,16 +57,16 @@ 2D02E4901E0B4A5D006451C7 /* Example-tvOSTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "Example-tvOSTests.xctest"; sourceTree = BUILT_PRODUCTS_DIR; }; 7B4B60DA1A94452FAAF2AFE8 /* Pods-Example-tvOS.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Example-tvOS.debug.xcconfig"; path = "Target Support Files/Pods-Example-tvOS/Pods-Example-tvOS.debug.xcconfig"; sourceTree = ""; }; 8444FF53BB475195E1A8C91D /* Pods-Example-tvOS.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Example-tvOS.release.xcconfig"; path = "Target Support Files/Pods-Example-tvOS/Pods-Example-tvOS.release.xcconfig"; sourceTree = ""; }; + 99484A0726D0D1355B09A912 /* Pods_ExampleTests.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_ExampleTests.framework; sourceTree = BUILT_PRODUCTS_DIR; }; + A3B2AA611DDA5AD7CB6468C8 /* Pods_Example.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Example.framework; sourceTree = BUILT_PRODUCTS_DIR; }; A50A84CC9C71E9683CA11E68 /* Pods-ExampleTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-ExampleTests.debug.xcconfig"; path = "Target Support Files/Pods-ExampleTests/Pods-ExampleTests.debug.xcconfig"; sourceTree = ""; }; - D3002D5B6C68400B66A8B505 /* libPods-ExampleTests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-ExampleTests.a"; sourceTree = BUILT_PRODUCTS_DIR; }; - DFFF1DF84DEB1ABE6230D6B8 /* libPods-Example-tvOS.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-Example-tvOS.a"; sourceTree = BUILT_PRODUCTS_DIR; }; + C26B5791CF4F44D95CE7BFFE /* Pods_Example_tvOSTests.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Example_tvOSTests.framework; sourceTree = BUILT_PRODUCTS_DIR; }; E13F5EE0D9998112AE1EAFB5 /* Pods-ExampleTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-ExampleTests.release.xcconfig"; path = "Target Support Files/Pods-ExampleTests/Pods-ExampleTests.release.xcconfig"; sourceTree = ""; }; E78F7D51D6B71F1012E0019F /* Pods-Example.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Example.debug.xcconfig"; path = "Target Support Files/Pods-Example/Pods-Example.debug.xcconfig"; sourceTree = ""; }; ED297162215061F000B7C4FE /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = System/Library/Frameworks/JavaScriptCore.framework; sourceTree = SDKROOT; }; ED2971642150620600B7C4FE /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS12.0.sdk/System/Library/Frameworks/JavaScriptCore.framework; sourceTree = DEVELOPER_DIR; }; F35C82EE8A82B25FB90E187C /* Pods-Example.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Example.release.xcconfig"; path = "Target Support Files/Pods-Example/Pods-Example.release.xcconfig"; sourceTree = ""; }; F4FE027B7AF7B41073C27B4E /* Pods-Example-tvOSTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Example-tvOSTests.debug.xcconfig"; path = "Target Support Files/Pods-Example-tvOSTests/Pods-Example-tvOSTests.debug.xcconfig"; sourceTree = ""; }; - FA0C8C19B8AD52E965DD436A /* libPods-Example.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-Example.a"; sourceTree = BUILT_PRODUCTS_DIR; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -74,7 +74,7 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( - 13E98185F232C603113517AA /* libPods-ExampleTests.a in Frameworks */, + 6194FA12DAD9B87B20696BB7 /* Pods_ExampleTests.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -82,7 +82,7 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( - 04C93CF98C15299BF408645B /* libPods-Example.a in Frameworks */, + 3F8AA2943CCB8B14A076EB40 /* Pods_Example.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -90,7 +90,7 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( - BBD5336FC2A8E88E6C5C53A5 /* libPods-Example-tvOS.a in Frameworks */, + 1A04B4A8149960C86072600F /* Pods_Example_tvOS.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -98,7 +98,7 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( - 5461666A4D5BC8CBD836C4D4 /* libPods-Example-tvOSTests.a in Frameworks */, + B68837C8EA565C92D8182BE7 /* Pods_Example_tvOSTests.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -141,10 +141,10 @@ children = ( ED297162215061F000B7C4FE /* JavaScriptCore.framework */, ED2971642150620600B7C4FE /* JavaScriptCore.framework */, - FA0C8C19B8AD52E965DD436A /* libPods-Example.a */, - DFFF1DF84DEB1ABE6230D6B8 /* libPods-Example-tvOS.a */, - 03B41F392E301E1D0F773015 /* libPods-Example-tvOSTests.a */, - D3002D5B6C68400B66A8B505 /* libPods-ExampleTests.a */, + A3B2AA611DDA5AD7CB6468C8 /* Pods_Example.framework */, + 08FFD8538D174909E13ED954 /* Pods_Example_tvOS.framework */, + C26B5791CF4F44D95CE7BFFE /* Pods_Example_tvOSTests.framework */, + 99484A0726D0D1355B09A912 /* Pods_ExampleTests.framework */, ); name = Frameworks; sourceTree = ""; @@ -230,6 +230,7 @@ 13B07F8C1A680F5B00A75B9A /* Frameworks */, 13B07F8E1A680F5B00A75B9A /* Resources */, 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */, + 095AA2D0F1F6828B47850CC6 /* [CP] Embed Pods Frameworks */, ); buildRules = ( ); @@ -373,6 +374,57 @@ shellPath = /bin/sh; shellScript = "export NODE_BINARY=node\n../node_modules/react-native/scripts/react-native-xcode.sh"; }; + 095AA2D0F1F6828B47850CC6 /* [CP] Embed Pods Frameworks */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-Example/Pods-Example-frameworks.sh", + "${BUILT_PRODUCTS_DIR}/DoubleConversion/DoubleConversion.framework", + "${BUILT_PRODUCTS_DIR}/Folly/folly.framework", + "${BUILT_PRODUCTS_DIR}/GoogleUtilities/GoogleUtilities.framework", + "${BUILT_PRODUCTS_DIR}/React-Core/React.framework", + "${BUILT_PRODUCTS_DIR}/React-DevSupport/React.framework", + "${BUILT_PRODUCTS_DIR}/React-RCTActionSheet/React.framework", + "${BUILT_PRODUCTS_DIR}/React-RCTAnimation/React.framework", + "${BUILT_PRODUCTS_DIR}/React-RCTBlob/React.framework", + "${BUILT_PRODUCTS_DIR}/React-RCTImage/React.framework", + "${BUILT_PRODUCTS_DIR}/React-RCTLinking/React.framework", + "${BUILT_PRODUCTS_DIR}/React-RCTNetwork/React.framework", + "${BUILT_PRODUCTS_DIR}/React-RCTSettings/React.framework", + "${BUILT_PRODUCTS_DIR}/React-RCTText/React.framework", + "${BUILT_PRODUCTS_DIR}/React-RCTVibration/React.framework", + "${BUILT_PRODUCTS_DIR}/React-RCTWebSocket/React.framework", + "${BUILT_PRODUCTS_DIR}/React-cxxreact/cxxreact.framework", + "${BUILT_PRODUCTS_DIR}/React-jsi/jsi.framework", + "${BUILT_PRODUCTS_DIR}/React-jsiexecutor/jsireact.framework", + "${BUILT_PRODUCTS_DIR}/React-jsinspector/jsinspector.framework", + "${BUILT_PRODUCTS_DIR}/glog/glog.framework", + "${BUILT_PRODUCTS_DIR}/nanopb/nanopb.framework", + "${BUILT_PRODUCTS_DIR}/react-native-admob/react_native_admob.framework", + "${BUILT_PRODUCTS_DIR}/yoga/yoga.framework", + ); + name = "[CP] Embed Pods Frameworks"; + outputPaths = ( + "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/DoubleConversion.framework", + "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/folly.framework", + "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/GoogleUtilities.framework", + "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/React.framework", + "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/cxxreact.framework", + "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/jsi.framework", + "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/jsireact.framework", + "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/jsinspector.framework", + "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/glog.framework", + "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/nanopb.framework", + "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/react_native_admob.framework", + "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/yoga.framework", + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Example/Pods-Example-frameworks.sh\"\n"; + showEnvVarsInLog = 0; + }; 110E645EA8D9BFBAF3F95EDF /* [CP] Check Pods Manifest.lock */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; diff --git a/Example/ios/Podfile b/Example/ios/Podfile index e85fc7c37..af5eef1d8 100644 --- a/Example/ios/Podfile +++ b/Example/ios/Podfile @@ -1,4 +1,5 @@ platform :ios, '9.0' +use_frameworks! require_relative '../node_modules/@react-native-community/cli-platform-ios/native_modules' target 'Example' do @@ -27,6 +28,8 @@ target 'Example' do pod 'glog', :podspec => '../node_modules/react-native/third-party-podspecs/glog.podspec' pod 'Folly', :podspec => '../node_modules/react-native/third-party-podspecs/Folly.podspec' + pod 'Google-Mobile-Ads-SDK', '~> 7.8' + target 'ExampleTests' do inherit! :search_paths # Pods for testing diff --git a/Example/ios/Podfile.lock b/Example/ios/Podfile.lock index b404b080b..1c3eaefad 100644 --- a/Example/ios/Podfile.lock +++ b/Example/ios/Podfile.lock @@ -86,7 +86,6 @@ PODS: - React-jsi (= 0.60.5) - React-jsinspector (0.60.5) - react-native-admob (2.0.0-beta.5): - - Google-Mobile-Ads-SDK - React-Core - React-RCTActionSheet (0.60.5): - React-Core (= 0.60.5) @@ -117,6 +116,7 @@ DEPENDENCIES: - DoubleConversion (from `../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec`) - Folly (from `../node_modules/react-native/third-party-podspecs/Folly.podspec`) - glog (from `../node_modules/react-native/third-party-podspecs/glog.podspec`) + - Google-Mobile-Ads-SDK (~> 7.8) - React (from `../node_modules/react-native/`) - React-Core (from `../node_modules/react-native/React`) - React-cxxreact (from `../node_modules/react-native/ReactCommon/cxxreact`) @@ -207,7 +207,7 @@ SPEC CHECKSUMS: React-jsi: 4d8c9efb6312a9725b18d6fc818ffc103f60fec2 React-jsiexecutor: 90ad2f9db09513fc763bc757fdc3c4ff8bde2a30 React-jsinspector: e08662d1bf5b129a3d556eb9ea343a3f40353ae4 - react-native-admob: b54436fb2eb5f5a706c49d2f33c918adcecca392 + react-native-admob: 6c8217b6e2b0317df130c6804bc150778301f93e React-RCTActionSheet: b0f1ea83f4bf75fb966eae9bfc47b78c8d3efd90 React-RCTAnimation: 359ba1b5690b1e87cc173558a78e82d35919333e React-RCTBlob: 5e2b55f76e9a1c7ae52b826923502ddc3238df24 @@ -220,6 +220,6 @@ SPEC CHECKSUMS: React-RCTWebSocket: cd932a16b7214898b6b7f788c8bddb3637246ac4 yoga: 312528f5bbbba37b4dcea5ef00e8b4033fdd9411 -PODFILE CHECKSUM: 427825d45bec91cf181bdca5a1e33480e904ef46 +PODFILE CHECKSUM: 4e567a12c0120fa5781752a0fe3f55e04addfdde COCOAPODS: 1.8.0.beta.2 diff --git a/ios/RNDFPBannerView.h b/ios/RNDFPBannerView.h index 8bc9b8d90..034469377 100644 --- a/ios/RNDFPBannerView.h +++ b/ios/RNDFPBannerView.h @@ -1,4 +1,4 @@ -#if __has_include() +#if __has_include() #import #else #import "RCTView.h" diff --git a/react-native-admob.podspec b/react-native-admob.podspec index f04623162..4e0cd3912 100644 --- a/react-native-admob.podspec +++ b/react-native-admob.podspec @@ -14,6 +14,15 @@ Pod::Spec.new do |s| s.source = { :git => 'https://github.com/sbugert/react-native-admob.git', :tag => "v#{version}" } s.source_files = 'ios/*.{h,m}' - s.dependency 'Google-Mobile-Ads-SDK' + # We can't add the Google-Mobile-Ads-SDK as a dependency, as it would prevent + # this library to be used with `use_frameworks!`. + # So instead we add the default location of the framework to the framework + # search paths, and we rely on consumers of this library to add + # Google-Mobile-Ads-SDK as a direct dependency. + s.weak_frameworks = 'GoogleMobileAds' + s.pod_target_xcconfig = { + 'FRAMEWORK_SEARCH_PATHS' => '"$(PODS_ROOT)/Google-Mobile-Ads-SDK/Frameworks/GoogleMobileAdsFramework-Current"', + } + s.dependency 'React-Core' end