[PATCH] Remove support for systems lacking vfork

Mark Salter msalter at redhat.com
Fri May 4 12:18:46 UTC 2012


Signed-off-by: Mark Salter <msalter at redhat.com>
---
 libc/stdio/popen.c         |    9 ---------
 libc/stdlib/system.c       |    5 -----
 libc/stdlib/unix_grantpt.c |    6 ------
 3 files changed, 0 insertions(+), 20 deletions(-)

diff --git a/libc/stdio/popen.c b/libc/stdio/popen.c
index d5c60cf..dfbfd96 100644
--- a/libc/stdio/popen.c
+++ b/libc/stdio/popen.c
@@ -26,15 +26,6 @@
 #warning "hmm... susv3 says Pipe streams are byte-oriented."
 #endif /* __UCLIBC_MJN3_ONLY__ */
 
-
-/* uClinux-2.0 has vfork, but Linux 2.0 doesn't */
-#include <sys/syscall.h>
-#if ! defined __NR_vfork
-# define vfork fork
-# define VFORK_LOCK		((void) 0)
-# define VFORK_UNLOCK		((void) 0)
-#endif
-
 #ifndef VFORK_LOCK
 __UCLIBC_MUTEX_STATIC(mylock, PTHREAD_MUTEX_INITIALIZER);
 # define VFORK_LOCK		__UCLIBC_MUTEX_LOCK(mylock)
diff --git a/libc/stdlib/system.c b/libc/stdlib/system.c
index a92c307..ec25ead 100644
--- a/libc/stdlib/system.c
+++ b/libc/stdlib/system.c
@@ -24,11 +24,6 @@ extern __typeof(system) __libc_system;
  * need to figure out why still
  */
 #if !defined __UCLIBC_HAS_THREADS_NATIVE__ || defined __sparc__
-/* uClinux-2.0 has vfork, but Linux 2.0 doesn't */
-#include <sys/syscall.h>
-#ifndef __NR_vfork
-# define vfork fork
-#endif
 
 int __libc_system(const char *command)
 {
diff --git a/libc/stdlib/unix_grantpt.c b/libc/stdlib/unix_grantpt.c
index 1be0a7d..527b8c9 100644
--- a/libc/stdlib/unix_grantpt.c
+++ b/libc/stdlib/unix_grantpt.c
@@ -31,12 +31,6 @@
 #include "pty-private.h"
 
 
-/* uClinux-2.0 has vfork, but Linux 2.0 doesn't */
-#include <sys/syscall.h>
-#if ! defined __NR_vfork
-#define vfork fork
-#endif
-
 /* Return the result of ptsname_r in the buffer pointed to by PTS,
    which should be of length BUF_LEN.  If it is too long to fit in
    this buffer, a sufficiently long buffer is allocated using malloc,
-- 
1.7.9.1



More information about the uClibc mailing list