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
|
Description: fix mipsel build with Linux ≥ 5.0
Linux 5.0 switched to generated system call table files, which needs some
changes in Chromium code. See this commit:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=99bf73ebf9c4193d
Author: Dmitry Shachnev <mitya57@debian.org>
Forwarded: not-yet
Last-Update: 2020-03-02
--- a/src/3rdparty/chromium/sandbox/linux/bpf_dsl/linux_syscall_ranges.h
+++ b/src/3rdparty/chromium/sandbox/linux/bpf_dsl/linux_syscall_ranges.h
@@ -37,14 +37,14 @@
#elif defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)
-#include <asm/unistd.h> // for __NR_O32_Linux and __NR_Linux_syscalls
+#include <asm/unistd_nr_o32.h> // for __NR_O32_Linux and __NR_O32_Linux_syscalls
#define MIN_SYSCALL __NR_O32_Linux
-#define MAX_PUBLIC_SYSCALL (MIN_SYSCALL + __NR_Linux_syscalls)
+#define MAX_PUBLIC_SYSCALL (MIN_SYSCALL + __NR_O32_Linux_syscalls)
#define MAX_SYSCALL MAX_PUBLIC_SYSCALL
#elif defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_64_BITS)
-#include <asm/unistd.h> // for __NR_64_Linux and __NR_64_Linux_syscalls
+#include <asm/unistd_nr_n64.h> // for __NR_64_Linux and __NR_64_Linux_syscalls
#define MIN_SYSCALL __NR_64_Linux
#define MAX_PUBLIC_SYSCALL (MIN_SYSCALL + __NR_64_Linux_syscalls)
#define MAX_SYSCALL MAX_PUBLIC_SYSCALL
--- a/src/3rdparty/chromium/sandbox/linux/bpf_dsl/syscall_set.cc
+++ b/src/3rdparty/chromium/sandbox/linux/bpf_dsl/syscall_set.cc
@@ -17,10 +17,10 @@ namespace {
#if defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_32_BITS)
// This is true for Mips O32 ABI.
-static_assert(MIN_SYSCALL == __NR_Linux, "min syscall number should be 4000");
+static_assert(MIN_SYSCALL == __NR_O32_Linux, "min syscall number should be 4000");
#elif defined(ARCH_CPU_MIPS_FAMILY) && defined(ARCH_CPU_64_BITS)
// This is true for MIPS N64 ABI.
-static_assert(MIN_SYSCALL == __NR_Linux, "min syscall number should be 5000");
+static_assert(MIN_SYSCALL == __NR_64_Linux, "min syscall number should be 5000");
#else
// This true for supported architectures (Intel and ARM EABI).
static_assert(MIN_SYSCALL == 0u,
|