浏览代码

* moved a linux specific call to the implementation of system, where
it is used. General Unix units should not expose Linux-specific
functionality.

git-svn-id: trunk@13427 -

marco 16 年之前
父节点
当前提交
7c52be9287
共有 2 个文件被更改,包括 4 次插入3 次删除
  1. 4 0
      rtl/linux/system.pp
  2. 0 3
      rtl/unix/oscdeclh.inc

+ 4 - 0
rtl/linux/system.pp

@@ -87,6 +87,10 @@ procedure haltproc(e:longint);cdecl;external name '_haltproc_eabi';
 procedure haltproc(e:longint);cdecl;external name '_haltproc';
 {$endif}
 
+{$ifdef FPC_USE_LIBC}
+function  FpPrCtl(options : cInt; const args : ptruint) : cint; cdecl; external clib name 'prctl';
+{$endif}
+
 procedure System_exit;
 begin
   haltproc(ExitCode);

+ 0 - 3
rtl/unix/oscdeclh.inc

@@ -156,6 +156,3 @@ const
     Function  FpPWrite     (fd : cInt; buf:pChar; nbytes : TSize; offset:Toff): TSSize;  cdecl; external clib name 'pwrite'+suffix64bit;
     function  FpWriteV	   (fd: cint; const iov : piovec; iovcnt : cint):TSSize;  cdecl; external clib name 'writev';
 
-{$ifdef linux}
-    function  FpPrCtl(options : cInt; const args : ptruint) : cint; cdecl; external clib name 'prctl';
-{$endif}