bug-gnu-utils
[Top][All Lists]
Advanced

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

Re: #define proc in awk.h causes problems


From: Stepan Kasal
Subject: Re: #define proc in awk.h causes problems
Date: Thu, 12 Dec 2002 09:19:53 +0100
User-agent: Mutt/1.2.5.1i

Hello Dan,

On Wed, Dec 11, 2002 at 10:23:44PM -0500, address@hidden wrote:
> The '#define proc .....' line in awk causes problem when io.c pulls in
> sys/socket.h since sys/socket.h has a 'struct proc *foo;' in it on some
> systems.  Changing that #define to gawk_proc or some such thing should
> fix it.

OK, a patch doing exactly this is attached to this mail, maybe someone
searching the mail list archive may find it useful.
(It patches directly awkgram.c, so bison is not needed.)

> Also, I noticed that some systems only have partial wide char support and
> thus an autoconf test for the existance of type wctype_t as an additional
> requirement along with HAVE_WCHAR_H before enabling wide char support
> would make the build more portable.

The source has the following:

#if defined(HAVE_MBRLEN) && defined(HAVE_MBRTOWC) &&
    defined(HAVE_WCHAR_H) && defined(HAVE_WCTYPE_H)

So your system has mbrlen(), mbrtowc(), wchar.h and wctype.h but you don't
have wctype_t even if you include wctype.h?
This sounds strange.  How does wctype.h look like?

Please mail us the details about this configuration.

> Finally, could the link ${exec_prefix}/bin/awk be made something you can
> turn off with a configure flag?  I usually don't want to install gawk as
> 'awk', but rather i want to keep my 'awk' and have 'gawk' as a separate
> thing.

There was a heuristics whether the link is required.  It only checked the
destination directory for a file named awk.

I've changed the check to call "which awk" and "awk --version".  If awk
executable is found and the version info doesn't start with the word GNU, 
the sylink is not created.

The patch is attached. (Again, it patches Makefile.in directly, so you
don't have to search for the right version of automake.)

> Gawk rules!

Sure.

Have a nice day,
        Stepan

Attachment: gawk-3.1.1-gawk_proc.patch
Description: Text document

Attachment: gawk-3.1.1-ln_awk.patch
Description: Text document


reply via email to

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