|
@@ -24,6 +24,14 @@ program fpc;
|
|
uses
|
|
uses
|
|
dos;
|
|
dos;
|
|
|
|
|
|
|
|
+ const
|
|
|
|
+{$ifdef UNIX}
|
|
|
|
+ exeext='';
|
|
|
|
+{$else UNIX}
|
|
|
|
+ exeext='.exe';
|
|
|
|
+{$endif UNIX}
|
|
|
|
+
|
|
|
|
+
|
|
procedure error(const s : string);
|
|
procedure error(const s : string);
|
|
begin
|
|
begin
|
|
writeln('Error: ',s);
|
|
writeln('Error: ',s);
|
|
@@ -92,6 +100,9 @@ program fpc;
|
|
ppccommandline:=ppccommandline+s+' ';
|
|
ppccommandline:=ppccommandline+s+' ';
|
|
end;
|
|
end;
|
|
|
|
|
|
|
|
+ { add .exe extension }
|
|
|
|
+ ppcbin:=ppcbin+exeext;
|
|
|
|
+
|
|
{ get path of fpc.exe }
|
|
{ get path of fpc.exe }
|
|
path:=splitpath(paramstr(0));
|
|
path:=splitpath(paramstr(0));
|
|
if FileExists(path+ppcbin) then
|
|
if FileExists(path+ppcbin) then
|