1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50
|
From 27084cb9b8a0cdc0bdaae792a329ea3b35a9ef92 Mon Sep 17 00:00:00 2001
From: Niko Tyni <ntyni@debian.org>
Date: Sat, 21 May 2016 14:05:31 +0000
Subject: [PATCH] Add mips* support
Bug-Debian: https://bugs.debian.org/824936
---
lib/Sys/Syscall.pm | 19 +++++++++++++++++++
1 file changed, 19 insertions(+)
diff --git a/lib/Sys/Syscall.pm b/lib/Sys/Syscall.pm
index b7ac0ce..165b152 100644
--- a/lib/Sys/Syscall.pm
+++ b/lib/Sys/Syscall.pm
@@ -64,6 +64,11 @@ if ($^O eq "linux") {
$machine = "i386";
}
+ # Similarly for mips64 vs mips
+ if ($machine eq "mips64" && $Config{ptrsize} == 4) {
+ $machine = "mips";
+ }
+
if ($machine =~ m/^i[3456]86$/) {
$SYS_epoll_create = 254;
$SYS_epoll_ctl = 255;
@@ -113,6 +118,20 @@ if ($^O eq "linux") {
$SYS_sendfile = 187;
$SYS_readahead = 225;
$u64_mod_8 = 1;
+ } elsif ($machine =~ m/^mips64/) {
+ $SYS_sendfile = 5039;
+ $SYS_epoll_create = 5207;
+ $SYS_epoll_ctl = 5208;
+ $SYS_epoll_wait = 5209;
+ $SYS_readahead = 5179;
+ $u64_mod_8 = 1;
+ } elsif ($machine =~ m/^mips/) {
+ $SYS_sendfile = 4207;
+ $SYS_epoll_create = 4248;
+ $SYS_epoll_ctl = 4249;
+ $SYS_epoll_wait = 4250;
+ $SYS_readahead = 4223;
+ $u64_mod_8 = 1;
} else {
# as a last resort, try using the *.ph files which may not
# exist or may be wrong
--
2.1.4
|