community/dotnet6-build: sync with aports

This commit is contained in:
Antoine Martin 2023-11-24 17:52:01 -05:00
parent 46e7fabb59
commit 6756e08c16
4 changed files with 33 additions and 139 deletions

View file

@ -34,21 +34,38 @@
# - CVE-2023-35390
# - CVE-2023-38180
# - CVE-2023-35391
# 6.0.122-r0:
# - CVE-2023-36792
# - CVE-2023-36793
# - CVE-2023-36794
# - CVE-2023-36796
# - CVE-2023-36799
# 6.0.123-r0:
# - CVE-2023-44487
# 6.0.124-r0:
# - CVE-2023-36792
# - CVE-2023-36793
# - CVE-2023-36794
# - CVE-2023-36796
# - CVE-2023-36799
# - CVE-2023-44487
# 6.0.125-r0:
# - CVE-2023-36049
# - CVE-2023-36558
pkgname=dotnet6-build
pkgver=6.0.121
pkgver=6.0.125
pkgrel=0
_gittag=v$pkgver-source-build
_gittag=v$pkgver
_giturl="https://github.com/dotnet/installer"
_testtag=e1cc0f181ffd4d755756d30d985513897d592ba4
_bunnytag=71880bd94711519f7b786248a88a827a401207a2
_llvmver=16
_patches="
build_14816-non-portable-build.patch
build_14816-stop-overriding-aspnetcore-version.patch
build_14816-update-portable-rid-logic.patch
build_disable-apphost.diff
installer_14816-crossgen2-rid.patch
installer_14816-update-portable-rid-logic.patch
msbuild_optional-systemconfiguration.patch
msbuild_optional-systemsecurity.patch
@ -65,8 +82,7 @@ _pkgver_macro=${pkgver%.*}
_pkgver_prior=${pkgver%.*.*}
_pkgver_name=${_pkgver_macro//[.0]}
pkgdesc="The .NET $_pkgver_macro bootstrap"
# aarch64: build failure
arch="x86_64 armv7 s390x"
arch="x86_64 aarch64 armv7"
url=https://dotnet.microsoft.com
license="MIT"
# hack for dotnetx-build to be able to pull itself for bootstrapping
@ -90,7 +106,7 @@ checkdepends="
makedepends="
alpine-release
bash
clang
clang$_llvmver
cmake
dotnet$_pkgver_name-bootstrap
dotnet$_pkgver_name-bootstrap-artifacts
@ -110,7 +126,7 @@ makedepends="
libxml2-utils
linux-headers
lldb-dev
llvm-dev
llvm$_llvmver-dev
lttng-ust-dev
nodejs
numactl-dev
@ -275,6 +291,8 @@ build() {
msg "Building $pkgname-$pkgver"
ulimit -n 4096
export PATH="$PATH:/usr/lib/llvm$_llvmver/bin"
# Disable use of LTTng as tracing on lttng <=2,13,0 is broken
# See https://github.com/dotnet/runtime/issues/57784.
if [ -f "/usr/lib/liblttng-ust.so.1 " ]; then
@ -551,14 +569,12 @@ doc() {
}
sha512sums="
f038ff9707a102cc07032a32547dd4b0bae9bbe357cfafd769030ad625fbcd86bb9396db543309e625bad2af1f0e183f0288d6bd3ef47f803d203a11e03524e2 dotnet-v6.0.121-source-build.tar.xz
5f3626aac49cf29c924d30fa81c508be8a45b38914c08b67c1dbec44f7d2b3ff7b6a8126ff4af88d43b972e5e17a712757b762ecf5c99c5f6acd8284ee9b2a3f dotnet-v6.0.125.tar.xz
e9f3df13d093fac214778c1137857e065f58d4e0d2a48d540d8ed7bb41e2fd73b2b3f62a0aa5b0e80fa80a5b58ba77ff19b9d10a492802f8539e3a6ed79d299d dotnet-testsuite-e1cc0f181ffd4d755756d30d985513897d592ba4.tar.gz
fc281df5fcf0d31dc9ff7f5b0e870960cfbe3c4fa0f6a6bb50b22c4ee18d2c608c827205bc79bd7f686d77ac917582fc26f68432cdd86c4a33b910c0c7416d09 dotnet-bunny-71880bd94711519f7b786248a88a827a401207a2.tar.gz
bdbe798add3ded0c2cf361c9f5aa18fb3540e348e68a5695cbdb797be917f06d1bda69855cae2f36950e9506119e81165927787e13b80a17a1b647ef2c221916 build_14816-non-portable-build.patch
3e04fff2d9d9b39ac4dce0b80f4b566fff8819313a5bf1df791e8f1a63a26ef882bd8aa1524344f63fbb4a3728077179b7f1d7ebefc003c236d39a48beaa0073 build_14816-stop-overriding-aspnetcore-version.patch
bdc2617791fda07bcc87cf5f8727ac721756810880b14c5472998d6a3e238d85d5a12db7823d1237b17f40945e697a6c9104d1c43816c775cc03920e88572a37 build_14816-non-portable-build.patch
70d402d0bcaa98c8b09652365404238b67ed26eb9c3d510c7d6309fb61937d98c9144f1096e521c11b00e946d29585a9d474498ccc5223de32bd6471ab5a431f build_14816-update-portable-rid-logic.patch
a5a359af816595fbf19482e5dccf874c78d2fc4b59f38223118aac603b33e00c9fed22580eee3112519477205c2c8ed16177d100f09f45275e3da3c20b0ed7f7 build_disable-apphost.diff
7ffda90d766217e7c3756ebd423b557218c24f5337668b319421514945d3f961d82037c997b7254de088b1853102d7de15e0d824cf2cc02a6c455efc2b0107a2 installer_14816-crossgen2-rid.patch
e71f91d14873755bc2f227807d909e5260bd1f166a262eda0bf05d4a3975a7bce7fde457c1eba476a83b317aebdaaba25f1893d3385182428c08bba6243f21c8 installer_14816-update-portable-rid-logic.patch
86e14ecc0269c8b2c2a2a679790de4fa4e15ac06b2a831e1129c4a7de1499d60583fcdc79b3705652c3c4ced73afac2e0ee3edce2cfa3b00fddf94180fb26e10 msbuild_optional-systemconfiguration.patch
f4d27624f735ce77e0030fa791594fc12fb325a3ce8620791a7856bd5c0067a042df2196ec97ed4d0309db64bd51e6a48cafaad316d9ea45e34134214a7f3ca4 msbuild_optional-systemsecurity.patch

View file

@ -52,15 +52,15 @@ index 480f3c713..52243024a 100644
<!-- Update to 1.0.0 version of reference assemblies which are built in SBRP instead of the preview.2 version
included by Arcade -->
<BuildCommandArgs>$(BuildCommandArgs) /p:MicrosoftNetFrameworkReferenceAssembliesVersion=1.0.0</BuildCommandArgs>
diff --git a/repos/installer.proj b/repos/installer.proj
index e34337b85..6c08a1f67 100644
--- a/repos/installer.proj
diff --git a/repos/installer.proj.orig b/repos/installer.proj
index 0df0c8f7c03..95d47c94152 100644
--- a/repos/installer.proj.orig
+++ b/repos/installer.proj
@@ -25,7 +25,7 @@
@@ -30,7 +30,7 @@
<BuildCommandArgs Condition="'$(TargetOS)' == 'Linux'">$(BuildCommandArgs) /p:Rid=$(TargetRid)</BuildCommandArgs>
<BuildCommandArgs>$(BuildCommandArgs) /p:DOTNET_INSTALL_DIR=$(DotNetCliToolDir)</BuildCommandArgs>
- <BuildCommandArgs Condition="'$(TargetOS)' == 'Linux'">$(BuildCommandArgs) /p:AspNetCoreInstallerRid=linux-$(Platform)</BuildCommandArgs>
- <BuildCommandArgs Condition="'$(TargetOS)' == 'Linux'">$(BuildCommandArgs) /p:AspNetCoreInstallerRid=$(PortableRid)</BuildCommandArgs>
+ <BuildCommandArgs Condition="'$(TargetOS)' == 'Linux'">$(BuildCommandArgs) /p:AspNetCoreInstallerRid=$(TargetRid)</BuildCommandArgs>
<!-- core-sdk always wants to build portable on OSX and FreeBSD -->
<BuildCommandArgs Condition="'$(TargetOS)' == 'FreeBSD'">$(BuildCommandArgs) /p:CoreSetupRid=freebsd-x64 /p:PortableBuild=true</BuildCommandArgs>

View file

@ -1,69 +0,0 @@
From 94463478bd6aaec208bc5e3dd1d120e0a49aeaaa Mon Sep 17 00:00:00 2001
Patch-Source: https://github.com/dotnet/installer/pull/14816
From: Antoine Martin <dev@ayakael.net>
Date: Tue, 15 Nov 2022 01:08:29 -0500
Subject: [PATCH 3/3] source-build: stop overriding aspnetcore version
(backport of #14938)
---
.../tarball/content/Directory.Build.props | 4 ----
.../tarball/content/tools-local/init-build.proj | 12 ++++++++++++
2 files changed, 12 insertions(+), 4 deletions(-)
diff --git a/Directory.Build.props b/Directory.Build.props
index 2e2d7e8bc..6b08fa71b 100644
--- a/Directory.Build.props
+++ b/Directory.Build.props
@@ -222,12 +222,8 @@
<ExtraPackageVersionPropsPackageInfo Include="MicrosoftNETCoreAppRuntimePackageVersion" Version="$(runtimeOutputPackageVersion)" />
<ExtraPackageVersionPropsPackageInfo Include="MicrosoftNETCoreAppRuntimeVersion" Version="$(runtimeOutputPackageVersion)" />
<ExtraPackageVersionPropsPackageInfo Include="MicrosoftNETCoreAppHostPackageVersion" Version="$(runtimeOutputPackageVersion)" />
- <ExtraPackageVersionPropsPackageInfo Include="MicrosoftAspNetCoreAppRuntimePackageVersion" Version="%24(MicrosoftAspNetCoreAppRuntimeLinux$(Platform)PackageVersion)" />
<!-- core-sdk uses this property for ASP.NET blob directory -->
<ExtraPackageVersionPropsPackageInfo Include="VSRedistCommonAspNetCoreTargetingPackx6430PackageVersion" Version="$(aspnetcoreOutputPackageVersion)" />
- <!-- OSX needs the OSX version instead of Linux. We don't have a lot of flexibility in how we output these properties so we're relying on the previous one being blank if the Linux version of the package is missing. -->
- <ExtraPackageVersionPropsPackageInfo Include="MicrosoftAspNetCoreAppRuntimePackageVersion" Version="%24(MicrosoftAspNetCoreAppRuntimeOsxX64PackageVersion)" DoNotOverwrite="true" />
- <ExtraPackageVersionPropsPackageInfo Include="MicrosoftAspNetCoreAppRuntimePackageVersion" Version="%24(MicrosoftAspNetCoreAppRuntimewinx64PackageVersion)" DoNotOverwrite="true" />
<!-- Used by installer to determine sdk version -->
<ExtraPackageVersionPropsPackageInfo Include="MicrosoftDotnetToolsetInternalPackageVersion" Version="%24(MicrosoftNETSdkPackageVersion)" />
diff --git a/tools-local/init-build.proj b/tools-local/init-build.proj
index 701f76c0c..ac4508947 100644
--- a/tools-local/init-build.proj
+++ b/tools-local/init-build.proj
@@ -9,6 +9,7 @@
<UsingTask AssemblyFile="$(XPlatSourceBuildTasksAssembly)" TaskName="NuGetPack" />
<UsingTask AssemblyFile="$(XPlatSourceBuildTasksAssembly)" TaskName="ZipFileExtractToDirectory" />
<UsingTask AssemblyFile="$(XPlatSourceBuildTasksAssembly)" TaskName="ReplaceTextInFile" />
+ <UsingTask AssemblyFile="$(XPlatSourceBuildTasksAssembly)" TaskName="ReplaceRegexInFiles" />
<ItemGroup>
<BuildTasksTarget Include="Restore;Build;InstallResolver" />
@@ -22,6 +23,7 @@
<CallTarget Targets="
UnpackTarballs;
BuildXPlatTasks;
+ PatchPackageVersions;
BuildLeakDetection;
ExtractToolPackage;
GenerateRootFs;
@@ -38,6 +40,16 @@
<Delete Files="$(CompletedSemaphorePath)*.*" />
</Target>
+ <!-- TODO: Remove this when the .NET 8 artifacts tarball no longer includes MicrosoftAspNetCoreAppRuntimePackageVersion -->
+ <Target Name="PatchPackageVersions">
+ <!-- Rename MicrosoftAspNetCoreAppRuntimePackageVersion so it isn't used
+ Fixes https://github.com/dotnet/installer/issues/14492 -->
+ <ReplaceRegexInFiles
+ InputFiles="$(IntermediatePath)PreviouslySourceBuiltPackageVersions.props"
+ OldTextRegex="\bMicrosoftAspNetCoreAppRuntimePackageVersion\b"
+ NewText="__unused" />
+ </Target>
+
<Target Name="UnpackTarballs"
Inputs="$(MSBuildProjectFullPath)"
Outputs="$(CompletedSemaphorePath)UnpackTarballs.complete" >
--
2.38.2

View file

@ -1,53 +0,0 @@
From 3008f7ef29e0a5593f6f0afbdc9343f573f1a375 Mon Sep 17 00:00:00 2001
Patch-Source: https://github.com/dotnet/installer/pull/14816
From: Antoine Martin <dev@ayakael.net>
Date: Tue, 15 Nov 2022 01:04:07 -0500
Subject: [PATCH 1/3] Eliminate runtime portable build (backport dotnet#14549)
---
.../tarball/content/Directory.Build.props | 8 --
.../tarball/content/repos/aspnetcore.proj | 1 +
.../tarball/content/repos/installer.proj | 2 +-
.../tarball/content/repos/known-good.proj | 1 -
.../content/repos/runtime-portable.proj | 47 -----------
.../content/repos/runtime.common.props | 43 ----------
.../content/repos/runtime.common.targets | 46 -----------
.../tarball/content/repos/runtime.proj | 82 ++++++++++++++++++-
.../source-build-reference-packages.proj | 4 +-
src/redist/targets/Crossgen.targets | 2 +-
src/redist/targets/GenerateLayout.targets | 3 +
11 files changed, 88 insertions(+), 151 deletions(-)
delete mode 100644 src/SourceBuild/tarball/content/repos/runtime-portable.proj
delete mode 100644 src/SourceBuild/tarball/content/repos/runtime.common.props
delete mode 100644 src/SourceBuild/tarball/content/repos/runtime.common.targets
diff --git a/src/installer/src/redist/targets/Crossgen.targets b/src/installer/src/redist/targets/Crossgen.targets
index 8949af132..a59ed388f 100644
--- a/src/installer/src/redist/targets/Crossgen.targets
+++ b/src/installer/src/redist/targets/Crossgen.targets
@@ -6,7 +6,7 @@
<PropertyGroup>
<RuntimeNETCoreAppPackageName>microsoft.netcore.app.runtime.$(SharedFrameworkRid)</RuntimeNETCoreAppPackageName>
- <RuntimeNETCrossgenPackageName>microsoft.netcore.app.crossgen2.$(HostOSName)-$(BuildArchitecture)</RuntimeNETCrossgenPackageName>
+ <RuntimeNETCrossgenPackageName>microsoft.netcore.app.crossgen2.$(Crossgen2Rid)</RuntimeNETCrossgenPackageName>
<CrossgenPath>$(NuGetPackageRoot)/$(RuntimeNETCrossgenPackageName)/$(MicrosoftNETCoreAppRuntimePackageVersion)/tools/crossgen2$(ExeExtension)</CrossgenPath>
<!-- When ingesting stable pgo instrumented binaries, the shared framework will be a non-stable version,
as will the archive file names themselves. -->
diff --git a/src/installer/src/redist/targets/GenerateLayout.targets b/src/installer/src/redist/targets/GenerateLayout.targets
index 88a053b61..ce5e09b69 100644
--- a/src/installer/src/redist/targets/GenerateLayout.targets
+++ b/src/installer/src/redist/targets/GenerateLayout.targets
@@ -84,6 +84,9 @@
<CombinedFrameworkHostArchiveFileName Condition=" '$(PgoInstrument)' == 'true' ">dotnet-runtime$(PgoTerm)-$(VSRedistCommonNetCoreSharedFrameworkx6460PackageVersion)-$(SharedFrameworkRid)$(ArchiveExtension)</CombinedFrameworkHostArchiveFileName>
<WinFormsAndWpfSharedFxArchiveFileName>windowsdesktop-runtime-$(MicrosoftWindowsDesktopAppRuntimePackageVersion)-$(SharedFrameworkRid)$(ArchiveExtension)</WinFormsAndWpfSharedFxArchiveFileName>
+ <Crossgen2Rid>$(HostOSName)-$(BuildArchitecture)</Crossgen2Rid>
+ <Crossgen2Rid Condition="'$(DotNetBuildFromSource)' == 'true'">$(SharedFrameworkRid)</Crossgen2Rid>
+
<AspNetCoreInstallerRid Condition="'$(AspNetCoreInstallerRid)' == ''">$(SharedFrameworkRid)</AspNetCoreInstallerRid>
<AspNetCoreInstallerRid Condition="'$(SharedFrameworkRid)' == 'rhel.6-x64'">linux-x64</AspNetCoreInstallerRid>
<AspNetCoreArchiveRid>$(AspNetCoreInstallerRid)</AspNetCoreArchiveRid>
--
2.38.2