Skip to content

Commit 4dee599

Browse files
committed
AOT profiling won't work with dynamic runtime linking
Unconditionally disable dynamic linking in the AOT profiling test
1 parent 0025d34 commit 4dee599

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

tests/MSBuildDeviceIntegration/Tests/AotProfileTests.cs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,12 @@ public void BuildBasicApplicationAndAotProfileIt ()
3333
};
3434
proj.SetAndroidSupportedAbis (DeviceAbi);
3535

36+
// Currently, AOT profiling won't work with dynamic runtime linking because the `libmono-profiler-aot.so` library from
37+
// the `mono.aotprofiler.android` package depends on `libmonosgen-2.0.so` which, when dynamic linking is enabled, simply
38+
// doesn't exist (it's linked statically into `libmonodroid.so`). AOT profiler would have to have a static library in
39+
// the nuget in order for us to support profiling in this mode.
40+
proj.SetProperty ("_AndroidEnableNativeRuntimeLinking", "False");
41+
3642
// TODO: only needed in .NET 6+
3743
// See https://github.com/dotnet/runtime/issues/56989
3844
proj.PackageReferences.Add (KnownPackages.Mono_AotProfiler_Android);

0 commit comments

Comments
 (0)