Update.
authorUlrich Drepper <drepper@redhat.com>
Wed, 15 Jan 2003 07:15:24 +0000 (07:15 +0000)
committerUlrich Drepper <drepper@redhat.com>
Wed, 15 Jan 2003 07:15:24 +0000 (07:15 +0000)
2003-01-14  Ulrich Drepper  <drepper@redhat.com>

* manual/install.texi: Correct description of header preparation for
Linux build.  Patch by mhwood@Ameritech.Net [PR libc/4941].

ChangeLog
manual/install.texi
nptl/Banner
nptl/ChangeLog
nptl/sem_open.c

index c016035..7dd6e43 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2003-01-14  Ulrich Drepper  <drepper@redhat.com>
+
+       * manual/install.texi: Correct description of header preparation for
+       Linux build.  Patch by mhwood@Ameritech.Net [PR libc/4941].
+
 2003-01-14  Guido Guenther  <agx@sigxcpu.org>
 
        * sysdeps/unix/sysv/linux/mips/sysdep.h (INTERNAL_SYSCALL,
index 1c366d5..0e60128 100644 (file)
@@ -504,12 +504,24 @@ include/linux/version.h}.  Finally, configure glibc with the option
 kernel you can get your hands on.
 
 An alternate tactic is to unpack the 2.2 kernel and run @samp{make
-config} as above; then, rename or delete @file{/usr/include}, create
-a new @file{/usr/include}, and make the usual symbolic links of
-@file{/usr/include/linux} and @file{/usr/include/asm} into the 2.2
-kernel sources.  You can then configure glibc with no special options.
-This tactic is recommended if you are upgrading from libc5, since you
-need to get rid of the old header files anyway.
+config} as above; then, rename or delete @file{/usr/include}, create a
+new @file{/usr/include}, and make symbolic links of
+@file{/usr/include/linux} and @file{/usr/include/asm} into the kernel
+sources.  You can then configure glibc with no special options.  This
+tactic is recommended if you are upgrading from libc5, since you need to
+get rid of the old header files anyway.
+
+After installing GNU libc, you may need to remove or rename
+@file{/usr/include/linux} and @file{/usr/include/asm}, and replace them
+with copies of @file{include/linux} and
+@file{include/asm-$@var{ARCHITECTURE}} taken from the Linux source
+package which supplied kernel headers for building the library.
+@var{ARCHITECTURE} will be the machine architecture for which the
+library was built, such as @samp{i386} or @samp{alpha}.  You do not need
+to do this if you did not specify an alternate kernel header source
+using @samp{--with-headers}.  The intent here is that these directories
+should be copies of, @strong{not} symlinks to, the kernel headers used to
+build the library.
 
 Note that @file{/usr/include/net} and @file{/usr/include/scsi} should
 @strong{not} be symlinks into the kernel sources.  GNU libc provides its
index aaca240..9a3a874 100644 (file)
@@ -1 +1 @@
-NPTL 0.16 by Ulrich Drepper
+NPTL 0.17 by Ulrich Drepper
index 0d7a57b..4d1f8cc 100644 (file)
@@ -1,5 +1,9 @@
 2003-01-14  Ulrich Drepper  <drepper@redhat.com>
 
+       * sem_open.c (sem_open): Return SEM_FAILED if existing semaphore
+       must be used and mapping failed.
+       Reported by Luke Elliott <luke.elliott@activfinancial.com>.
+
        * Makefile (CFLAGS-pthread_self.os): Define this, not
        CFLAGS-pthread_self.c.
 
index e8ef8f5..0ed8001 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 2002 Free Software Foundation, Inc.
+/* Copyright (C) 2002, 2003 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@redhat.com>, 2002.
 
@@ -169,6 +169,8 @@ sem_open (const char *name, int oflag, ...)
       /* Map the sem_t structure from the file.  */
       result = (sem_t *) mmap (NULL, sizeof (sem_t), PROT_READ | PROT_WRITE,
                               MAP_SHARED, fd, 0);
+      if (MAP_FAILED != (void *) SEM_FAILED && result == MAP_FAILED)
+       result = SEM_FAILED;
     }
   else
     {