mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-13 11:59:19 +02:00
* Try to update i386/openbsd port
git-svn-id: trunk@19350 -
This commit is contained in:
parent
7e87ca4c3c
commit
7f69e6426d
@ -50,6 +50,7 @@ begin
|
|||||||
FPsigsuspend:= do_syscall(syscall_nr_sigsuspend,TSysParam(@sigmask));
|
FPsigsuspend:= do_syscall(syscall_nr_sigsuspend,TSysParam(@sigmask));
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
{$ifndef FPC_SYS_SIGTIMEDWAIT_UNAVAILABLE}
|
||||||
function fpsigtimedwait(const sigset:TSigSet;info:Psiginfo;timeout:Ptimespec):cint;
|
function fpsigtimedwait(const sigset:TSigSet;info:Psiginfo;timeout:Ptimespec):cint;
|
||||||
|
|
||||||
begin
|
begin
|
||||||
@ -58,6 +59,7 @@ begin
|
|||||||
Tsysparam(info),
|
Tsysparam(info),
|
||||||
Tsysparam(timeout));
|
Tsysparam(timeout));
|
||||||
end;
|
end;
|
||||||
|
{$endif ndef FPC_SYS_SIGTIMEDWAIT_UNAVAILABLE}
|
||||||
|
|
||||||
|
|
||||||
Type // implementation side for now. Should move to BSD unit.
|
Type // implementation side for now. Should move to BSD unit.
|
||||||
@ -567,7 +569,7 @@ end;
|
|||||||
function Fppread(fd: cint; buf: pchar; nbytes : size_t; offset:Toff): ssize_t; [public, alias : 'FPC_SYSC_PREAD'];
|
function Fppread(fd: cint; buf: pchar; nbytes : size_t; offset:Toff): ssize_t; [public, alias : 'FPC_SYSC_PREAD'];
|
||||||
|
|
||||||
begin
|
begin
|
||||||
|
|
||||||
{$ifdef CPU64}
|
{$ifdef CPU64}
|
||||||
Fppread:=do_syscall(syscall_nr_pread,Fd,TSysParam(buf),nbytes,TSysParam(OffSet));
|
Fppread:=do_syscall(syscall_nr_pread,Fd,TSysParam(buf),nbytes,TSysParam(OffSet));
|
||||||
{$else}
|
{$else}
|
||||||
|
@ -24,7 +24,9 @@ Type TGrpArr = Array [0..0] of TGid; { C style array workarounds}
|
|||||||
Function FpSigProcMask (how : cInt; Const nset : TSigSet; var oset : TSigSet): cInt; external name 'FPC_SYSC_SIGPROCMASK';
|
Function FpSigProcMask (how : cInt; Const nset : TSigSet; var oset : TSigSet): cInt; external name 'FPC_SYSC_SIGPROCMASK';
|
||||||
Function FpSigPending (var nset : TSigSet): cInt;
|
Function FpSigPending (var nset : TSigSet): cInt;
|
||||||
Function FpSigSuspend (Const sigmask : TSigSet): cInt;
|
Function FpSigSuspend (Const sigmask : TSigSet): cInt;
|
||||||
|
{$ifndef FPC_SYS_SIGTIMEDWAIT_UNAVAILABLE}
|
||||||
Function FpSigTimedWait (Const sigset : TSigSet; info : Psiginfo; timeout:Ptimespec): cInt;
|
Function FpSigTimedWait (Const sigset : TSigSet; info : Psiginfo; timeout:Ptimespec): cInt;
|
||||||
|
{$endif ndef FPC_SYS_SIGTIMEDWAIT_UNAVAILABLE}
|
||||||
|
|
||||||
Function FpUmask (cmask : TMode): TMode;
|
Function FpUmask (cmask : TMode): TMode;
|
||||||
Function FpLink (existing : pChar; newone : pChar): cInt;
|
Function FpLink (existing : pChar; newone : pChar): cInt;
|
||||||
@ -85,7 +87,7 @@ Type TGrpArr = Array [0..0] of TGid; { C style array workarounds}
|
|||||||
function FpReadV (fd: cint; const iov : piovec; iovcnt : cint):TSSize;
|
function FpReadV (fd: cint; const iov : piovec; iovcnt : cint):TSSize;
|
||||||
Function FpWrite (fd : cInt; buf:pChar; nbytes : TSize): TSsize; external name 'FPC_SYSC_WRITE';
|
Function FpWrite (fd : cInt; buf:pChar; nbytes : TSize): TSsize; external name 'FPC_SYSC_WRITE';
|
||||||
Function FpPWrite (fd : cInt; buf:pChar; nbytes : TSize; offset:Toff): TSSize;
|
Function FpPWrite (fd : cInt; buf:pChar; nbytes : TSize; offset:Toff): TSSize;
|
||||||
function FpWriteV (fd: cint; const iov : piovec; iovcnt : cint):TSSize;
|
function FpWriteV (fd: cint; const iov : piovec; iovcnt : cint):TSSize;
|
||||||
|
|
||||||
Function FpLseek (fd : cInt; offset : TOff; whence : cInt): TOff; external name 'FPC_SYSC_LSEEK';
|
Function FpLseek (fd : cInt; offset : TOff; whence : cInt): TOff; external name 'FPC_SYSC_LSEEK';
|
||||||
Function FpTime (var tloc : TTime): TTime; external name 'FPC_SYSC_TIME';
|
Function FpTime (var tloc : TTime): TTime; external name 'FPC_SYSC_TIME';
|
||||||
|
@ -47,7 +47,7 @@ Type
|
|||||||
Const
|
Const
|
||||||
{ IPC flags for get calls }
|
{ IPC flags for get calls }
|
||||||
|
|
||||||
{$if defined(FreeBSD) or defined(NetBSD)} // BSD_VISIBLE
|
{$if defined(FreeBSD) or defined(NetBSD) or defined(OpenBSD)} // BSD_VISIBLE
|
||||||
IPC_R = 4 shl 6;
|
IPC_R = 4 shl 6;
|
||||||
IPC_W = 2 shl 6;
|
IPC_W = 2 shl 6;
|
||||||
IPC_M = 2 shl 12;
|
IPC_M = 2 shl 12;
|
||||||
@ -63,7 +63,7 @@ Const
|
|||||||
IPC_EXCL = 2 shl 9; { fail if key exists }
|
IPC_EXCL = 2 shl 9; { fail if key exists }
|
||||||
IPC_NOWAIT = 4 shl 9; { return error on wait }
|
IPC_NOWAIT = 4 shl 9; { return error on wait }
|
||||||
|
|
||||||
{$if defined(FreeBSD) or defined(Darwin) or defined(Linux)}
|
{$if defined(FreeBSD) or defined(Darwin) or defined(Linux) or defined(OpenBSD)}
|
||||||
IPC_PRIVATE : TKey = 0;
|
IPC_PRIVATE : TKey = 0;
|
||||||
{$endif}
|
{$endif}
|
||||||
|
|
||||||
@ -81,7 +81,7 @@ type
|
|||||||
{$ifdef darwin}
|
{$ifdef darwin}
|
||||||
{$packrecords 4}
|
{$packrecords 4}
|
||||||
{$endif}
|
{$endif}
|
||||||
{$if defined(FreeBSD) or defined(Darwin)}
|
{$if defined(FreeBSD) or defined(Darwin) or defined(OpenBSD)}
|
||||||
TIPC_Perm = record
|
TIPC_Perm = record
|
||||||
cuid : cushort; { creator user id }
|
cuid : cushort; { creator user id }
|
||||||
cgid : cushort; { creator group id }
|
cgid : cushort; { creator group id }
|
||||||
@ -146,7 +146,7 @@ Function ftok (Path : pchar; ID : cint) : TKey; {$ifdef FPC_USE_LIBC} cdecl; ex
|
|||||||
Type
|
Type
|
||||||
PShmid_DS = ^TShmid_ds;
|
PShmid_DS = ^TShmid_ds;
|
||||||
|
|
||||||
{$ifdef FreeBSD}
|
{$if defined(FreeBSD) or defined(OpenBSD)}
|
||||||
TShmid_ds = record
|
TShmid_ds = record
|
||||||
shm_perm : TIPC_Perm;
|
shm_perm : TIPC_Perm;
|
||||||
shm_segsz : cint;
|
shm_segsz : cint;
|
||||||
@ -190,7 +190,7 @@ Type
|
|||||||
__unused4 : culong;
|
__unused4 : culong;
|
||||||
__unused5 : culong;
|
__unused5 : culong;
|
||||||
end;
|
end;
|
||||||
{$else cpux86_64}
|
{$else cpux86_64}
|
||||||
TShmid_ds = record
|
TShmid_ds = record
|
||||||
shm_perm : TIPC_Perm;
|
shm_perm : TIPC_Perm;
|
||||||
shm_segsz : cint;
|
shm_segsz : cint;
|
||||||
@ -204,7 +204,7 @@ Type
|
|||||||
shm_pages : pointer;
|
shm_pages : pointer;
|
||||||
attaches : pointer;
|
attaches : pointer;
|
||||||
end;
|
end;
|
||||||
{$endif cpux86_64}
|
{$endif cpux86_64}
|
||||||
{$endif}
|
{$endif}
|
||||||
|
|
||||||
const
|
const
|
||||||
@ -243,7 +243,7 @@ type // the shm*info kind is "kernel" only.
|
|||||||
shmall : cint;
|
shmall : cint;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
{$if defined(FreeBSD) or defined(Linux)}
|
{$if defined(FreeBSD) or defined(OpenBSD) or defined(Linux)}
|
||||||
PSHM_info = ^TSHM_info;
|
PSHM_info = ^TSHM_info;
|
||||||
TSHM_info = record
|
TSHM_info = record
|
||||||
used_ids : cint;
|
used_ids : cint;
|
||||||
@ -279,7 +279,7 @@ type
|
|||||||
msglen_t = culong;
|
msglen_t = culong;
|
||||||
msgqnum_t= culong;
|
msgqnum_t= culong;
|
||||||
|
|
||||||
{$ifdef Darwin}
|
{$ifdef Darwin}
|
||||||
user_msglen_t = culonglong;
|
user_msglen_t = culonglong;
|
||||||
user_msgqnum_t= culonglong;
|
user_msgqnum_t= culonglong;
|
||||||
{$endif}
|
{$endif}
|
||||||
@ -287,7 +287,7 @@ type
|
|||||||
PMSG = ^TMSG;
|
PMSG = ^TMSG;
|
||||||
TMSG = record
|
TMSG = record
|
||||||
{$ifndef FreeBSD} // opague in FreeBSD
|
{$ifndef FreeBSD} // opague in FreeBSD
|
||||||
{$ifdef Darwin}
|
{$ifdef Darwin}
|
||||||
msg_next : PMSG;
|
msg_next : PMSG;
|
||||||
msg_type : clong;
|
msg_type : clong;
|
||||||
msg_ts : cushort;
|
msg_ts : cushort;
|
||||||
|
Loading…
Reference in New Issue
Block a user