OSDN Git Service

Fix daemon build for no-MMU no-threads.
authorJoseph Myers <joseph@codesourcery.com>
Tue, 4 Aug 2009 15:45:53 +0000 (15:45 +0000)
committerJoseph Myers <joseph@codesourcery.com>
Tue, 4 Aug 2009 15:45:53 +0000 (15:45 +0000)
CLONE_VM (used in no-MMU daemon) is defined in <bits/sched.h>.  A
build with threads ends up including <sched.h> via <pthread.h> via
<bits/uClibc_mutex.h>; this indirect include does not happen for a
build without threads, so this patch adds a direct <sched.h> include.

Signed-off-by: Joseph Myers <joseph@codesourcery.com>
libc/unistd/daemon.c

index 7894889..b18d618 100644 (file)
@@ -59,6 +59,7 @@
 
 #ifndef __ARCH_USE_MMU__
 #include <sys/syscall.h>
+#include <sched.h>
 /* use clone() to get fork() like behavior here -- we just want to disassociate
  * from the controlling terminal
  */