Skip to content
This repository has been archived by the owner on Jan 14, 2025. It is now read-only.

Commit

Permalink
Merge pull request #160 from xamarin/android-5.11
Browse files Browse the repository at this point in the history
Update Android bindings
  • Loading branch information
Redth authored Nov 21, 2019
2 parents 2784d33 + 24b7f3f commit f268f4b
Show file tree
Hide file tree
Showing 31 changed files with 144 additions and 12,047 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ externals
.vs/
tmp-nugets/
_._
**/Resource.designer.cs
38 changes: 23 additions & 15 deletions Facebook.Android/build.cake
Original file line number Diff line number Diff line change
Expand Up @@ -9,20 +9,20 @@ var BUILD_TIMESTAMP = DateTime.UtcNow.ToString();
var TARGET = Argument ("t", Argument ("target", "ci"));

var ARTIFACTS = new List<ArtifactInfo> {
new ArtifactInfo("facebook-android-sdk", "5.0.3"),
new ArtifactInfo("facebook-core", "5.0.3"),
new ArtifactInfo("facebook-common", "5.0.3"),
new ArtifactInfo("facebook-login", "5.0.3"),
new ArtifactInfo("facebook-share", "5.0.3"),
new ArtifactInfo("facebook-places", "5.0.3"),
new ArtifactInfo("facebook-applinks", "5.0.3"),
new ArtifactInfo("facebook-messenger", "5.0.3"),
new ArtifactInfo("facebook-android-sdk", "5.11.0"),
new ArtifactInfo("facebook-core", "5.11.0"),
new ArtifactInfo("facebook-common", "5.11.0"),
new ArtifactInfo("facebook-login", "5.11.0"),
new ArtifactInfo("facebook-share", "5.11.0"),
new ArtifactInfo("facebook-places", "5.11.0"),
new ArtifactInfo("facebook-applinks", "5.11.0"),
new ArtifactInfo("facebook-messenger", "5.11.0"),
new ArtifactInfo("facebook-livestreaming", "4.36.0"),
new ArtifactInfo("facebook-loginkit", "4.36.0"),
new ArtifactInfo("facebook-marketing", "5.0.3"),
new ArtifactInfo("facebook-marketing", "5.9.0"),
// This needs to stay preview until google play services comes out of preview
new ArtifactInfo("account-kit-sdk", "5.0.0", "5.0.0-preview"),
new ArtifactInfo("audience-network-sdk", "5.4.0"),
new ArtifactInfo("account-kit-sdk", "5.4.0"),
new ArtifactInfo("audience-network-sdk", "5.6.0"),
new ArtifactInfo("notifications", "1.0.2")
};

Expand All @@ -41,20 +41,27 @@ class ArtifactInfo
}

