Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
29 changes: 29 additions & 0 deletions .github/workflows/package-cpp-sdk
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Package C++ SDK'

on:
workflow_dispatch:
inputs:
commitId:
description: 'commit ID to package'

jobs:
build:

runs-on: ubuntu-latest

steps:
- name: Fetch binutils source
uses: boyeborg/fetch-url-action@v1.1
with:
url: https://ftpmirror.gnu.org/binutils/binutils-2.34.tar.xz
- name: untar binutils source
run: tar -xvzf binutils-2.34.tar.xz
- name: configure binutils
run: ./configure --enable-targets=all --prefix=/tmp/bin
working-directory: ./binutils-2.34
- name: make binutils
run: make
working-directory: ./binutils-2.34
- name: install binutils in /tmp/bin
run: make install
working-directory: ./binutils-2.34
57 changes: 57 additions & 0 deletions admob/tools/ios/testapp/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
Firebase AdMob iOS Test App
===========================

The Firebase AdMob iOS test app is designed to enable implementing, modifying,
and debugging API features directly in Xcode.

Getting Started
---------------

- Get the code:

git5 init
git5-track-p4-depot-paths //depot_firebase_cpp/admob/client/cpp/tools/ios/testapp/p4_depot_paths
git5 sync

- Create the following symlinks (DO NOT check these in to google3 -- they should be added to your
.gitignore):

NOTE: Firebase changed their includes from `include` to `src/include`.
These soft links work around the issue.

GOOGLE3_PATH=~/path/to/git5/repo/google3 # Change to your google3 path
ln -s $GOOGLE3_PATH/firebase/app/client/cpp/src/include/ $GOOGLE3_PATH/firebase/app/client/cpp/include
ln -s $GOOGLE3_PATH/firebase/admob/client/cpp/src/include/ $GOOGLE3_PATH/firebase/admob/client/cpp/include

Setting up the App
------------------

- In Project Navigator, add the GoogleMobileAds.framework to the Frameworks
testapp project.
- Update the following files:
- google3/firebase/admob/client/cpp/src/common/admob_common.cc
- Comment out the following code:

/*
FIREBASE_APP_REGISTER_CALLBACKS(admob,
{
if (app == ::firebase::App::GetInstance()) {
return firebase::admob::Initialize(*app);
}
return kInitResultSuccess;
},
{
if (app == ::firebase::App::GetInstance()) {
firebase::admob::Terminate();
}
});
*/

- google3/firebase/admob/client/cpp/src/include/firebase/admob.h
- Comment out the following code:

/*
#if !defined(DOXYGEN) && !defined(SWIG)
FIREBASE_APP_REGISTER_CALLBACKS_REFERENCE(admob)
#endif // !defined(DOXYGEN) && !defined(SWIG)
*/
7 changes: 7 additions & 0 deletions admob/tools/ios/testapp/p4_depot_paths
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Run the following command to git5 track the required directories for the
# Firebase-AdMob iOS test app:
#
# $ git5-track-p4-depot-paths //depot_firebase_cpp/admob/client/cpp/tools/ios/testapp/p4_depot_paths

//depot_firebase_cpp/app/...
//depot_firebase_cpp/admob/...
524 changes: 524 additions & 0 deletions admob/tools/ios/testapp/testapp.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

11 changes: 11 additions & 0 deletions admob/tools/ios/testapp/testapp/AppDelegate.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
// Copyright © 2016 Google. All rights reserved.

@import GoogleMobileAds;

#import <UIKit/UIKit.h>

@interface AppDelegate : UIResponder <UIApplicationDelegate>

@property(nonatomic, strong) UIWindow *window;

@end
16 changes: 16 additions & 0 deletions admob/tools/ios/testapp/testapp/AppDelegate.m
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
// Copyright © 2016 Google. All rights reserved.

#import "AppDelegate.h"

@interface AppDelegate ()

@end

@implementation AppDelegate

- (BOOL)application:(UIApplication *)application
didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
return YES;
}

@end
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
{
"images" : [
{
"idiom" : "iphone",
"size" : "29x29",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "29x29",
"scale" : "3x"
},
{
"idiom" : "iphone",
"size" : "40x40",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "40x40",
"scale" : "3x"
},
{
"idiom" : "iphone",
"size" : "60x60",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "60x60",
"scale" : "3x"
},
{
"idiom" : "ipad",
"size" : "29x29",
"scale" : "1x"
},
{
"idiom" : "ipad",
"size" : "29x29",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "40x40",
"scale" : "1x"
},
{
"idiom" : "ipad",
"size" : "40x40",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "76x76",
"scale" : "1x"
},
{
"idiom" : "ipad",
"size" : "76x76",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "83.5x83.5",
"scale" : "2x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
6 changes: 6 additions & 0 deletions admob/tools/ios/testapp/testapp/Assets.xcassets/Contents.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"info" : {
"version" : 1,
"author" : "xcode"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
{
"images" : [
{
"orientation" : "portrait",
"idiom" : "ipad",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "1x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "1x"
},
{
"orientation" : "portrait",
"idiom" : "ipad",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "2x"
},
{
"orientation" : "landscape",
"idiom" : "ipad",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "2x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
27 changes: 27 additions & 0 deletions admob/tools/ios/testapp/testapp/Base.lproj/LaunchScreen.storyboard
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="10116" systemVersion="15E65" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" initialViewController="01J-lp-oVM">
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="10085"/>
</dependencies>
<scenes>
<!--View Controller-->
<scene sceneID="EHf-IW-A2E">
<objects>
<viewController id="01J-lp-oVM" sceneMemberID="viewController">
<layoutGuides>
<viewControllerLayoutGuide type="top" id="Llm-lL-Icb"/>
<viewControllerLayoutGuide type="bottom" id="xb3-aO-Qok"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="Ze5-6b-2t3">
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
</view>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="iYj-Kq-Ea1" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="28.266666666666666" y="355"/>
</scene>
</scenes>
</document>
27 changes: 27 additions & 0 deletions admob/tools/ios/testapp/testapp/Base.lproj/Main.storyboard
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="10116" systemVersion="15E65" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" initialViewController="BYZ-38-t0r">
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="10085"/>
</dependencies>
<scenes>
<!--View Controller-->
<scene sceneID="tne-QT-ifu">
<objects>
<viewController id="BYZ-38-t0r" customClass="ViewController" sceneMemberID="viewController">
<layoutGuides>
<viewControllerLayoutGuide type="top" id="y3c-jy-aDJ"/>
<viewControllerLayoutGuide type="bottom" id="wfy-db-euE"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="8bC-Xf-vdC">
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
</view>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="dkx-z0-nzr" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="437.33333333333331" y="710.47333333333336"/>
</scene>
</scenes>
</document>
50 changes: 50 additions & 0 deletions admob/tools/ios/testapp/testapp/Info.plist
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>NSAppTransportSecurity</key>
<dict>
<key>NSAllowsArbitraryLoads</key>
<true/>
</dict>
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleVersion</key>
<string>1</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>UILaunchStoryboardName</key>
<string>LaunchScreen</string>
<key>UIMainStoryboardFile</key>
<string>Main</string>
<key>UIRequiredDeviceCapabilities</key>
<array>
<string>armv7</string>
</array>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
<key>UISupportedInterfaceOrientations~ipad</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
</dict>
</plist>
8 changes: 8 additions & 0 deletions admob/tools/ios/testapp/testapp/ViewController.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
// Copyright © 2016 Google. All rights reserved.

#import <GLKit/GLKit.h>
#import <UIKit/UIKit.h>

@interface ViewController : UIViewController

@end
Loading