SHA256
1
0
forked from pool/binutils

Accepting request 591508 from home:Andreas_Schwab:Factory

- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
  relocatable link

OBS-URL: https://build.opensuse.org/request/show/591508
OBS-URL: https://build.opensuse.org/package/show/devel:gcc/binutils?expand=0&rev=274
This commit is contained in:
Michael Matz 2018-03-27 15:01:40 +00:00 committed by Git OBS Bridge
parent c0b27d2978
commit 87992c9ec4
45 changed files with 206 additions and 0 deletions

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -95,6 +95,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -167,6 +168,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Mar 22 17:11:45 UTC 2018 - schwab@suse.de
- riscv-relax-relocatable.patch: RISC-V: Don't enable relaxation in
relocatable link
-------------------------------------------------------------------
Tue Mar 20 11:26:23 UTC 2018 - rguenther@suse.com

View File

@ -98,6 +98,7 @@ Patch34: aarch64-common-pagesize.patch
Patch35: riscv-wrap-relax.patch
Patch36: binutils-pr22868.diff
Patch37: riscv-relax-size.patch
Patch38: riscv-relax-relocatable.patch
Patch90: cross-avr-nesc-as.patch
Patch92: cross-avr-omit_section_dynsym.patch
Patch93: cross-avr-size.patch
@ -170,6 +171,7 @@ echo "make check will return with %{make_check_handling} in case of testsuite fa
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%if "%{TARGET}" == "avr"
cp gas/config/tc-avr.h gas/config/tc-avr-nesc.h
%patch90

View File

@ -0,0 +1,30 @@
2018-03-15 Andreas Schwab <schwab@suse.de>
PR ld/22949
* emultempl/riscvelf.em (riscv_elf_before_allocation): Don't
enable relaxation in relocatable link.
Index: binutils-2.30/ld/emultempl/riscvelf.em
===================================================================
--- binutils-2.30.orig/ld/emultempl/riscvelf.em
+++ binutils-2.30/ld/emultempl/riscvelf.em
@@ -33,11 +33,14 @@ riscv_elf_before_allocation (void)
if (link_info.discard == discard_sec_merge)
link_info.discard = discard_l;
- /* We always need at least some relaxation to handle code alignment. */
- if (RELAXATION_DISABLED_BY_USER)
- TARGET_ENABLE_RELAXATION;
- else
- ENABLE_RELAXATION;
+ if (!bfd_link_relocatable (&link_info))
+ {
+ /* We always need at least some relaxation to handle code alignment. */
+ if (RELAXATION_DISABLED_BY_USER)
+ TARGET_ENABLE_RELAXATION;
+ else
+ ENABLE_RELAXATION;
+ }
link_info.relax_pass = 3;
}