mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-13 09:39:09 +02:00
* unix does ansistring exec
This commit is contained in:
parent
aeaf3e9d2c
commit
64e776098a
@ -21,8 +21,10 @@
|
|||||||
****************************************************************************}
|
****************************************************************************}
|
||||||
program fpc;
|
program fpc;
|
||||||
|
|
||||||
|
{$mode objfpc}{$H+}
|
||||||
|
|
||||||
uses
|
uses
|
||||||
dos;
|
Sysutils,dos;
|
||||||
|
|
||||||
const
|
const
|
||||||
{$ifdef UNIX}
|
{$ifdef UNIX}
|
||||||
@ -43,7 +45,7 @@ program fpc;
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
function SplitPath(Const HStr:ShortString):ShortString;
|
function SplitPath(Const HStr:String):String;
|
||||||
var
|
var
|
||||||
i : longint;
|
i : longint;
|
||||||
begin
|
begin
|
||||||
@ -54,7 +56,7 @@ program fpc;
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
function FileExists ( Const F : ShortString) : Boolean;
|
function FileExists ( Const F : String) : Boolean;
|
||||||
var
|
var
|
||||||
Info : SearchRec;
|
Info : SearchRec;
|
||||||
begin
|
begin
|
||||||
@ -85,11 +87,11 @@ program fpc;
|
|||||||
|
|
||||||
|
|
||||||
var
|
var
|
||||||
s,
|
s : ansistring;
|
||||||
processorname,
|
processorname,
|
||||||
ppcbin,
|
ppcbin,
|
||||||
versionStr,
|
versionStr,
|
||||||
processorstr : shortstring;
|
processorstr : string;
|
||||||
ppccommandline : ansistring;
|
ppccommandline : ansistring;
|
||||||
i : longint;
|
i : longint;
|
||||||
begin
|
begin
|
||||||
@ -162,7 +164,11 @@ program fpc;
|
|||||||
|
|
||||||
{ call ppcXXX }
|
{ call ppcXXX }
|
||||||
swapvectors;
|
swapvectors;
|
||||||
exec(ppcbin,ppccommandline);
|
{$ifdef unix}
|
||||||
|
SysUtils.exec(ppcbin,ppccommandline);
|
||||||
|
{$else}
|
||||||
|
Dos.exec(ppcbin,ppccommandline);
|
||||||
|
{$endif}
|
||||||
swapvectors;
|
swapvectors;
|
||||||
if doserror<>0 then
|
if doserror<>0 then
|
||||||
error(ppcbin+' can''t be executed');
|
error(ppcbin+' can''t be executed');
|
||||||
@ -170,7 +176,10 @@ program fpc;
|
|||||||
end.
|
end.
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.8 2003-10-08 19:16:50 peter
|
Revision 1.9 2004-01-03 09:12:23 marco
|
||||||
|
* unix does ansistring exec
|
||||||
|
|
||||||
|
Revision 1.8 2003/10/08 19:16:50 peter
|
||||||
* -Q back to -P, -L back to -V
|
* -Q back to -P, -L back to -V
|
||||||
|
|
||||||
Revision 1.7 2003/09/30 17:25:01 marco
|
Revision 1.7 2003/09/30 17:25:01 marco
|
||||||
|
Loading…
Reference in New Issue
Block a user