0004-Fix-gdbserver-build-on-uClibc-noMMU.patch 1016 B

1234567891011121314151617181920212223242526272829303132
  1. From 430ab62f356d9e45e2231b0483ee33eaf3af5df3 Mon Sep 17 00:00:00 2001
  2. From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
  3. Date: Fri, 9 Jun 2017 10:19:32 +0200
  4. Subject: [PATCH] Fix gdbserver build on uClibc/noMMU
  5. The noMMU specific code requires including <sched.h>.
  6. Originally from
  7. https://cgit.openadk.org/cgi/cgit/openadk.git/plain/package/gdbserver/patches/nommu.patch.
  8. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
  9. ---
  10. gdb/nat/linux-ptrace.h | 3 ++-
  11. 1 file changed, 2 insertions(+), 1 deletion(-)
  12. diff --git a/gdb/nat/linux-ptrace.h b/gdb/nat/linux-ptrace.h
  13. index 5954945..80bb674 100644
  14. --- a/gdb/nat/linux-ptrace.h
  15. +++ b/gdb/nat/linux-ptrace.h
  16. @@ -23,7 +23,8 @@ struct buffer;
  17. #include "nat/gdb_ptrace.h"
  18. #ifdef __UCLIBC__
  19. -#if !(defined(__UCLIBC_HAS_MMU__) || defined(__ARCH_HAS_MMU__))
  20. +#include <sched.h>
  21. +#if !(defined(__UCLIBC_HAS_MMU__) || defined(__ARCH_USE_MMU__))
  22. /* PTRACE_TEXT_ADDR and friends. */
  23. #include <asm/ptrace.h>
  24. #define HAS_NOMMU
  25. --
  26. 2.7.4