Explorar o código

* only use ld -T in case of cross-link (-XR), because not all platforms have complete link script yet

git-svn-id: trunk@8718 -
micha %!s(int64=18) %!d(string=hai) anos
pai
achega
89b5825029
Modificáronse 1 ficheiros con 5 adicións e 1 borrados
  1. 5 1
      compiler/systems/t_linux.pas

+ 5 - 1
compiler/systems/t_linux.pas

@@ -239,7 +239,11 @@ var
 begin
   with Info do
    begin
-     ExeCmd[1]:='ld '+platform_select+' $OPT $DYNLINK $STATIC $GCSECTIONS $STRIP -L. -o $EXE -T $RES';
+     ExeCmd[1]:='ld '+platform_select+' $OPT $DYNLINK $STATIC $GCSECTIONS $STRIP -L. -o $EXE';
+     { when we want to cross-link we need to override default library paths }
+     if length(sysrootpath) > 0 then
+       ExeCmd[1]:=ExeCmd[1]+' -T';
+     ExeCmd[1]:=ExeCmd[1]+' $RES';
      DllCmd[1]:='ld '+platform_select+' $OPT $INIT $FINI $SONAME -shared -L. -o $EXE $RES -E';
      DllCmd[2]:='strip --strip-unneeded $EXE';
 {$ifdef m68k}