From c421f4d91e469eec13225d91ee07e490d084cc81 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?K=C3=A1roly=20Balogh?= <karoly@freepascal.org>
Date: Wed, 18 Feb 2015 14:09:15 +0000
Subject: [PATCH] do not include outputexedir in linker resname. it causes the
 path to be double-included when cross-compiling with -st and -FE on Liunuxes.
 also, be consistent between linking on host and target.

git-svn-id: trunk@29753 -
---
 compiler/link.pas | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/compiler/link.pas b/compiler/link.pas
index 7731666d18..297df93093 100644
--- a/compiler/link.pas
+++ b/compiler/link.pas
@@ -620,8 +620,8 @@ Implementation
         FillChar(Info,sizeof(Info),0);
         if cs_link_on_target in current_settings.globalswitches then
           begin
-            Info.ResName:=outputexedir+ChangeFileExt(inputfilename,'_link.res');
-            Info.ScriptName:=outputexedir+ChangeFileExt(inputfilename,'_script.res');
+            Info.ResName:=ChangeFileExt(inputfilename,'_link.res');
+            Info.ScriptName:=ChangeFileExt(inputfilename,'_script.res');
           end
         else
           begin