You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gentoo-overlay/dev-util/trinity/files/trinity-1.9-include_types_h...

34 lines
1.1 KiB

From 45fdc97620063be4318b9b361482fa1b5463e1d5 Mon Sep 17 00:00:00 2001
From: Jiri Slaby <jslaby@suse.cz>
Date: Mon, 18 Nov 2019 10:14:55 +0100
Subject: [PATCH] modify_ldt: include linux/types.h before ASSEMBLY == 1
Otherwise we see a lot of:
In file included from /usr/include/bits/statx.h:30,
from /usr/include/sys/stat.h:446,
from include/files.h:3,
from include/shm.h:6,
from syscalls/x86/modify_ldt.c:12:
/usr/include/linux/stat.h:57:2: error: unknown type name '__s64'
57 | __s64 tv_sec;
| ^~~~~
/usr/include/linux/stat.h:58:2: error: unknown type name '__u32'
58 | __u32 tv_nsec;
| ^~~~~
---
syscalls/x86/modify_ldt.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/syscalls/x86/modify_ldt.c b/syscalls/x86/modify_ldt.c
index f2eaf065..0221561a 100644
--- a/syscalls/x86/modify_ldt.c
+++ b/syscalls/x86/modify_ldt.c
@@ -6,6 +6,7 @@
*/
#include <stdlib.h>
#include <sys/types.h>
+#include <linux/types.h> /* before __ASSEMBLY__ == 1 */
#define __ASSEMBLY__ 1
#include <asm/ldt.h>
#include "sanitise.h"