testing/dotnet{31,31-stage0,5,5-stage0}: new aports
New aport for dotnet31, dotnet31-stage0 (to build dotnet31), dotnet5 and dotnet5-stage (to build dotnet5) from source using (at first) Microsoft bootstraps, with capacity to then build using Alpine bootstraps. Successful build on x86_64 platform, further notes copied from README.md:
(continuation of merge requests !28197 (merged) and !28195 (merged))
dotnet31-stage0:
# Description
APKBUILD for dotnet31-stage0
# How to build dotnet31 stack
* Build testing/dotnet31-stage0 first (provides binary
dotnet31-bootstrap-runtime / sdk and dotnet-host)
* Build testing/dotnet31 once (with binary bootstraps, provides repo versions
of above packages, and more)
* Build testing/dotnet31 again (with repo bootstraps, provides full repo
versions)
# Known issues
* While dotnet31 supports musl-arm64, builds for that architecture hasn't been
attempted due to lack of bootstrap SDK
dotnet31:
## application-insights_fix-net40-location.patch (see microsoft/ApplicationInsights-dotnet#2498)
Because paths on Linux are case sensitive. Applications insights looks
for <dotnet/applications-insights>/src/Core/Managed/net40 in net40
while the repo has a Net40. Patch moves whatever is in Net40 to net40.
## build_coreclr-tools-path.patch (see dotnet/source-build#2697)
Various steps in the build process looks for ilasm in ildasm in
$builddir/src/dotnet-3.1/Tools/source-built/coreclr-tools/x64 while they are
built to $builddir/src/dotnet-3.1/Tools/source-built/coreclr-tools.
This patches <dotnet/source-build> to look for ilasm and ildasm
in correct path.
## build_darc-fix-alpine.patch
Darc has a segmentation fault on Alpine due to not chosing the correct
binary architecture. This patch deletes all the wrong ones so that it
is forced to chose the correct one. See issue dotnet/source-build #1868
This issue only occurs when using dotnet-stage0-runtime, thus libunwind is
suspected to be the issue as stage0 wasn't built with system libunwind.
## coreclr_fix-build-on-Alpine-edge-45352.patch (see dotnet/coreclr#28226)
Fixes a build error for Alpine Linux. It has since been fixed in dotnet-5.0,
see issue dotnet/runtime 45352.
## corefx_fix-build-clang10.patch (see dotnet/corefx#43130)
Fixes a build error for clang 10
## core-setup_rid-plat-generation-on-alpine-fix.patch (see dotnet/core-setup#9195)
<dotnet/core-setup>/src/corehost/build.sh generates wrong plat_rid on Alpine
Generated RID is expected to be alpine.x.xx-xx, while the computed RID
is linux-musl-xxx. This patches it by matching what's expected.
## coreclr_non-portable-distrorid-fix-alpine.patch (see dotnet/coreclr#28227)
<dotnet/coreclr>/init-distro-id.sh generates incorrect DistroRid on Alpine.
While the expected DistroRid (alpine-x.xx-xxx) should only include macro
version, init-distro-id.sh includes the micro version. This patches it
to cut off the trailing subversion off of VERSION_ID by treating it
the same way RHEL's VERSION_ID is treated.
## core-sdk_generate-layout-core-setup-blob-path-fix.patch
<dotnet/core-setup> blobs are written to $builddir/artifacts/obj/x64/Release/
blobs/Runtime/3.1.20-alpine.3.15 while installer expects them in 3.1.20.
This patches <dotnet/installer>/src/redist/targets/GenerateLayout.targets
to point to actual path
dotnet5-stage0:
APKBUILD for dotnet5-stage0
# How to build dotnet5 stack
* Build testing/dotnet5-stage0 (provides dotnet5-bootstrap-runtime / sdk)
* Build testing/dotnet5 once (dotnet5-stage0 runtime / sdk bootstrap)
* Build testing/dotnet5 again (with repo bootstraps, provides full repo
versions)
# Known issues
* While dotnet5 supports musl-arm64 musl-arm32 and musl-x64, builds for those
architectures hasn't been tested.
dotnet5:
# Description
APKBUILD for dotnet5
# How to build dotnet5 stack
* Build testing/dotnet5-stage0 (provides dotnet5-bootstrap-runtime / sdk)
* Build testing/dotnet5 once (dotnet5-stage0 runtime / sdk bootstrap)
* Build testing/dotnet5 again (with repo bootstraps, provides full repo
versions)
# Known issues
* Build oddities here and there that the patches fix. In the process of
upstreaming to clear them out
* No check() mechanism, havn't found any docs for source-build tests
* While dotnet5 supports musl-arm64 musl-arm32 and musl-x64, builds for those
architectures hasn't been tested.
# Patch notes
# Description
APKBUILD for dotnet5
# How to build dotnet5 stack
* Build testing/dotnet5-stage0 (provides dotnet5-bootstrap-runtime / sdk)
* Build testing/dotnet5 once (dotnet5-stage0 runtime / sdk bootstrap)
* Build testing/dotnet5 again (with repo bootstraps, provides full repo
versions)
# Known issues
* Build oddities here and there that the patches fix. In the process of
upstreaming to clear them out
* No check() mechanism, havn't found any docs for source-build tests
* While dotnet5 supports musl-arm64 musl-arm32 and musl-x64, builds for those
architectures hasn't been tested.
# Patch notes
## application-insights_fix-net40-location.patch (see microsoft/ApplicationInsights-dotnet#2498)
Because paths on Linux are case sensitive. Applications insights looks
for <dotnet/applicationsinsights>/src/Core/Managed/net40 in net40
while the repo has a Net40. Patch moves whatever is in Net40 to net40
## build_darc-use-available-runtime.patch (see dotnet/source-build#2698)
Default version of Darc needs dotnet 3.1 runtimes, and fails to run on
Alpine. This patch fixes this by pushing Darc's version and disabling runtime
retrieval. Can't push it too much, though, as latest version breaks with
application-insights as it doesn't include a eng/Version.Details.xml file
## build_darc-fix-alpine.patch (see dotnet/source-build#1868)
Darc has a segmentation fault on Alpine due to not chosing the correct
binary architecture. This patch deletes all the wrong ones so that it
is forced to chose the correct one. See issue dotnet/source-build #1868
This issue only occurs when using dotnet-stage0-runtime, thus libunwind is
suspected to be the issue as stage0 wasn't built with system libunwind.
## runtime_add-rid-for-alpine-315.patch (see dotnet/runtime#62938)
As of version 5.0.12, runtime does not have the RIDs for Alpine Linux 3.15.
This patch adds them. See dotnet/core issue #6985
## runtime_link-order.patch
For some reason, runtime does not link in the right order. This fixes that.
## runtime_non-portable-distrorid-fix-alpine.patch (see dotnet/runtime#62942)
Runtime adds the extra subversion in its calculation of Alpine's DistroRID
when a non-portable build, but does so inconsistently. This creates an error
when it generates its nuget package.
## runtime_use-latest-microsoftnetcoreplatformspackage.patch
In stock build, an old version of MicrosoftNETCorePlatformsPackage is used.
Thus, dotnet5-runtime is shipped without RIDs for alpine 3.13 and up, causing
a segmentation fault for dotnet projects. Related to dotnet/runtime#24189 and
dotnet/runtime#50739. This patches eng/Versions.props to use latest version.
## sdk_telemetry-optout.patch
Optouts of telemetry gathering
Edited by Antoine Martin