Task ("externals")
.WithCriteria (!FileExists ("./externals/facebook-android-sdk.aar"))
.Does (() =>
{
EnsureDirectoryExists ("./externals/");

foreach (var artifact in ARTIFACTS) {
var url = $"http://search.maven.org/remotecontent?filepath=com/facebook/android/{artifact.ArtifactId}/{artifact.Version}/{artifact.ArtifactId}-{artifact.Version}.aar";
var pomUrl = $"http://search.maven.org/remotecontent?filepath=com/facebook/android/{artifact.ArtifactId}/{artifact.Version}/{artifact.ArtifactId}-{artifact.Version}.pom";
var docUrl = $"http://search.maven.org/remotecontent?filepath=com/facebook/android/{artifact.ArtifactId}/{artifact.Version}/{artifact.ArtifactId}-{artifact.Version}-javadoc.jar";

DownloadFile(url, $"./externals/{artifact.ArtifactId}.aar");
var aar = $"./externals/{artifact.ArtifactId}.aar";
if (!FileExists (aar))
DownloadFile(url, aar);

var pom = $"./externals/{artifact.ArtifactId}.pom";
if (!FileExists (pom))
DownloadFile(pomUrl, pom);

try {
var localDocsFile = $"./externals/{artifact.ArtifactId}-javadoc.jar";
DownloadFile(docUrl, localDocsFile);
if (!FileExists (localDocsFile))
DownloadFile(docUrl, localDocsFile);

EnsureDirectoryExists ($"./externals/{artifact.ArtifactId}-docs/");
Unzip (localDocsFile, $"./externals/{artifact.ArtifactId}-docs/");
Expand Down Expand Up @@ -106,8 +113,9 @@ Task ("nuget")

MSBuild(csproj, c =>
c.SetConfiguration("Release")
.WithProperty("NoBuild", "true")
.WithProperty("PackageVersion", art.Version)
.WithProperty("PackageOutputPath", "../../output/")
.WithProperty("PackageOutputPath", MakeAbsolute((DirectoryPath)"./output/").FullPath)
.WithProperty("DesignTimeBuild", "false")
.WithTarget("Pack"));
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,8 @@
<AndroidResgenClass>Resource</AndroidResgenClass>
<AndroidResgenFile>Resources\Resource.designer.cs</AndroidResgenFile>
<AndroidApplication>True</AndroidApplication>
<AndroidUseLatestPlatformSdk>True</AndroidUseLatestPlatformSdk>
<AssemblyName>HelloFacebookSample</AssemblyName>
<TargetFrameworkVersion>v8.1</TargetFrameworkVersion>
<TargetFrameworkVersion>v9.0</TargetFrameworkVersion>
<AndroidManifest>Properties\AndroidManifest.xml</AndroidManifest>
<AndroidSupportedAbis>armeabi-v7a;x86;arm64-v8a;x86_64</AndroidSupportedAbis>
</PropertyGroup>
Expand All @@ -30,6 +29,7 @@
<WarningLevel>4</WarningLevel>
<AndroidLinkMode>None</AndroidLinkMode>
<ConsolePause>false</ConsolePause>
<AndroidDexTool>d8</AndroidDexTool>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>full</DebugType>
Expand All @@ -39,6 +39,7 @@
<WarningLevel>4</WarningLevel>
<AndroidUseSharedRuntime>false</AndroidUseSharedRuntime>
<ConsolePause>false</ConsolePause>
<AndroidDexTool>d8</AndroidDexTool>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
Expand Down Expand Up @@ -106,15 +107,12 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="Xamarin.Android.Support.Annotations" Version="27.0.2" />
<PackageReference Include="Xamarin.Android.Support.v4" Version="27.0.2" />
<PackageReference Include="Xamarin.Android.Support.v7.RecyclerView" Version="27.0.2" />
<PackageReference Include="Xamarin.Android.Support.v7.AppCompat" Version="27.0.2" />
<PackageReference Include="Xamarin.Android.Support.Annotations" Version="28.0.0.3" />
<PackageReference Include="Xamarin.Android.Support.v4" Version="28.0.0.3" />
<PackageReference Include="Xamarin.Android.Support.v7.RecyclerView" Version="28.0.0.3" />
<PackageReference Include="Xamarin.Android.Support.v7.AppCompat" Version="28.0.0.3" />

<PackageReference Include="Xamarin.GooglePlayServices.Ads" Version="60.1142.1" />

<PackageReference Include="Xam.Plugins.Android.ExoPlayer.Core" Version="2.7.3" />
<PackageReference Include="Xam.Plugins.Android.ExoPlayer.Dash" Version="2.7.3" />
<PackageReference Include="Xamarin.GooglePlayServices.Ads" Version="71.1720.1" />
</ItemGroup>

<Import Project="$(MSBuildExtensionsPath)\Xamarin\Android\Xamarin.Android.CSharp.targets" />
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.facebook.samples.hellofacebook" android:versionCode="1" android:versionName="1.0">
<uses-sdk android:minSdkVersion="14" />
<uses-sdk android:minSdkVersion="19" android:targetSdkVersion="29" />
<application android:label="@string/app_name" android:icon="@drawable/icon" android:theme="@android:style/Theme.NoTitleBar">
<activity android:name="com.facebook.FacebookActivity" android:configChanges="keyboard|keyboardHidden|screenLayout|screenSize|orientation" android:theme="@android:style/Theme.Translucent.NoTitleBar" android:label="@string/app_name" />
<provider android:authorities="com.facebook.app.FacebookContentProvider355198514515820" android:name="com.facebook.FacebookContentProvider" android:exported="true" />
Expand Down
Loading

0 comments on commit f268f4b

Please sign in to comment.