@@ -6,27 +6,44 @@ SPDX-License-Identifier: MIT
6
6
<PropertyGroup >
7
7
<!-- enable target framework net* (.NET >= 5.0) by default -->
8
8
<EnableTargetFrameworkDotNet >true</EnableTargetFrameworkDotNet >
9
- <!-- enable target framework netcoreapp* by default -- >
10
- <EnableTargetFrameworkNetCoreApp >true</EnableTargetFrameworkNetCoreApp >
9
+ <EnableTargetFrameworkDotNet60 >true</ EnableTargetFrameworkDotNet60 >
10
+ <EnableTargetFrameworkDotNet80 >true</EnableTargetFrameworkDotNet80 >
11
11
<!-- enable target framework net* (.NET Framework/Mono) by default -->
12
12
<EnableTargetFrameworkNetFx >true</EnableTargetFrameworkNetFx >
13
13
</PropertyGroup >
14
14
15
+ <!--
16
+ Note: RuntimeInformation.RuntimeIdentifier on >= .NET 8 has been changed to return 'linux-x64' instead of 'ubuntu.20.04-x64'.
17
+ RuntimeInformation.OSDescription still returns 'Ubuntu 22.04' on >= .NET 8.
18
+ -->
19
+
15
20
<!-- On Ubuntu 22.04 -->
16
21
<PropertyGroup
17
- Condition =" $([System.Runtime.InteropServices.RuntimeInformation]::RuntimeIdentifier.StartsWith('ubuntu.22.04')) "
22
+ Condition ="
23
+ $([System.Runtime.InteropServices.RuntimeInformation]::RuntimeIdentifier.StartsWith('ubuntu.22.04')) or
24
+ $([System.Runtime.InteropServices.RuntimeInformation]::OSDescription.StartsWith('Ubuntu 22.04'))
25
+ "
18
26
>
19
- <!-- disable .NET Core (cannot run .NET Core on Ubuntu 22.04) -->
20
- <EnableTargetFrameworkNetCoreApp >false</EnableTargetFrameworkNetCoreApp >
21
27
<!-- disable Mono (test runner not working on local environment?) -->
22
- <EnableTargetFrameworkNetFx >false</EnableTargetFrameworkNetFx >
28
+ <EnableTargetFrameworkNetFx Condition = " '$(GITHUB_ACTIONS)' != 'true' " >false</EnableTargetFrameworkNetFx >
23
29
</PropertyGroup >
24
30
25
- <!-- On Ubuntu 20 .04 -->
31
+ <!-- On Ubuntu 24 .04 -->
26
32
<PropertyGroup
27
- Condition =" $([System.Runtime.InteropServices.RuntimeInformation]::RuntimeIdentifier.StartsWith('ubuntu.20.04')) "
33
+ Condition ="
34
+ $([System.Runtime.InteropServices.RuntimeInformation]::RuntimeIdentifier.StartsWith('ubuntu.24.04')) or
35
+ $([System.Runtime.InteropServices.RuntimeInformation]::OSDescription.StartsWith('Ubuntu 24.04'))
36
+ "
28
37
>
29
- <!-- enable Mono on GitHub Actions -->
30
- <EnableTargetFrameworkNetFx Condition =" '$(GITHUB_ACTIONS)' == 'true' " >true</EnableTargetFrameworkNetFx >
38
+ <!-- disable net6.0 on GitHub Actions Ubuntu 24.04 runner images -->
39
+ <EnableTargetFrameworkDotNet60 Condition =" '$(GITHUB_ACTIONS)' == 'true' " >false</EnableTargetFrameworkDotNet60 >
40
+ <!-- disable Mono on GitHub Actions Ubuntu 24.04 runner images -->
41
+ <EnableTargetFrameworkNetFx Condition =" '$(GITHUB_ACTIONS)' == 'true' " >false</EnableTargetFrameworkNetFx >
42
+ </PropertyGroup >
43
+
44
+ <!-- On MacOS -->
45
+ <PropertyGroup Condition =" $([System.OperatingSystem]::IsMacOS())" >
46
+ <!-- disable net6.0 on GitHub Actions MacOS runner images -->
47
+ <EnableTargetFrameworkDotNet60 Condition =" '$(GITHUB_ACTIONS)' == 'true' " >false</EnableTargetFrameworkDotNet60 >
31
48
</PropertyGroup >
32
49
</Project >
0 commit comments