Changeset 83 for trunk/UTarget.pas


Ignore:
Timestamp:
Aug 4, 2017, 9:11:00 AM (7 years ago)
Author:
chronos
Message:
  • Added: Show meaningful error message if target compiler or executor doesn't exist.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/UTarget.pas

    r72 r83  
    144144resourcestring
    145145  SCompilerNotFound = 'Compiler "%s" not found';
     146  SExecutorNotFound = 'Executor "%s" not found';
    146147  SCompiledFileNotFound = 'Program compiled file "%s" not found';
    147148
     
    420421    Free;
    421422  end;
    422   if CompilerPath <> '' then begin
    423     if FileExistsUTF8(CompilerPath) then
     423  if FileExistsUTF8(CompilerPath) then
    424424    try
    425425      Process := TProcess.Create(nil);
     
    441441      Process.Free;
    442442    end else raise Exception.Create(Format(SCompilerNotFound, [CompilerPath]));
    443   end;
    444443end;
    445444
     
    456455    'compiled' + DirectorySeparator + Name + DirectorySeparator +
    457456    ExtractFileNameOnly(ProjectFileName) + RunExtension;
     457  if not FileExistsUTF8(ExecutorPath) then
     458    raise Exception.Create(Format(SExecutorNotFound, [ExecutorPath]));
    458459  if FileExistsUTF8(CompiledFile) then
    459460  try
Note: See TracChangeset for help on using the changeset viewer.