[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [bug-gnulib] New GNULIB glob module?

From: Paul Eggert
Subject: Re: [bug-gnulib] New GNULIB glob module?
Date: Sun, 15 May 2005 15:36:18 -0700
User-agent: Gnus/5.1006 (Gnus v5.10.6) Emacs/21.4 (gnu/linux)

Derek Price <address@hidden> 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 code that I proposed does not have any runtime tests, since the
array is allocated statically.  Tests like this are often used during

> it should be pretty safe to grep for "gnu_glob_version = 1", unless you
> are worried about some future CPP padding with spaces before the EOL?

Yes, that sort of thing.  cpp can even insert newlines if it wants to.
It's best to avoid cpp tricks if there is an easy substitute, which
there is here.

> 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.

> Fixed.  It's still listed in srclist.txt as "gpl" however, since the
> other glibc modules were.  Why is that?

That tells the import-from-glibc module to use the GPL in the CVS
repository.  It's fine.

More messages to follow, since I need to look at the code again.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]