From ee11a7c226ccf1eefea1049ee833ea4a5d8a97b2 Mon Sep 17 00:00:00 2001 From: Johnny Hughes Date: Nov 29 2017 18:51:46 +0000 Subject: change to remove RHEL specific code to compile on CentOS --- diff --git a/SPECS/dotnet.spec b/SPECS/dotnet.spec index ab8608d..2f1c731 100644 --- a/SPECS/dotnet.spec +++ b/SPECS/dotnet.spec @@ -16,7 +16,7 @@ Name: %{?scl_prefix}dotnet Version: %{sdk_version} -Release: 4%{?dist} +Release: 4.1%{?dist} Summary: .NET Core is a general-purpose cross platform development platform Group: Development/Languages License: ASL 2.0 and MIT @@ -128,6 +128,16 @@ sed -ie "s|flp:Verbosity=normal|flp:Verbosity=diag|" src/coreclr/build.sh # Change text printed when SDK is not installed sed -ie "s|http://go.microsoft.com/fwlink/?LinkID=798306&clcid=0x409|yum install %{?scl_prefix}dotnet-sdk-2.0|" src/core-setup/src/corehost/common/utils.h +%if %{centos} >= 7 +# Replace RHEL rid with CentOS rid +sed -i -e 's|rhel.7.4-|centos.%{centos}-|g' targets/core-setup.props +sed -i -e 's|rhel.7.4-|centos.%{centos}-|g' targets/cli.props + +# These patches explicitly force a RHEL runtime id +rm patches/corefx/0008-fix-ilasm.patch +rm patches/cli/0013-pass-rid-to-crossgen.csproj.patch +%endif + %build %{?scl:scl enable %scl - << \EOF} set -xe @@ -141,7 +151,7 @@ VERBOSE=1 ./build.sh /clp:v=detailed install -dm 755 $RPM_BUILD_ROOT/%{_libdir}/%{pkg_name}/ # for debugging find bin/x64/Release/ -tar xf bin/x64/Release/dotnet-sdk-%{sdk_version}-rhel.7.4-x64.tar.gz -C $RPM_BUILD_ROOT/%{_libdir}/%{pkg_name}/ +tar xf bin/x64/Release/dotnet-sdk-%{sdk_version}-centos.%{centos}-x64.tar.gz -C $RPM_BUILD_ROOT/%{_libdir}/%{pkg_name}/ install -dm 755 $RPM_BUILD_ROOT/%{_root_datadir}/bash-completion/completions # dynamic completion needs the file to be named the same as the base command @@ -199,6 +209,9 @@ find -type f -iname 'dotnet*\.1' -exec cp {} $RPM_BUILD_ROOT/%{_mandir}/man1/ \; %{_root_datadir}/zsh/site-functions/%{name} %changelog +* Wed Nov 29 2017 Johnny Hughes - 2.0.3-4.1 +- Mod to use CentOS rid + * Fri Nov 10 2017 Omair Majid - 2.0.3-4 - Make corefx build non-portable, which was how it was in 2.0.0