Browse Source

* fixed for win32 and go32v2

peter 25 years ago
parent
commit
441e44a83d
1 changed files with 11 additions and 0 deletions
  1. 11 0
      compiler/fpc.pas

+ 11 - 0
compiler/fpc.pas

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