RHEL 9.0.0 Alpha bootstrap

The content of this branch was automatically imported from Fedora ELN
with the following as its source:
https://src.fedoraproject.org/rpms/dotnet-build-reference-packages#e7b448e64a2c6a997dad61c7a46792f0b8508104
This commit is contained in:
Petr Šabata 2020-10-14 23:49:20 +02:00
parent 299e6a65cd
commit e0fd81e322
5 changed files with 149 additions and 0 deletions

5
.gitignore vendored
View File

@ -0,0 +1,5 @@
/dotnet-build-reference-packages-9cc7dad.tar.gz
/dotnet-build-reference-packages-6e2aee6.tar.gz
/dotnet-build-reference-packages-5aaf20d.tar.gz
/dotnet-build-reference-packages-1b1a695.tar.gz
/dotnet-build-reference-packages-cd5a8c6.tar.gz

9
README.md Normal file
View File

@ -0,0 +1,9 @@
# dotnet-build-reference-packages
The dotnet-build-reference-packages package contains reference assemblies needed to build .NET Core.
This package is not meant to be used by end-users.
For developers, you can easily update this package using:
./update-release <new-upstream-git-sha>

View File

@ -0,0 +1,86 @@
%global debug_package %{nil}
%global commit cd5a8c6f5c67cbaa87755aafa8765e812ceaa2dc
%global shortcommit %(c=%{commit}; echo ${c:0:7})
Name: dotnet-build-reference-packages
Version: 0
Release: 7.20200608git%{shortcommit}%{?dist}
Summary: Reference packages needed by the .NET Core SDK build
License: MIT
URL: https://github.com/dotnet/source-build-reference-packages
Source0: https://github.com/dotnet/source-build-reference-packages/archive/%{commit}/%{name}-%{shortcommit}.tar.gz
%if 0%{?fedora} > 32 || 0%{?rhel} > 8
ExclusiveArch: aarch64 x86_64
%else
ExclusiveArch: x86_64
%endif
BuildRequires: dotnet-sdk-3.1
BuildRequires: dotnet-sdk-3.1-source-built-artifacts
%description
This contains references packages used for building .NET Core.
This is not meant to be used by end-users.
%prep
%setup -q -n source-build-reference-packages-%{commit}
find -name '*.nupkg' -type f -delete
find -name '*.dll' -type f -delete
find -name '*.so' -type f -delete
find -name '*.tar.gz' -type f -delete
%build
find -iname 'nuget.config' -exec echo {} \; -exec cat {} \;
%{_libdir}/dotnet/dotnet --info
./build.sh \
--with-sdk %{_libdir}/dotnet \
--with-packages %{_libdir}/dotnet/source-built-artifacts/*.tar.gz
pushd artifacts/reference-packages
tar cvzf Private.SourceBuild.ReferencePackages.%{version}.tar.gz *.nupkg
popd
mv artifacts/reference-packages/Private.SourceBuild.ReferencePackages.%{version}.tar.gz .
%install
mkdir -p %{buildroot}/%{_libdir}/dotnet
cp -a artifacts/reference-packages %{buildroot}/%{_libdir}/dotnet/
cp -a Private.SourceBuild.ReferencePackages.%{version}.tar.gz %{buildroot}/%{_libdir}/dotnet/reference-packages/
%files
%dir %{_libdir}/dotnet/
%{_libdir}/dotnet/reference-packages/
%license LICENSE.txt
%changelog
* Mon Jul 27 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0-7.20200608gitcd5a8c6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
* Tue Jul 21 2020 Omair Majid <omajid@redhat.com> - 0-6.20200608gitcd5a8c6
- Update to upstream commit cd5a8c6
* Mon Jul 20 2020 Omair Majid <omajid@redhat.com> - 0-5.20200608git1b1a695
- Update to upstream commit 1b1a695
* Fri Jun 19 2020 Omair Majid <omajid@redhat.com> - 0-4.20200608git5aaf20d
- Enable building on aarch64
* Mon Jun 08 2020 Chris Rummel <crummel@microsoft.com> - 0-3.20200608git5aaf20d
- Updated to upstream commit 5aaf20d
* Tue Jun 02 2020 Omair Majid <omajid@redhat.com> - 0-3.20200528git6e2aee66e2aee6
- Updated to upstream commit 6e2aee6
* Wed Feb 19 2020 Radka Janekova <rjanekov@redhat.com> - 0-2.20200108git9cc7dad
- Added license reference
* Tue Feb 11 2020 Omair Majid <omajid@redhat.com> - 0-1.20200108git9cc7dad
- Initial package

1
sources Normal file
View File

@ -0,0 +1 @@
SHA512 (dotnet-build-reference-packages-cd5a8c6.tar.gz) = 416967b6cb1c0cedaa664d8d065ff1ae63bc5cb5be6296a97228f0277914c32d806d2b00508e67d0d778a57e7e661ed7eca8badd31a1214f87d734dc0f9e4a44

48
update-release Executable file
View File

@ -0,0 +1,48 @@
#!/bin/bash
# Usage:
# ./update-release commit-sha
set -euo pipefail
IFS=$'\n\t'
print_usage() {
echo " Usage:"
echo " ./update-release commit-sha"
echo ""
echo "Update the source-build-reference-packages package to the upstream commit sha"
}
positional_args=()
while [[ "$#" -gt 0 ]]; do
arg="${1}"
case "${arg}" in
-h|--help)
print_usage
exit 0
;;
*)
positional_args+=("$1")
shift
;;
esac
done
spec_file=dotnet-build-reference-packages.spec
commit_sha=${positional_args[0]:-}
if [[ -z ${commit_sha} ]]; then
echo "error: missing commit sha"
exit 1
fi
set -x
sed -i -E "s|^%global commit [a-f0-9]+$|%global commit ${commit_sha}|" "$spec_file"
sed -i -E "s|^(Release: +[[:digit:]]+\.)([[:digit:]]{8})git|\1$(date '+%4Y%m%d')git|" "$spec_file"
spectool -g "${spec_file}"
comment="Update to upstream commit ${commit_sha:0:7}"
rpmdev-bumpspec --comment="$comment" $spec_file