diff --git a/.dotnet7.0.metadata b/.dotnet7.0.metadata index e7d148c..5f5fd10 100644 --- a/.dotnet7.0.metadata +++ b/.dotnet7.0.metadata @@ -1,3 +1 @@ -2eb3691e273742e1c98ddd1fb9fdce6253414a4b SOURCES/dotnet-arm64-prebuilts-2022-08-17.tar.gz -636d7b9399eddeea347e0785b4e9fcb99a65df29 SOURCES/dotnet-fd587269d0a1fa669d547f3a2e74f5d9353b6dcf-x64-bootstrap.tar.xz -da39a3ee5e6b4b0d3255bfef95601890afd80709 SOURCES/dotnet-s390x-prebuilts-2021-10-29.tar.gz +c2015d0972371ab8995d18246d1f5b76299f3be3 SOURCES/dotnet-v7.0.103.tar.gz diff --git a/.gitignore b/.gitignore index 74b9f9c..8c34d05 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1 @@ -SOURCES/dotnet-arm64-prebuilts-2022-08-17.tar.gz -SOURCES/dotnet-fd587269d0a1fa669d547f3a2e74f5d9353b6dcf-x64-bootstrap.tar.xz -SOURCES/dotnet-s390x-prebuilts-2021-10-29.tar.gz +SOURCES/dotnet-v7.0.103.tar.gz diff --git a/SOURCES/roslyn-analyzers-ppc64le-apphost.patch b/SOURCES/roslyn-analyzers-ppc64le-apphost.patch new file mode 100644 index 0000000..4dd465c --- /dev/null +++ b/SOURCES/roslyn-analyzers-ppc64le-apphost.patch @@ -0,0 +1,12 @@ +diff --git a/src/roslyn-analyzers/src/PerformanceTests/Tests/PerformanceTests.csproj b/src/roslyn-analyzers/src/PerformanceTests/Tests/PerformanceTests.csproj +index 044a2aba4..b3f8f2611 100644 +--- a/src/roslyn-analyzers/src/PerformanceTests/Tests/PerformanceTests.csproj ++++ b/src/roslyn-analyzers/src/PerformanceTests/Tests/PerformanceTests.csproj +@@ -4,6 +4,7 @@ + preview + disable + Exe ++ false + + + true diff --git a/SPECS/dotnet7.0.spec b/SPECS/dotnet7.0.spec index f2018e4..ed242a3 100644 --- a/SPECS/dotnet7.0.spec +++ b/SPECS/dotnet7.0.spec @@ -1,4 +1,4 @@ -%bcond_without bootstrap +%bcond_with bootstrap # LTO triggers a compilation error for a source level issue. Given that LTO should not # change the validity of any given source and the nature of the error (undefined enum), I @@ -6,22 +6,21 @@ # until that's done, disable LTO. This has to happen before setting the flags below. %define _lto_cflags %{nil} -%global host_version 7.0.0-rc.1.22411.12 -%global runtime_version 7.0.0-rc.1.22411.12 -%global aspnetcore_runtime_version 7.0.0-rc.1.22412.2 -%global sdk_version 7.0.100-rc.1.22413.1 +%global host_version 7.0.3 +%global runtime_version 7.0.3 +%global aspnetcore_runtime_version %{runtime_version} +%global sdk_version 7.0.103 %global sdk_feature_band_version %(echo %{sdk_version} | cut -d '-' -f 1 | sed -e 's|[[:digit:]][[:digit:]]$|00|') -%global templates_version 7.0.0-rc.1.22412.2 +%global templates_version %{runtime_version} #%%global templates_version %%(echo %%{runtime_version} | awk 'BEGIN { FS="."; OFS="." } {print $1, $2, $3+1 }') -%global host_rpm_version 7.0.0 -%global runtime_rpm_version 7.0.0 -%global aspnetcore_runtime_rpm_version 7.0.0 -%global sdk_rpm_version 7.0.100 +%global host_rpm_version %{host_version} +%global runtime_rpm_version %{runtime_version} +%global aspnetcore_runtime_rpm_version %{aspnetcore_runtime_version} +%global sdk_rpm_version %{sdk_version} # upstream can update releases without revving the SDK version so these don't always match -#%%global upstream_tag v%%{sdk_version} -%global upstream_tag fd587269d0a1fa669d547f3a2e74f5d9353b6dcf +%global upstream_tag v%{sdk_version} %if 0%{?fedora} || 0%{?rhel} < 8 %global use_bundled_libunwind 0 @@ -29,39 +28,46 @@ %global use_bundled_libunwind 1 %endif -%ifarch aarch64 s390x +%ifarch aarch64 ppc64le s390x %global use_bundled_libunwind 1 %endif -%ifarch x86_64 -%global runtime_arch x64 -%endif %ifarch aarch64 %global runtime_arch arm64 %endif +%ifarch ppc64le +%global runtime_arch ppc64le +%endif %ifarch s390x %global runtime_arch s390x %endif +%ifarch x86_64 +%global runtime_arch x64 +%endif + +%global mono_archs s390x ppc64le %{!?runtime_id:%global runtime_id %(. /etc/os-release ; echo "${ID}.${VERSION_ID%%.*}")-%{runtime_arch}} Name: dotnet7.0 Version: %{sdk_rpm_version} -Release: 0.1%{?dist} +Release: 1%{?dist} Summary: .NET Runtime and SDK License: MIT and ASL 2.0 and BSD and LGPLv2+ and CC-BY and CC0 and MS-PL and EPL-1.0 and GPL+ and GPLv2 and ISC and OFL and zlib URL: https://github.com/dotnet/ %if %{with bootstrap} -# The source is generated on a Fedora box via: +# The source is generated on a RHEL box via: # ./build-dotnet-tarball --bootstrap %%{upstream_tag} Source0: dotnet-%{upstream_tag}-x64-bootstrap.tar.xz # Generated via ./build-arm64-bootstrap-tarball -Source1: dotnet-arm64-prebuilts-2022-08-17.tar.gz +Source1: dotnet-arm64-prebuilts-2022-10-12.tar.gz +# Generated manually, same pattern as the arm64 tarball +Source2: dotnet-ppc64le-prebuilts-2022-10-21.tar.gz # Generated manually, same pattern as the arm64 tarball -Source2: dotnet-s390x-prebuilts-2021-10-29.tar.gz +Source3: dotnet-s390x-prebuilts-2022-10-12.tar.gz %else -# The source is generated on a Fedora box via: +# The source is generated on a RHEL box via: # ./build-dotnet-tarball %%{upstream_tag} Source0: dotnet-%{upstream_tag}.tar.gz %endif @@ -69,11 +75,13 @@ Source0: dotnet-%{upstream_tag}.tar.gz Source10: check-debug-symbols.py Source11: dotnet.sh.in +# Disable apphost; there's no net6.0 apphost for ppc64le +Patch1: roslyn-analyzers-ppc64le-apphost.patch + + %if 0%{?fedora} || 0%{?rhel} >= 8 -# FIXME -# ExclusiveArch: aarch64 x86_64 s390x -ExclusiveArch: aarch64 x86_64 +ExclusiveArch: aarch64 ppc64le s390x x86_64 %else ExclusiveArch: x86_64 %endif @@ -100,6 +108,9 @@ BuildRequires: libunwind-devel %ifarch aarch64 BuildRequires: lld %endif +# if the build ever crashes, then having lldb installed might help the +# runtime generate a backtrace for the crash +BuildRequires: lldb BuildRequires: llvm BuildRequires: lttng-ust-devel BuildRequires: make @@ -331,6 +342,20 @@ These are not meant for general use. %prep %if %{without bootstrap} %setup -q -n dotnet-%{upstream_tag} + +# Remove all prebuilts +find -iname '*.dll' -type f -delete +find -iname '*.so' -type f -delete +find -iname '*.tar.gz' -type f -delete +find -iname '*.nupkg' -type f -delete +find -iname '*.zip' -type f -delete + +rm -rf .dotnet/ +rm -rf packages/source-built + +mkdir -p packages/archive +ln -s %{_libdir}/dotnet/source-built-artifacts/Private.SourceBuilt.Artifacts.*.tar.gz packages/archive/ + %else %setup -q -T -b 0 -n dotnet-%{upstream_tag}-x64-bootstrap @@ -341,29 +366,40 @@ rm -rf .dotnet %ifarch aarch64 tar -x --strip-components=1 -f %{SOURCE1} -C packages/prebuilt %endif -%ifarch s390x +%ifarch ppc64le tar -x --strip-components=1 -f %{SOURCE2} -C packages/prebuilt %endif +%ifarch s390x +tar -x --strip-components=1 -f %{SOURCE3} -C packages/prebuilt +%endif + mkdir -p .dotnet tar xf packages/prebuilt/dotnet-sdk*.tar.gz -C .dotnet/ rm packages/prebuilt/dotnet-sdk*.tar.gz + boot_sdk_version=$(ls -1 .dotnet/sdk/) sed -i -E 's|"dotnet": "[^"]+"|"dotnet" : "'$boot_sdk_version'"|' global.json + +%ifarch ppc64le s390x +ilasm_version=$(ls packages/prebuilt| grep -i ilasm | tr 'A-Z' 'a-z' | sed -E 's|runtime.linux-'%{runtime_arch}'.microsoft.netcore.ilasm.||' | sed -E 's|.nupkg$||') +echo $ilasm_version + +mkdir -p packages-customized-local +pushd packages-customized-local +tar xf ../packages/archive/Private.SourceBuilt.Artifacts.*.tar.gz +sed -i -E 's|[^<]+|'$ilasm_version'|' PackageVersions.props +sed -i -E 's|[^<]+|'$ilasm_version'|' PackageVersions.props +tar czf ../packages/archive/Private.SourceBuilt.Artifacts.*.tar.gz * +popd + %endif %endif -%if %{without bootstrap} -# Remove all prebuilts -find -iname '*.dll' -type f -delete -find -iname '*.so' -type f -delete -find -iname '*.tar.gz' -type f -delete -find -iname '*.nupkg' -type f -delete -find -iname '*.zip' -type f -delete -rm -rf .dotnet/ -rm -rf packages/source-built %endif +%patch1 -p1 + # Fix bad hardcoded path in build sed -i 's|/usr/share/dotnet|%{_libdir}/dotnet|' src/runtime/src/native/corehost/hostmisc/pal.unix.cpp @@ -429,15 +465,12 @@ export COMPlus_LTTng=0 export OPENSSL_ENABLE_SHA1_SIGNATURES=1 %endif -%if 0%{?rhel} -# See https://github.com/dotnet/source-build/issues/2991 -export DOTNET_NUGET_SIGNATURE_VERIFICATION=false -%endif - VERBOSE=1 ./build.sh \ %if %{without bootstrap} --with-sdk previously-built-dotnet \ - --with-packages %{_libdir}/dotnet/source-built-artifacts/Private.SourceBuilt.Artifacts.*.tar.gz +%endif +%ifarch %{mono_archs} + --use-mono-runtime \ %endif -- \ /p:MinimalConsoleLogOutput=false \ @@ -576,7 +609,6 @@ export COMPlus_LTTng=0 %dir %{_libdir}/dotnet/sdk %{_libdir}/dotnet/sdk/%{sdk_version} %dir %{_libdir}/dotnet/sdk-manifests -%{_libdir}/dotnet/sdk-manifests/6.0.300 %{_libdir}/dotnet/sdk-manifests/%{sdk_feature_band_version} %{_libdir}/dotnet/metadata %dir %{_libdir}/dotnet/packs @@ -587,7 +619,36 @@ export COMPlus_LTTng=0 %changelog -* Thu Aug 25 2022 Omair Majid - 7.0.100 +* Thu Feb 02 2023 Omair Majid - 7.0.103-1 +- Update to .NET SDK 7.0.103 and Runtime 7.0.3 +- Resolves: RHBZ#2166775 + +* Mon Dec 19 2022 Omair Majid - 7.0.102-1 +- Update to .NET SDK 7.0.102 and Runtime 7.0.2 +- Resolves: RHBZ#2154466 + +* Tue Dec 06 2022 Omair Majid - 7.0.101-1 +- Update to .NET SDK 7.0.101 and Runtime 7.0.1 +- Resolves: RHBZ#2150151 + +* Wed Nov 02 2022 Omair Majid - 7.0.100-1 +- Update to .NET SDK 7.0.100 and Runtime 7.0.0 +- Resolves: RHBZ#2137943 + +* Mon Oct 24 2022 Omair Majid - 7.0.100-0.4.rc2 +- Enable ppc64le builds +- Related: RHBZ#2134642 + +* Thu Oct 13 2022 Omair Majid - 7.0.100-0.3.rc2 +- Update to .NET 7 RC 2 +- Resolves: RHBZ#2134642 + +* Sat Sep 17 2022 Omair Majid - 7.0.100-0.2.rc1 +- Update to .NET 7 RC 1 +- Enable s390x builds +- Resolves: RHBZ#2123886 + +* Thu Aug 25 2022 Omair Majid - 7.0.100-0.1 - Initial .NET 7 package - Resolves: RHBZ#2112096