From: Peter Michael Green Date: Thu, 14 Jan 2021 20:35:41 +0000 (+0000) Subject: Use ld.bfd explicitly X-Git-Tag: archive/raspbian/3.2.0+dfsg-12+rpi1~22 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=5f0da0d6a128566fa0a8500315879ac75b0dc744;p=fpc.git Use ld.bfd explicitly Bug-Debian: http://bugs.debian.org/620815 Bug-Debian: http://bugs.debian.org/624525 Bug-Debian: http://bugs.debian.org/717651 Freepascal is broken with ld.gold, previously we conflicted with binutils-gold but that makes us uninstallable with the new binutils. So instead we take the approach of patching fpc to use ld.bfd directly Gbp-Pq: Name use-bfd-explicitly.diff --- diff --git a/fpcsrc/compiler/systems/t_linux.pas b/fpcsrc/compiler/systems/t_linux.pas index a7398fb9..a5986f6b 100644 --- a/fpcsrc/compiler/systems/t_linux.pas +++ b/fpcsrc/compiler/systems/t_linux.pas @@ -1408,7 +1408,7 @@ begin if HasExports then cmdstr:=cmdstr+' -E'; - success:=DoExec(FindUtil(utilsprefix+BinStr),CmdStr,true,false); + success:=DoExec(FindUtil(utilsprefix+BinStr)+'.bfd',CmdStr,true,false); { Create external .dbg file with debuginfo } if success and (cs_link_separate_dbg_file in current_settings.globalswitches) then @@ -1476,7 +1476,7 @@ begin Replace(cmdstr,'$SONAME',SoNameStr); Replace(cmdstr,'$MAP',mapstr); Replace(cmdstr,'$GCSECTIONS',GCSectionsStr); - success:=DoExec(FindUtil(utilsprefix+binstr),cmdstr,true,false); + success:=DoExec(FindUtil(utilsprefix+binstr)+'.bfd',cmdstr,true,false); { Strip the library ? } if success and (cs_link_strip in current_settings.globalswitches) then