Explorar o código

* Do not call with UseShell = true if CatFileContent expands the file into parameters

git-svn-id: trunk@19650 -
pierre %!s(int64=13) %!d(string=hai) anos
pai
achega
836da25e81
Modificáronse 3 ficheiros con 12 adicións e 6 borrados
  1. 4 2
      compiler/systems/t_beos.pas
  2. 4 2
      compiler/systems/t_bsd.pas
  3. 4 2
      compiler/systems/t_haiku.pas

+ 4 - 2
compiler/systems/t_beos.pas

@@ -363,7 +363,8 @@ function TLinkerBeOS.MakeExecutable:boolean;
 var
 var
   binstr,
   binstr,
   cmdstr : TCmdStr;
   cmdstr : TCmdStr;
-  success : boolean;
+  success,
+  useshell : boolean;
   DynLinkStr : string[60];
   DynLinkStr : string[60];
   GCSectionsStr,
   GCSectionsStr,
   StaticStr,
   StaticStr,
@@ -409,7 +410,8 @@ begin
   Replace(cmdstr,'$STRIP',StripStr);
   Replace(cmdstr,'$STRIP',StripStr);
   Replace(cmdstr,'$GCSECTIONS',GCSectionsStr);
   Replace(cmdstr,'$GCSECTIONS',GCSectionsStr);
   Replace(cmdstr,'$DYNLINK',DynLinkStr);
   Replace(cmdstr,'$DYNLINK',DynLinkStr);
-  success:=DoExec(FindUtil(utilsprefix+BinStr),CmdStr,true,true);
+  useshell:=not (tf_no_backquote_support in source_info.flags);
+  success:=DoExec(FindUtil(utilsprefix+BinStr),CmdStr,true,useshell);
 
 
 { Remove ReponseFile }
 { Remove ReponseFile }
   if (success) and not(cs_link_nolink in current_settings.globalswitches) then
   if (success) and not(cs_link_nolink in current_settings.globalswitches) then

+ 4 - 2
compiler/systems/t_bsd.pas

@@ -546,7 +546,8 @@ var
   GCSectionsStr,
   GCSectionsStr,
   StaticStr,
   StaticStr,
   StripStr   : string[63];
   StripStr   : string[63];
-  success : boolean;
+  success,
+  useshell : boolean;
 begin
 begin
   if not(cs_link_nolink in current_settings.globalswitches) then
   if not(cs_link_nolink in current_settings.globalswitches) then
    Message1(exec_i_linking,current_module.exefilename^);
    Message1(exec_i_linking,current_module.exefilename^);
@@ -633,7 +634,8 @@ begin
       CmdStr:='';
       CmdStr:='';
     end;
     end;
 
 
-  success:=DoExec(BinStr,CmdStr,true,LdSupportsNoResponseFile);
+  useshell:=not (tf_no_backquote_support in source_info.flags);
+  success:=DoExec(BinStr,CmdStr,true,LdSupportsNoResponseFile or useshell);
   if (success and
   if (success and
       (extdbgbinstr<>'') and
       (extdbgbinstr<>'') and
       (cs_link_nolink in current_settings.globalswitches)) then
       (cs_link_nolink in current_settings.globalswitches)) then

+ 4 - 2
compiler/systems/t_haiku.pas

@@ -363,7 +363,8 @@ function TLinkerHaiku.MakeExecutable:boolean;
 var
 var
   binstr,
   binstr,
   cmdstr : TCmdStr;
   cmdstr : TCmdStr;
-  success : boolean;
+  success,
+  useshell : boolean;
   DynLinkStr : string[60];
   DynLinkStr : string[60];
   GCSectionsStr,
   GCSectionsStr,
   StaticStr,
   StaticStr,
@@ -409,7 +410,8 @@ begin
   Replace(cmdstr,'$STRIP',StripStr);
   Replace(cmdstr,'$STRIP',StripStr);
   Replace(cmdstr,'$GCSECTIONS',GCSectionsStr);
   Replace(cmdstr,'$GCSECTIONS',GCSectionsStr);
   Replace(cmdstr,'$DYNLINK',DynLinkStr);
   Replace(cmdstr,'$DYNLINK',DynLinkStr);
-  success:=DoExec(FindUtil(utilsprefix+BinStr),CmdStr,true,true);
+  useshell:=not (tf_no_backquote_support in source_info.flags);
+  success:=DoExec(FindUtil(utilsprefix+BinStr),CmdStr,true,useshell);
 
 
 { Remove ReponseFile }
 { Remove ReponseFile }
   if (success) and not(cs_link_nolink in current_settings.globalswitches) then
   if (success) and not(cs_link_nolink in current_settings.globalswitches) then