Skip to content

Commit 6e1c6c3

Browse files
committed
Cleanup
1 parent 630eeeb commit 6e1c6c3

File tree

10 files changed

+4
-172
lines changed

10 files changed

+4
-172
lines changed

Configuration.props

-5
Original file line numberDiff line numberDiff line change
@@ -220,9 +220,4 @@
220220
<AndroidAbiAndRuntimeFlavor Include="@(AndroidSupportedTargetJitAbi)" AndroidRuntime="NativeAOT" />
221221
<AndroidAbiAndRuntimeFlavor Include="@(AndroidSupportedTargetJitAbi)" AndroidRuntime="CoreCLR" />
222222
</ItemGroup>
223-
224-
<!-- TEMPORARY: to be removed once this PR is ready to be merged -->
225-
<PropertyGroup>
226-
<_LocalClrDirectory Condition=" Exists('$(AndroidToolchainDirectory)\clr') ">$(AndroidToolchainDirectory)\clr</_LocalClrDirectory>
227-
</PropertyGroup>
228223
</Project>

Makefile

-5
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ PREPARE_SCENARIO =
1515
PREPARE_CI_PR ?= 0
1616
PREPARE_CI ?= 0
1717
PREPARE_AUTOPROVISION ?= 0
18-
LOCAL_CLR ?=
1918

2019
_PREPARE_CI_MODE_PR_ARGS = --no-emoji --run-mode=CI
2120
_PREPARE_CI_MODE_ARGS = $(_PREPARE_CI_MODE_PR_ARGS) -a
@@ -66,10 +65,6 @@ ifeq ($(XA_FORCE_COMPONENT_REFRESH),true)
6665
_PREPARE_ARGS += -refresh
6766
endif
6867

69-
ifneq ($(LOCAL_CLR),)
70-
_PREPARE_ARGS += -p:_LocalClrDirectory="$(LOCAL_CLR)"
71-
endif
72-
7368
_PREPARE_ARGS += $(PREPARE_ARGS)
7469

7570
include build-tools/scripts/msbuild.mk

build-tools/xaprepare/xaprepare/Application/KnownProperties.cs

-1
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@ static class KnownProperties
3939
public const string JavaSdkDirectory = "JavaSdkDirectory";
4040
public const string JdkIncludePath = "JdkIncludePath";
4141
public const string LibZipSourceFullPath = "LibZipSourceFullPath";
42-
public const string LocalClrDirectory = "_LocalClrDirectory";
4342
public const string ManagedRuntime = "ManagedRuntime";
4443
public const string MicrosoftAndroidSdkOutDir = "MicrosoftAndroidSdkOutDir";
4544
public const string MonoCecilVersion = "MonoCecilVersion";

build-tools/xaprepare/xaprepare/Application/Properties.Defaults.cs.in

-1
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,6 @@ namespace Xamarin.Android.Prepare
4343
properties.Add (KnownProperties.JavaSdkDirectory, StripQuotes (@"@JavaSdkDirectory@"));
4444
properties.Add (KnownProperties.JdkIncludePath, StripQuotes (@"@JdkIncludePath@"));
4545
properties.Add (KnownProperties.LibZipSourceFullPath, StripQuotes (@"@LibZipSourceFullPath@"));
46-
properties.Add (KnownProperties.LocalClrDirectory, StripQuotes (@"@_LocalClrDirectory@"));
4746
properties.Add (KnownProperties.ManagedRuntime, StripQuotes (@"@ManagedRuntime@"));
4847
properties.Add (KnownProperties.MicrosoftAndroidSdkOutDir, StripQuotes (@"@MicrosoftAndroidSdkOutDir@"));
4948
properties.Add (KnownProperties.MonoCecilVersion, StripQuotes ("@MonoCecilVersion@"));

build-tools/xaprepare/xaprepare/ConfigAndData/Configurables.cs

-5
Original file line numberDiff line numberDiff line change
@@ -250,11 +250,6 @@ static string GetNetcoreAppRuntimePath (Context ctx, string androidTarget)
250250

251251
static string GetCoreClrAppRuntimePath (Context ctx, string androidTarget)
252252
{
253-
string? localClrDir = ctx.Properties.GetValue (KnownProperties.LocalClrDirectory);
254-
if (!String.IsNullOrEmpty (localClrDir)) {
255-
return Path.Combine (localClrDir, "runtimes", $"android-{androidTarget}");
256-
}
257-
258253
// TODO: The nuget id and the ref package version are guesses atm, since the CoreCLR packages don't exist yet
259254
Log.Instance.Todo ("The nuget id and the ref package version are guesses atm, since the CoreCLR packages don't exist yet");
260255
return Path.Combine (

build-tools/xaprepare/xaprepare/xaprepare.targets

-1
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,6 @@
7676
<Replacement Include="@JavaSdkDirectory@=$(JavaSdkDirectory)" />
7777
<Replacement Include="@JdkIncludePath@=$(JavaIncludePath)" />
7878
<Replacement Include="@LibZipSourceFullPath@=$(LibZipSourceFullPath)" />
79-
<Replacement Include="@_LocalClrDirectory@=$(_LocalClrDirectory)" />
8079
<Replacement Include="@ManagedRuntime@=$(ManagedRuntime)" />
8180
<Replacement Include="@MicrosoftAndroidSdkOutDir@=$(MicrosoftAndroidSdkOutDir)" />
8281
<Replacement Include="@MonoCecilVersion@=$(MonoCecilVersion)" />

src/Xamarin.Android.Build.Tasks/Tasks/MaybeUseLocalClr.cs

-149
This file was deleted.

src/Xamarin.Android.Build.Tasks/Tasks/ResolveSdksTask.cs

-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@
3030
using Microsoft.Build.Framework;
3131
using Microsoft.Build.Utilities;
3232
using System;
33-
using System.Collections.Generic;
3433
using System.IO;
3534
using System.Linq;
3635
using Microsoft.Android.Build.Tasks;

src/java-runtime/java/mono/android/MonoPackageManager.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@ public class MonoPackageManager {
2727

2828
public static void LoadApplication (Context context)
2929
{
30-
Log.w ("XAMONO", "MonoPackageManager.LoadApplication: start");
3130
synchronized (lock) {
3231
android.content.pm.ApplicationInfo runtimePackage = context.getApplicationInfo ();
3332
String[] apks = null;
@@ -66,7 +65,8 @@ public static void LoadApplication (Context context)
6665
}
6766

6867
//
69-
// Should the order change here, src/native/runtime-base/shared-constants.hh must be updated accordingly
68+
// Should the order change here, src/mono/native/runtime-base/shared-constants.hh and
69+
// src/native/clr/include/constants.hh must be updated accordingly
7070
//
7171
String[] appDirs = new String[] {filesDir, cacheDir, dataDir};
7272
boolean haveSplitApks = runtimePackage.splitSourceDirs != null && runtimePackage.splitSourceDirs.length > 0;

src/native/clr/runtime-base/android-system.cc

+2-2
Original file line numberDiff line numberDiff line change
@@ -241,9 +241,9 @@ AndroidSystem::setup_environment () noexcept
241241
var_value = "";
242242
}
243243

244-
// if constexpr (Constants::is_debug_build) {
244+
if constexpr (Constants::is_debug_build) {
245245
log_info (LOG_DEFAULT, "Setting environment variable '{}' to '{}'", var_name, var_value);
246-
// }
246+
}
247247

248248
if (setenv (var_name, var_value, 1) < 0) {
249249
log_warn (LOG_DEFAULT, "Failed to set environment variable: {}", strerror (errno));

0 commit comments

Comments
 (0)