summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorEric Andersen <andersen@codepoet.org>2005-10-04 22:26:07 +0000
committerEric Andersen <andersen@codepoet.org>2005-10-04 22:26:07 +0000
commit977216264f4ef4c2ebeb9d30435c17a950fed6e6 (patch)
treeb43b4b36da948adf32ace8f819e5d8e23085947f /include
parentda595aca3aef049535b12fdcec0e77c787286779 (diff)
downloaduClibc-alpine-977216264f4ef4c2ebeb9d30435c17a950fed6e6.tar.bz2
uClibc-alpine-977216264f4ef4c2ebeb9d30435c17a950fed6e6.tar.xz
Do not stub out functions for mmu-less systems. Hide all
prototypes for functions disabled on mmu-less systems.
Diffstat (limited to 'include')
-rw-r--r--include/sys/mman.h2
-rw-r--r--include/unistd.h4
2 files changed, 6 insertions, 0 deletions
diff --git a/include/sys/mman.h b/include/sys/mman.h
index c0dd39e32..a0ac6f981 100644
--- a/include/sys/mman.h
+++ b/include/sys/mman.h
@@ -96,6 +96,7 @@ extern int madvise (void *__addr, size_t __len, int __advice) __THROW;
extern int posix_madvise (void *__addr, size_t __len, int __advice) __THROW;
#endif
+#if defined __ARCH_HAS_MMU__
/* Guarantee all whole pages mapped by the range [ADDR,ADDR+LEN) to
be memory resident. */
extern int mlock (__const void *__addr, size_t __len) __THROW;
@@ -111,6 +112,7 @@ extern int mlockall (int __flags) __THROW;
/* All currently mapped pages of the process' address space become
unlocked. */
extern int munlockall (void) __THROW;
+#endif
#ifdef __USE_MISC
/* Remap pages mapped by the range [ADDR,ADDR+OLD_LEN) to new length
diff --git a/include/unistd.h b/include/unistd.h
index ab8e4b31a..6ee8732dd 100644
--- a/include/unistd.h
+++ b/include/unistd.h
@@ -632,10 +632,12 @@ extern int setresgid (__gid_t __egid, __gid_t __rgid, __gid_t __sgid);
#endif
+#ifdef __ARCH_HAS_MMU__
/* Clone the calling process, creating an exact copy.
Return -1 for errors, 0 to the new process,
and the process ID of the new process to the old process. */
extern __pid_t fork (void) __THROW;
+#endif
#if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
/* Clone the calling process, but without copying the whole address space.
@@ -752,10 +754,12 @@ extern void endusershell (void) __THROW; /* Discard cached info. */
extern void setusershell (void) __THROW; /* Rewind and re-read the file. */
+#if defined __ARCH_HAS_MMU__
/* Put the program in the background, and dissociate from the controlling
terminal. If NOCHDIR is zero, do `chdir ("/")'. If NOCLOSE is zero,
redirects stdin, stdout, and stderr to /dev/null. */
extern int daemon (int __nochdir, int __noclose) __THROW;
+#endif
#endif /* Use BSD || X/Open. */