Skip to contentSkip to conversation

Include string.h before console.h

PATCH Superseded Wei Liu 2 participants 3 messages Oct 4, 2017 Library code

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore

Wei Liu

author
#0 lore raw

PATCH 1/1 Include string.h before console.h

Starting from Xen commit af8d93564, it is required to include string.h before console.h.

---
Cc: Ian Jackson <[email protected]>
Cc: Julien Grall <[email protected]>
Cc: Samuel Thibault <[email protected]>

After applying this patch to mini-os I will update Xen's Config.mk to fix the build failure in xen.git.

I will also update mini-os's copy of Xen headers later.

---
 lib/sys.c | 1 +
 main.c    | 1 +
 2 files changed, 2 insertions(+)
lib/sys.c +1 -0
index b173bc8..23dc2a5 100644
@@ -20,6 +20,7 @@
 
 #ifdef HAVE_LIBC
 #include <os.h>
+#include <string.h>
 #include <console.h>
 #include <sched.h>
 #include <events.h>
main.c +1 -0
index 263364c..4e42f53 100644
@@ -8,6 +8,7 @@
 #include <os.h>
 #include <kernel.h>
 #include <sched.h>
+#include <string.h>
 #include <console.h>
 #include <netfront.h>
 #include <pcifront.h>
Signature · 7 lines
2.11.0


_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xen.org/xen-devel
author
#1 lore raw
Quoted 4 lines · Wei Liu

Starting from Xen commit af8d93564, it is required to include string.h before console.h.

Sorry this one isn't complete. There are other instances where string.h are needed. But the basic idea is the same.

Quoted 41 lines

---
Cc: Ian Jackson <[email protected]>
Cc: Julien Grall <[email protected]>
Cc: Samuel Thibault <[email protected]>

After applying this patch to mini-os I will update Xen's Config.mk to fix the build failure in xen.git.

I will also update mini-os's copy of Xen headers later.

---
 lib/sys.c | 1 +
 main.c    | 1 +
 2 files changed, 2 insertions(+)
lib/sys.c +1 -0
index b173bc8..23dc2a5 100644
@@ -20,6 +20,7 @@
 
 #ifdef HAVE_LIBC
 #include <os.h>
+#include <string.h>
 #include <console.h>
 #include <sched.h>
 #include <events.h>
main.c +1 -0
index 263364c..4e42f53 100644
@@ -8,6 +8,7 @@
 #include <os.h>
 #include <kernel.h>
 #include <sched.h>
+#include <string.h>
 #include <console.h>
 #include <netfront.h>
 #include <pcifront.h>
Signature · 1 line
2.11.0

_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xen.org/xen-devel

Reviewed-by on v1 1/1
#2 lore raw
In reply to Wei Liu
Quoted 4 lines · Wei Liu, on mer. 04 oct. 2017 14:33:36 +0100, wrote:

Starting from Xen commit af8d93564, it is required to include string.h before console.h.

Quoted 41 lines

---
Cc: Ian Jackson <[email protected]>
Cc: Julien Grall <[email protected]>
Cc: Samuel Thibault <[email protected]>

After applying this patch to mini-os I will update Xen's Config.mk to fix the build failure in xen.git.

I will also update mini-os's copy of Xen headers later.

---
 lib/sys.c | 1 +
 main.c    | 1 +
 2 files changed, 2 insertions(+)
lib/sys.c +1 -0
index b173bc8..23dc2a5 100644
@@ -20,6 +20,7 @@
 
 #ifdef HAVE_LIBC
 #include <os.h>
+#include <string.h>
 #include <console.h>
 #include <sched.h>
 #include <events.h>
main.c +1 -0
index 263364c..4e42f53 100644
@@ -8,6 +8,7 @@
 #include <os.h>
 #include <kernel.h>
 #include <sched.h>
+#include <string.h>
 #include <console.h>
 #include <netfront.h>
 #include <pcifront.h>
Signature · 1 line
2.11.0
Signature · 8 lines
Samuel
 Battery 1: charging, 90%, charging at zero rate - will never fully charge.
 -+- acpi - et pourtant, ca monte -+-

_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xen.org/xen-devel