Add the latest RISC-V development

Signed-off-by: David Abdurachmanov <david.abdurachmanov@sifive.com>
This commit is contained in:
David Abdurachmanov 2020-05-04 08:28:35 +03:00
parent 4d546acf92
commit 5f85e9d9dc
Signed by: davidlt
GPG Key ID: 8B7F1DA0E2C9FDBB
2 changed files with 4671 additions and 1 deletions

View File

@ -32,6 +32,9 @@ Patch3: openblas-0.3.7-tests.patch
# Fix C++ compatibility (BZ #1820131) # Fix C++ compatibility (BZ #1820131)
Patch4: https://github.com/xianyi/OpenBLAS/commit/ee2e758278b5d82b7242f505ea694f082ef65879.patch Patch4: https://github.com/xianyi/OpenBLAS/commit/ee2e758278b5d82b7242f505ea694f082ef65879.patch
# RISC-V 64-bit support (generated from risc-v upstream branch)
Patch10: riscv64.patch
BuildRequires: gcc BuildRequires: gcc
BuildRequires: gcc-c++ BuildRequires: gcc-c++
BuildRequires: gcc-gfortran BuildRequires: gcc-gfortran
@ -250,6 +253,10 @@ cd OpenBLAS-%{version}
%patch3 -p1 -b .tests %patch3 -p1 -b .tests
%patch4 -p1 -b .cplusplus %patch4 -p1 -b .cplusplus
%ifarch riscv64
%patch10 -p1 -b .riscv64
%endif
# Fix source permissions # Fix source permissions
find -name \*.f -exec chmod 644 {} \; find -name \*.f -exec chmod 644 {} \;
@ -391,7 +398,7 @@ TARGET="TARGET=ARMV8 DYNAMIC_ARCH=1 DYNAMIC_OLDER=1"
TARGET="TARGET=ZARCH_GENERIC DYNAMIC_ARCH=1 DYNAMIC_OLDER=1" TARGET="TARGET=ZARCH_GENERIC DYNAMIC_ARCH=1 DYNAMIC_OLDER=1"
%endif %endif
%ifarch riscv64 %ifarch riscv64
TARGET="TARGET=RISCV64 DYNAMIC_ARCH=0" TARGET="TARGET=RISCV64_GENERIC DYNAMIC_ARCH=0"
%endif %endif
%if 0%{?rhel} == 5 %if 0%{?rhel} == 5
@ -457,6 +464,9 @@ suffix=""
%ifarch armv7hl %ifarch armv7hl
suffix="_armv7" suffix="_armv7"
%endif %endif
%ifarch riscv64
suffix="_riscv64_generic"
%endif
slibname=`basename %{buildroot}%{_libdir}/libopenblas${suffix}-*.so .so` slibname=`basename %{buildroot}%{_libdir}/libopenblas${suffix}-*.so .so`
mv %{buildroot}%{_libdir}/${slibname}.a %{buildroot}%{_libdir}/lib%{name}.a mv %{buildroot}%{_libdir}/${slibname}.a %{buildroot}%{_libdir}/lib%{name}.a
if [[ "$suffix" != "" ]]; then if [[ "$suffix" != "" ]]; then
@ -675,6 +685,9 @@ rm -rf %{buildroot}%{_libdir}/pkgconfig
%endif %endif
%changelog %changelog
* Mon May 04 2020 David Abdurachmanov <david.abdurachmanvo@sifive.com> - 0.3.9-2.0.riscv64
- Enable RISC-V 64-bit (riscv64) support
* Thu Apr 02 2020 Susi Lehtola <jussilehtola@fedoraproject.org> - 0.3.9-2 * Thu Apr 02 2020 Susi Lehtola <jussilehtola@fedoraproject.org> - 0.3.9-2
- Patch for BZ #1820131. - Patch for BZ #1820131.

4657
riscv64.patch Normal file

File diff suppressed because it is too large Load Diff