mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-11-03 12:49:26 +01:00
* arm-linux-eabi uses mmap2 and ugetrlimit
git-svn-id: trunk@11908 -
This commit is contained in:
parent
7b188a6a0e
commit
7c6e0a48e9
@ -33,7 +33,8 @@
|
||||
{$endif}
|
||||
{$endif}
|
||||
|
||||
{$if defined(cpupowerpc) or defined(cpupowerpc64) or defined(cpui386)}
|
||||
{$if defined(cpupowerpc) or defined(cpupowerpc64) or defined(cpui386) or
|
||||
(defined(cpuarm) and defined(FPC_ABI_EABI))}
|
||||
{$DEFINE has_ugetrlimit}
|
||||
{$endif}
|
||||
|
||||
|
||||
@ -471,7 +471,11 @@ type
|
||||
{$endif cpum68k}
|
||||
|
||||
{$ifdef cpuarm}
|
||||
{$define OLDMMAP}
|
||||
{$ifdef FPC_ABI_EABI}
|
||||
{$define MMAP2}
|
||||
{$else FPC_ABI_EABI}
|
||||
{$define OLDMMAP}
|
||||
{$endif FPC_ABI_EABI}
|
||||
{$endif cpuarm}
|
||||
|
||||
|
||||
@ -491,11 +495,19 @@ begin
|
||||
Fpmmap:=pointer(do_syscall(syscall_nr_mmap,TSysParam(@MMapArgs)));
|
||||
end;
|
||||
{$else OLDMMAP}
|
||||
{$ifdef MMAP2}
|
||||
begin
|
||||
{$message warning need mmap64 syscall, hi(off) not used}
|
||||
Fpmmap:= pointer(do_syscall(syscall_nr_mmap2,TSysParam(adr),TSysParam(len),
|
||||
TSysParam(prot),TSysParam(flags),TSysParam(fd),TSysParam(lo(off))));
|
||||
end;
|
||||
{$else MMAP2}
|
||||
begin
|
||||
{$message warning need mmap64 syscall, hi(off) not used}
|
||||
Fpmmap:= pointer(do_syscall(syscall_nr_mmap,TSysParam(adr),TSysParam(len),
|
||||
TSysParam(prot),TSysParam(flags),TSysParam(fd),TSysParam(lo(off))));
|
||||
end;
|
||||
{$endif MMAP2}
|
||||
{$endif OLDMMAP}
|
||||
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user