From 410b287e30cd14e0d91baa197889034d470a6048 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Laban?= Date: Fri, 15 Nov 2024 10:56:32 -0500 Subject: [PATCH 1/6] fix(wasm): workaround for invalid net9-browserwasm library detection (cherry picked from commit 9bd0c1d4408b9a3913f079cfa131f985a74b6432) --- .../test-scripts/run-net7-template-linux.ps1 | 3 ++ .../run-netcore-mobile-template-tests.ps1 | 3 ++ .../5.3/uno53net9Lib/Class1.cs | 6 +++ .../5.3/uno53net9Lib/global.json | 8 ++++ .../5.3/uno53net9Lib/uno53net9Lib.csproj | 41 +++++++++++++++++++ src/Uno.Sdk/targets/Uno.Common.Wasm.targets | 3 ++ 6 files changed, 64 insertions(+) create mode 100644 src/SolutionTemplate/5.3/uno53net9Lib/Class1.cs create mode 100644 src/SolutionTemplate/5.3/uno53net9Lib/global.json create mode 100644 src/SolutionTemplate/5.3/uno53net9Lib/uno53net9Lib.csproj diff --git a/build/test-scripts/run-net7-template-linux.ps1 b/build/test-scripts/run-net7-template-linux.ps1 index 7054ce2dc355..2ca5a48c4e7f 100644 --- a/build/test-scripts/run-net7-template-linux.ps1 +++ b/build/test-scripts/run-net7-template-linux.ps1 @@ -80,6 +80,9 @@ $projects = # 5.3 Blank with net9 @(3, "5.3/uno53net9blank/uno53net9blank/uno53net9blank.csproj", @(), @()) + # 5.3 lib + @(2, "5.3/uno53net9blank/uno53net9Lib/uno53net9Lib.csproj", @(), @()) + # 5.3 blank publish testing # Disabled for LXD setup issues # @(2, "5.3/uno53net9blank/uno53net9blank/uno53net9blank.csproj", @("-f:net9.0-desktop", "-p:SelfContained=true", "-p:PackageFormat=snap"), @("Publish")) diff --git a/build/test-scripts/run-netcore-mobile-template-tests.ps1 b/build/test-scripts/run-netcore-mobile-template-tests.ps1 index 376a9cb1da84..e7ef8ba11138 100644 --- a/build/test-scripts/run-netcore-mobile-template-tests.ps1 +++ b/build/test-scripts/run-netcore-mobile-template-tests.ps1 @@ -338,6 +338,9 @@ $projects = @(3, "5.3/uno53net9blank/uno53net9blank/uno53net9blank.csproj", @("-f", "net9.0-desktop"), @("macOS", "NetCore")), @(3, "5.3/uno53net9blank/uno53net9blank/uno53net9blank.csproj", @("-f", "net9.0-desktop", $sdkFeatures), @("macOS", "NetCore")), + # 5.3 Library + @(3, "5.3/uno53net9Lib/uno53net9Lib/uno53net9Lib.csproj", @(), @("macOS", "NetCore")), + # Default mode for the template is WindowsAppSDKSelfContained=true, which requires specifying a target platform. @(4, "5.2/uno52AppWithLib/uno52AppWithLib/uno52AppWithLib.csproj", @("-p:Platform=x86" , "-p:TargetFramework=net8.0-windows10.0.26100"), @()), diff --git a/src/SolutionTemplate/5.3/uno53net9Lib/Class1.cs b/src/SolutionTemplate/5.3/uno53net9Lib/Class1.cs new file mode 100644 index 000000000000..7066a6320a7d --- /dev/null +++ b/src/SolutionTemplate/5.3/uno53net9Lib/Class1.cs @@ -0,0 +1,6 @@ +namespace uno52Lib; + +public class Class1 +{ +} + diff --git a/src/SolutionTemplate/5.3/uno53net9Lib/global.json b/src/SolutionTemplate/5.3/uno53net9Lib/global.json new file mode 100644 index 000000000000..df83353d73bc --- /dev/null +++ b/src/SolutionTemplate/5.3/uno53net9Lib/global.json @@ -0,0 +1,8 @@ +{ + "sdk": { + "allowPrerelease": true + }, + "msbuild-sdks": { + "Uno.Sdk.Private": "5.2.0-dev.2002" + } +} diff --git a/src/SolutionTemplate/5.3/uno53net9Lib/uno53net9Lib.csproj b/src/SolutionTemplate/5.3/uno53net9Lib/uno53net9Lib.csproj new file mode 100644 index 000000000000..1677aeb2ef9b --- /dev/null +++ b/src/SolutionTemplate/5.3/uno53net9Lib/uno53net9Lib.csproj @@ -0,0 +1,41 @@ + + + net9.0;net9.0-ios;net9.0-maccatalyst;net9.0-windows10.0.19041;net9.0-browserwasm;net9.0-desktop + + + $(TargetFrameworks);net9.0-android + + + $(TargetFrameworks.Replace('net9.0-android','')) + $(TargetFrameworks.Replace('net9.0-ios','')) + $(TargetFrameworks.Replace('net9.0-maccatalyst','')) + + + true + enable + enable + true + Library + true + + + + + + + + + + diff --git a/src/Uno.Sdk/targets/Uno.Common.Wasm.targets b/src/Uno.Sdk/targets/Uno.Common.Wasm.targets index cda84acaf8b0..08f034bc31b5 100644 --- a/src/Uno.Sdk/targets/Uno.Common.Wasm.targets +++ b/src/Uno.Sdk/targets/Uno.Common.Wasm.targets @@ -18,6 +18,9 @@ false + + false + true From a096cede1e2f90738ce44c6149815e84498cdbb9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Laban?= Date: Fri, 15 Nov 2024 13:11:33 -0500 Subject: [PATCH 2/6] chore: Adjust test path (cherry picked from commit f8a449da122a5545748190660bbb3e78c9bd6209) --- build/test-scripts/run-net7-template-linux.ps1 | 2 +- build/test-scripts/run-netcore-mobile-template-tests.ps1 | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/build/test-scripts/run-net7-template-linux.ps1 b/build/test-scripts/run-net7-template-linux.ps1 index 2ca5a48c4e7f..274708fab03c 100644 --- a/build/test-scripts/run-net7-template-linux.ps1 +++ b/build/test-scripts/run-net7-template-linux.ps1 @@ -81,7 +81,7 @@ $projects = @(3, "5.3/uno53net9blank/uno53net9blank/uno53net9blank.csproj", @(), @()) # 5.3 lib - @(2, "5.3/uno53net9blank/uno53net9Lib/uno53net9Lib.csproj", @(), @()) + @(2, "5.3/uno53net9Lib/uno53net9Lib.csproj", @(), @()) # 5.3 blank publish testing # Disabled for LXD setup issues diff --git a/build/test-scripts/run-netcore-mobile-template-tests.ps1 b/build/test-scripts/run-netcore-mobile-template-tests.ps1 index e7ef8ba11138..671ec43db1d5 100644 --- a/build/test-scripts/run-netcore-mobile-template-tests.ps1 +++ b/build/test-scripts/run-netcore-mobile-template-tests.ps1 @@ -339,7 +339,7 @@ $projects = @(3, "5.3/uno53net9blank/uno53net9blank/uno53net9blank.csproj", @("-f", "net9.0-desktop", $sdkFeatures), @("macOS", "NetCore")), # 5.3 Library - @(3, "5.3/uno53net9Lib/uno53net9Lib/uno53net9Lib.csproj", @(), @("macOS", "NetCore")), + @(3, "5.3/uno53net9Lib/uno53net9Lib.csproj", @(), @("macOS", "NetCore")), # Default mode for the template is WindowsAppSDKSelfContained=true, which requires specifying a target platform. @(4, "5.2/uno52AppWithLib/uno52AppWithLib/uno52AppWithLib.csproj", @("-p:Platform=x86" , "-p:TargetFramework=net8.0-windows10.0.26100"), @()), From 1a876effab9e87416a016af0ea349e44cd5d26c8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Laban?= Date: Fri, 15 Nov 2024 15:28:15 -0500 Subject: [PATCH 3/6] chore: Adjust end of line (cherry picked from commit 8e5cb3ca4259544404e80001661cdd257afd01fe) # Conflicts: # build/test-scripts/run-net7-template-linux.ps1 --- build/test-scripts/run-net7-template-linux.ps1 | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/build/test-scripts/run-net7-template-linux.ps1 b/build/test-scripts/run-net7-template-linux.ps1 index 274708fab03c..6337f906e38c 100644 --- a/build/test-scripts/run-net7-template-linux.ps1 +++ b/build/test-scripts/run-net7-template-linux.ps1 @@ -78,7 +78,11 @@ $projects = @(2, "5.2/uno52AppWithLib/uno52AppWithLib/uno52AppWithLib.csproj", @(), @()), # 5.3 Blank with net9 +<<<<<<< HEAD @(3, "5.3/uno53net9blank/uno53net9blank/uno53net9blank.csproj", @(), @()) +======= + @(2, "5.3/uno53net9blank/uno53net9blank/uno53net9blank.csproj", @(), @()), +>>>>>>> 8e5cb3ca42 (chore: Adjust end of line) # 5.3 lib @(2, "5.3/uno53net9Lib/uno53net9Lib.csproj", @(), @()) From a3147293ec60411499d3d2cfcccdf84965c14e28 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Laban?= Date: Fri, 15 Nov 2024 23:10:26 -0500 Subject: [PATCH 4/6] chore: Adjust test run --- build/test-scripts/run-net7-template-linux.ps1 | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/build/test-scripts/run-net7-template-linux.ps1 b/build/test-scripts/run-net7-template-linux.ps1 index 6337f906e38c..a568c5516dbb 100644 --- a/build/test-scripts/run-net7-template-linux.ps1 +++ b/build/test-scripts/run-net7-template-linux.ps1 @@ -78,14 +78,10 @@ $projects = @(2, "5.2/uno52AppWithLib/uno52AppWithLib/uno52AppWithLib.csproj", @(), @()), # 5.3 Blank with net9 -<<<<<<< HEAD @(3, "5.3/uno53net9blank/uno53net9blank/uno53net9blank.csproj", @(), @()) -======= - @(2, "5.3/uno53net9blank/uno53net9blank/uno53net9blank.csproj", @(), @()), ->>>>>>> 8e5cb3ca42 (chore: Adjust end of line) # 5.3 lib - @(2, "5.3/uno53net9Lib/uno53net9Lib.csproj", @(), @()) + @(3, "5.3/uno53net9Lib/uno53net9Lib.csproj", @(), @()) # 5.3 blank publish testing # Disabled for LXD setup issues From 3b1e377437000de9f56cb36229854b7a3f3a5362 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Laban?= Date: Fri, 15 Nov 2024 17:14:40 -0500 Subject: [PATCH 5/6] chore: Remove HD analyzer when building in release --- .../Uno.Implicit.Packages.ProjectSystem.targets | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/Uno.Sdk/targets/Uno.Implicit.Packages.ProjectSystem.targets b/src/Uno.Sdk/targets/Uno.Implicit.Packages.ProjectSystem.targets index 6c9e0a81f315..9bc7dfe1dd4d 100644 --- a/src/Uno.Sdk/targets/Uno.Implicit.Packages.ProjectSystem.targets +++ b/src/Uno.Sdk/targets/Uno.Implicit.Packages.ProjectSystem.targets @@ -109,4 +109,17 @@ + + + + + + <_HDAnalyzerToRemove Include="@(Analyzer)" Condition="'%(Analyzer.NuGetPackageId)'=='Uno.UI.HotDesign'" /> + + + From a31d62d42c8a9e2f53f2530a55c341a19d29d7f9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Laban?= Date: Fri, 15 Nov 2024 21:11:04 -0500 Subject: [PATCH 6/6] chore: Adjust workaround location --- build/nuget/uno.winui.targets | 14 ++++++++++++++ .../Uno.Implicit.Packages.ProjectSystem.targets | 13 ------------- 2 files changed, 14 insertions(+), 13 deletions(-) diff --git a/build/nuget/uno.winui.targets b/build/nuget/uno.winui.targets index 0beb9f1738ba..ed93b8bc3195 100644 --- a/build/nuget/uno.winui.targets +++ b/build/nuget/uno.winui.targets @@ -21,4 +21,18 @@ + + + + + + <_HDAnalyzerToRemove Include="@(Analyzer)" Condition="'%(Analyzer.NuGetPackageId)'=='Uno.UI.HotDesign'" /> + + + + diff --git a/src/Uno.Sdk/targets/Uno.Implicit.Packages.ProjectSystem.targets b/src/Uno.Sdk/targets/Uno.Implicit.Packages.ProjectSystem.targets index 9bc7dfe1dd4d..6c9e0a81f315 100644 --- a/src/Uno.Sdk/targets/Uno.Implicit.Packages.ProjectSystem.targets +++ b/src/Uno.Sdk/targets/Uno.Implicit.Packages.ProjectSystem.targets @@ -109,17 +109,4 @@ - - - - - - <_HDAnalyzerToRemove Include="@(Analyzer)" Condition="'%(Analyzer.NuGetPackageId)'=='Uno.UI.HotDesign'" /> - - -