!35 【轻量级 PR】:add fully supported for riscv64.
From: @liqingqing_1229 Reviewed-by: @hanxinke Signed-off-by: @hanxinke
This commit is contained in:
commit
53420df9dc
@ -1,7 +1,7 @@
|
|||||||
Summary: Binary utilities
|
Summary: Binary utilities
|
||||||
Name: binutils
|
Name: binutils
|
||||||
Version: 2.34
|
Version: 2.34
|
||||||
Release: 6
|
Release: 7
|
||||||
License: GPLv3+
|
License: GPLv3+
|
||||||
URL: https://sourceware.org/binutils
|
URL: https://sourceware.org/binutils
|
||||||
|
|
||||||
@ -125,12 +125,12 @@ touch */configure
|
|||||||
|
|
||||||
%build
|
%build
|
||||||
CARGS=
|
CARGS=
|
||||||
case %{_target_platform} in i?86*|arm*|aarch64*)
|
case %{_target_platform} in i?86*|arm*|aarch64*|riscv64*)
|
||||||
CARGS="$CARGS --enable-64-bit-bfd"
|
CARGS="$CARGS --enable-64-bit-bfd"
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
case %{_target_platform} in x86_64*|i?86*|aarch64*)
|
case %{_target_platform} in x86_64*|i?86*|aarch64*|riscv64*)
|
||||||
CARGS="$CARGS --enable-targets=x86_64-pep --enable-relro=yes"
|
CARGS="$CARGS --enable-targets=x86_64-pep --enable-relro=yes"
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
@ -207,7 +207,7 @@ sed -i -e '/^#include "ansidecl.h"/{p;s~^.*$~#include <bits/wordsize.h>~;}' \
|
|||||||
%endif
|
%endif
|
||||||
touch -r bfd/bfd-in2.h %{buildroot}%{_prefix}/include/bfd.h
|
touch -r bfd/bfd-in2.h %{buildroot}%{_prefix}/include/bfd.h
|
||||||
|
|
||||||
# Generate libbfd.so and libbfd.so
|
# Generate libbfd.so and libopcodes.so
|
||||||
|
|
||||||
%ifarch x86_64
|
%ifarch x86_64
|
||||||
tee %{buildroot}%{_libdir}/libbfd.so <<EOF
|
tee %{buildroot}%{_libdir}/libbfd.so <<EOF
|
||||||
@ -245,6 +245,24 @@ INPUT ( %{_libdir}/libopcodes.a -lbfd )
|
|||||||
EOF
|
EOF
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
|
%ifarch riscv64
|
||||||
|
tee %{buildroot}%{_libdir}/libbfd.so <<EOF
|
||||||
|
/* GNU ld script */
|
||||||
|
|
||||||
|
OUTPUT_FORMAT(elf64-littleriscv)
|
||||||
|
|
||||||
|
INPUT ( %{_libdir}/libbfd.a -liberty -lz -ldl )
|
||||||
|
EOF
|
||||||
|
|
||||||
|
tee %{buildroot}%{_libdir}/libopcodes.so <<EOF
|
||||||
|
/* GNU ld script */
|
||||||
|
|
||||||
|
OUTPUT_FORMAT(elf64-littleriscv)
|
||||||
|
|
||||||
|
INPUT ( %{_libdir}/libopcodes.a -lbfd )
|
||||||
|
EOF
|
||||||
|
%endif
|
||||||
|
|
||||||
rm -f %{buildroot}%{_infodir}/dir
|
rm -f %{buildroot}%{_infodir}/dir
|
||||||
rm -rf %{buildroot}%{_prefix}/%{_target_platform}
|
rm -rf %{buildroot}%{_prefix}/%{_target_platform}
|
||||||
|
|
||||||
@ -345,6 +363,11 @@ fi
|
|||||||
%{_infodir}/bfd*info*
|
%{_infodir}/bfd*info*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Wed Nov 4 2020 Qingqing Li <liqingqing3@huawei.com> - 2.34-7
|
||||||
|
- Type:bugfix
|
||||||
|
- ID:NA
|
||||||
|
- SUG:fully support for riscv64.
|
||||||
|
|
||||||
* Tue Nov 3 2020 Qingqing Li <liqingqing3@huawei.com> - 2.34-6
|
* Tue Nov 3 2020 Qingqing Li <liqingqing3@huawei.com> - 2.34-6
|
||||||
- Type:bugfix
|
- Type:bugfix
|
||||||
- ID:NA
|
- ID:NA
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user