* Use ExeSearch instead of FileSearch to find compiler/command executable

git-svn-id: trunk@12952 -
This commit is contained in:
joost 2009-03-22 10:08:24 +00:00
parent 0721235ab3
commit ad7f4a1f24

View File

@ -3231,7 +3231,7 @@ begin
O:=Substitute(C.Options,['SOURCE',C.SourceFile,'DEST',C.DestFile]);
Cmd:=C.Command;
If (ExtractFilePath(Cmd)='') then
Cmd:=FileSearch(Cmd,GetEnvironmentvariable('PATH'));
Cmd:=ExeSearch(Cmd,GetEnvironmentvariable('PATH'));
ExecuteCommand(Cmd,O,C.IgnoreResult);
If Assigned(C.AfterCommand) then
C.AfterCommand(C);
@ -3583,7 +3583,7 @@ begin
FCompiler:=Defaults.Compiler;
If (ExtractFilePath(FCompiler)='') then
begin
S:=FileSearch(FCompiler,GetEnvironmentVariable('PATH'));
S:=ExeSearch(FCompiler,GetEnvironmentVariable('PATH'));
If (S<>'') then
FCompiler:=S;
end;