2003-02-12 Ulrich Drepper <drepper@redhat.com>
+ * sysdeps/generic/bits/confname.h: Define _CS_GNU_LIBC_VERSION and
+ _CS_GNU_LIBPTHREAD_VERSION.
+ * posix/conststr.c: Handle these new values.
+ * posix/getconf.c: Likewise.
+
* sysdeps/mips/dl-machine.h (ELF_MACHINE_RUNTIME_TRAMPOLINE): Fix
masking of version index.
Patch by Lance Larsh <Lance.Larsh@oracle.com>.
2003-02-08 Jim Meyering <jim@meyering.net>
- * ftw.c (ftw_startup): When using FTW_CHDIR, always remember
+ * io/ftw.c (ftw_startup): When using FTW_CHDIR, always remember
the current directory, not just when DIR contains a slash.
Reported by Manoj Srivastava.
# define _CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS _CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS
# endif
- _CS_V6_WIDTH_RESTRICTED_ENVS
+ _CS_V6_WIDTH_RESTRICTED_ENVS,
# define _CS_V6_WIDTH_RESTRICTED_ENVS _CS_V6_WIDTH_RESTRICTED_ENVS
+
+ _CS_GNU_LIBC_VERSION,
+#define _CS_GNU_LIBC_VERSION _CS_GNU_LIBC_VERSION
+ _CS_GNU_LIBPTHREAD_VERSION
+#define _CS_GNU_LIBPTHREAD_VERSION _CS_GNU_LIBPTHREAD_VERSION
};
#endif
+2003-02-12 Ulrich Drepper <drepper@redhat.com>
+
+ * sysdeps/pthread/Makefile: Define CFLAGS-confstr.c.
+
2003-02-10 Jakub Jelinek <jakub@redhat.com>
* sysdeps/unix/sysv/linux/alpha/vfork.S (__vfork): Check
$(objpfx)tst-timer: $(objpfx)librt.a $(static-thread-library)
endif
endif
+
+ifeq ($(subdir),posix)
+CFLAGS-confstr.c += -DLIBPTHREAD_VERSION="\"$(shell sed 's/\(.*\) by .*/\1/' ../nptl/Banner)\""
+endif
+2003-02-12 Ulrich Drepper <drepper@redhat.com>
+
+ * sysdeps/pthread/Makefile: Define CFLAGS-confstr.c.
+
2003-02-10 Ulrich Drepper <drepper@redhat.com>
* Makefile (tests): Add tst-cancel8.
-# 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.
$(objpfx)tst-timer: $(objpfx)librt.a $(static-thread-library)
endif
endif
+
+ifeq ($(subdir),posix)
+CFLAGS-confstr.c += -DLIBPTHREAD_VERSION="\"$(shell sed 's/\(.*\) by .*/\1/' ../nptl/Banner)\""
+endif
-/* Copyright (C) 1991,96,97,2000,01,02 Free Software Foundation, Inc.
+/* Copyright (C) 1991,96,97,2000-2002, 2003 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
#include <unistd.h>
#include <string.h>
#include <confstr.h>
+#include "../version.h"
/* If BUF is not NULL and LEN > 0, fill in at most LEN - 1 bytes
of BUF with the value corresponding to NAME and zero-terminate BUF.
string_len = 1;
break;
+ case _CS_GNU_LIBC_VERSION:
+ string = "glibc " VERSION;
+ string_len = strlen (string);
+
+ case _CS_GNU_LIBPTHREAD_VERSION:
+#ifdef LIBPTHREAD_VERSION
+ string = LIBPTHREAD_VERSION;
+ string_len = strlen (string);
+ break;
+#else
+ /* No thread library. */
+ __set_errno (EINVAL);
+ return 0;
+#endif
+
default:
__set_errno (EINVAL);
return 0;
#ifdef _PC_SYMLINK_MAX
{ "SYMLINK_MAX", _PC_SYMLINK_MAX, PATHCONF },
#endif
+#ifdef _CS_GNU_LIBC_VERSION
+ { "GNU_LIBC_VERSION", _CS_GNU_LIBC_VERSION, CONFSTR },
+#endif
+#ifdef _CS_GNU_LIBPTHREAD_VERSION
+ { "GNU_LIBPTHREAD_VERSION", _CS_GNU_LIBPTHREAD_VERSION, CONFSTR },
+#endif
{ NULL, 0, SYSCONF }
};
# define _CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS _CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS
# endif
- _CS_V6_WIDTH_RESTRICTED_ENVS
+ _CS_V6_WIDTH_RESTRICTED_ENVS,
# define _CS_V6_WIDTH_RESTRICTED_ENVS _CS_V6_WIDTH_RESTRICTED_ENVS
+
+ _CS_GNU_LIBC_VERSION,
+#define _CS_GNU_LIBC_VERSION _CS_GNU_LIBC_VERSION
+ _CS_GNU_LIBPTHREAD_VERSION
+#define _CS_GNU_LIBPTHREAD_VERSION _CS_GNU_LIBPTHREAD_VERSION
};
#endif