Derek Price [EMAIL PROTECTED] writes:
It may be. It looks like the change was intentional
(http://sources.redhat.com/cgi-bin/cvsweb.cgi/libc/sysdeps/generic/glob.c?rev=1.52content-type=text/x-cvsweb-markupcvsroot=glibc),
but I still disagree.
I agree with you. Historically, the * pattern in
Paul Eggert wrote:
Derek Price [EMAIL PROTECTED] writes:
1. Corrects an incorrect check for a successful return from
getlogin_r to assume only 0 means success, per the POSIX2 spec:
http://www.opengroup.org/onlinepubs/009695399/functions/getlogin_r.html.
2. Moves the check
Derek Price [EMAIL PROTECTED] writes:
After that I will write up a ChangeLog entry for the glob-glibc2gnulib
diff and submit our changes back to the glibc team, unless someone here
who is used to working with them would like to take a go at the actual
submission part. Perhaps it would be
Derek Price [EMAIL PROTECTED] writes:
I chose the _SYS_CDEFS_H route since it seemed simplest to me, though I
chose to name the macro `MISSING_SYS_CDEFS_H'.
Sorry, that's not right, since it fails in the following scenario:
#define MISSING_SYS_CDEFS_H 27
#include glob.h
in an ordinary
Paul Eggert wrote:
Derek Price [EMAIL PROTECTED] writes:
I chose the _SYS_CDEFS_H route since it seemed simplest to me, though I
chose to name the macro `MISSING_SYS_CDEFS_H'.
Sorry, that's not right, since it fails in the following scenario:
#define MISSING_SYS_CDEFS_H 27
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Paul Eggert wrote:
--- extensions.m4.~1.6.~ 2005-02-23 05:49:36 -0800
+++ extensions.m4 2005-05-24 12:35:48 -0700
@@ -21,6 +21,10 @@ AC_DEFUN([gl_USE_SYSTEM_EXTENSIONS], [
[/* Enable extensions on Solaris. */
#ifndef __EXTENSIONS__
# undef
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Paul Eggert wrote:
Derek Price [EMAIL PROTECTED] writes:
+# ifdef HAVE___POSIX_GETPWNAM_R
+ /* Solaris. */
+# define getpwnam_r(name, bufp, buf, len, res) \
+ __posix_getpwnam_r (name, bufp, buf, len, res)
+# endif
I don't see why this is needed.
Derek Price writes:
Larry, can you tell us if defining
_POSIX_PTHREAD_SEMANTICS would work to get the POSIX version of
getpwnam_r on Solaris?
It looks like it.
-Larry Jones
I never get to do anything fun. -- Calvin
___
Bug-cvs mailing list
Larry Jones wrote:
Derek Price writes:
Larry, can you tell us if defining
_POSIX_PTHREAD_SEMANTICS would work to get the POSIX version of
getpwnam_r on Solaris?
It looks like it.
I've committed Paul's patch to the CVS CVS tree, as well as removing the
associated glob.c changes,
Derek Price [EMAIL PROTECTED] writes:
+#else
+/* Is there really a case where the getlogin or getlogin_r proto can come
from
+ somewhere other than unistd.h? */
+# ifdef HAVE_GETLOGIN_R
+extern int getlogin_r (char *, size_t);
+# else
+extern char *getlogin (void);
+# endif
+#endif
Derek Price [EMAIL PROTECTED] writes:
all the HAVE_.*64 stuff in glob.c shouldn't be necessary when !_LIBC.
Yes, that's correct; it should just invoke stat, opendir, etc., without
worrying about their 64-bit variants. I thought it already did that?
If not, where does it not do it?
Also, this
Paul Eggert wrote:
There is one change I know I made that might have an effect. I added
the !defined _LIBC to the following block because I was unsure what
__REDIRECT_NTH was supposed to be doing
I think that one's OK.
Larry Jones on the CVS team just made a comment that makes me
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Paul Eggert wrote:
Answering my own question: yes it will, in general, because perhaps
the gnulib version fixes a bug that's in the glibc version, and the
user wants the gnulib version. So we should worry about this.
And (as far as I can see) the
Derek Price [EMAIL PROTECTED] writes:
Why do we need to include sys/types.h here? All we need is size_t,
right? And stddef.h gives us that.
If I don't, I get the following error:
In file included from glob.c:23:
glob.h:107: error: syntax error before struct
In file included from
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Thanks for the latest round. I'm going to be out of the office today,
but I should get to it by tomorrow.
Regards,
Derek
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.0 (Cygwin)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
Paul Eggert wrote:
Derek Price [EMAIL PROTECTED] writes:
/* Enable GNU extensions in glob.h. */
-#ifndef _GNU_SOURCE
+#if defined _LIBC !defined _GNU_SOURCE
# define _GNU_SOURCE 1
#endif
I just checked the glibc source file include/libc-symbols.h, and it
defines both _LIBC and
Derek Price [EMAIL PROTECTED] writes:
This seems a bit brittle. Why not simply try to compile this program?
#include glob.h
char a[_GNU_GLOB_INTERFACE_VERSION == 1 ? 1 : -1];
Because I like to avoid runtime tests if I can avoid it, since they
cannot be used when cross-compiling.
The
Paul Eggert wrote:
Now for commentary on glob.h.
Derek Price [EMAIL PROTECTED] writes:
--- ../glibc-2.3.5/posix/glob.h 2004-09-16 20:55:15.0 -0400
+++ lib/glob_.h 2005-05-13 12:21:39.0 -0400
@@ -19,29 +19,48 @@
#ifndef _GLOB_H
#define _GLOB_H 1
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Paul Eggert wrote:
Derek Price [EMAIL PROTECTED] writes:
Are you sure? You asked me to restore similar parens around bit-ands
back at several other locations despite other work that changed the
lines, in an earlier email. Not that I disagree now. I
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Paul Eggert wrote:
First, already we have something bogus: that __BEGIN_DECLS. It must
be protected by #ifdef _LIBC, since random C environments don't have
it. Similarly for __END_DECLS.
Done.
The simplest fix would be to do something like this:
Derek Price [EMAIL PROTECTED] writes:
Are you sure? You asked me to restore similar parens around bit-ands
back at several other locations despite other work that changed the
lines, in an earlier email. Not that I disagree now. I actually prefer
the version without the unnecessary parens
One other remark about glob.c. You should remove this comment, as
it's obsolete now:
/* Comment out all this code if we are using the GNU C Library, and are not
actually compiling the library itself. This code is part of the GNU C
Library, but also included in many other GNU
Derek Price [EMAIL PROTECTED] writes:
/* Enable GNU extensions in glob.h. */
-#ifndef _GNU_SOURCE
+#if defined _LIBC !defined _GNU_SOURCE
# define _GNU_SOURCE 1
#endif
I just checked the glibc source file include/libc-symbols.h, and it
defines both _LIBC and _GNU_SOURCE. So this stuff
Now for commentary on glob.h.
Derek Price [EMAIL PROTECTED] writes:
--- ../glibc-2.3.5/posix/glob.h 2004-09-16 20:55:15.0 -0400
+++ lib/glob_.h 2005-05-13 12:21:39.0 -0400
@@ -19,29 +19,48 @@
#ifndef _GLOB_H
#define _GLOB_H 1
-#include sys/cdefs.h
Derek Price [EMAIL PROTECTED] writes:
First, what is __ptr_t? Shouldn't it be replaced by void *
uniformly?
This is one of the items I didn't touch since it didn't raise any
compiler warnings here. It looks like it is mostly being used as a void
*, though I'm not sure why since there are a
Derek Price [EMAIL PROTECTED] writes:
We've been removing those sort of constructs from CVS as part of the
move away from KR support. IIRC, I was told that typecasts to and from
(void *) were necessary on some really old systems, but that I could be
confident that we wouldn't encounter any
Subject: [bug-gnulib] New GNULIB glob module?
Would it be possible to simply use the libc code as-is? I guess I mean,
with whatever changes are needed sent back to libc.
So much stuff in gnulib is 95% the same as libc. It doesn't seem good.
k
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Karl Berry wrote:
Subject: [bug-gnulib] New GNULIB glob module?
Would it be possible to simply use the libc code as-is? I guess I mean,
with whatever changes are needed sent back to libc.
So much stuff in gnulib is 95% the same as libc. It doesn't
Derek Price [EMAIL PROTECTED] writes:
I needed a portable version of glob for CVS, so I imported the glob
module from glibc 2.3.5 into a GNULIB format.
Wow! Nice project.
Mostly I kept the glibc version intact, though I managed to simplify
some portability cruft immensely by replacing huge
Most of this looks good, but one quick question as I get to this: I
assume from the following that I can expect _LIBC to be defined iff the
file is being compiled as part of glibc? I wasn't sure...
Cheers,
Derek
Paul Eggert wrote:
-#ifdef _LIBC
-# include alloca.h
-# undef strdup
-# define
30 matches
Mail list logo