help-bison
[Top][All Lists]
Advanced

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

Re: compiling 0115 snapshot on windows.


From: Akim Demaille
Subject: Re: compiling 0115 snapshot on windows.
Date: 18 Jan 2001 14:21:02 +0100
User-agent: Gnus/5.0808 (Gnus v5.8.8) XEmacs/21.1 (Crater Lake)

| okay people i just compiled the snapshot on windows with MSVC (yuck :o)
| cygwin configure didn't work out since it said 'install-sh' is missing...

Yep, the distro is not really portable those days, sorry.

| --------------------------------------------------------------------
| diff -r -a -u bisonorg/lib/quote.c bisondiff/lib/quote.c
| --- bisonorg/lib/quote.c      Mon Oct 16 18:28:40 2000
| +++ bisondiff/lib/quote.c     Tue Jan 16 12:36:19 2001
| @@ -5,6 +5,7 @@
|  #endif
|  
|  #include <sys/types.h>
| +#include <stdio.h>
|  #include <quotearg.h>
|  #include <quote.h>
|  
| diff -r -a -u bisonorg/lib/quotearg.c bisondiff/lib/quotearg.c
| --- bisonorg/lib/quotearg.c   Mon Oct 16 18:28:40 2000
| +++ bisondiff/lib/quotearg.c  Tue Jan 16 12:36:08 2001
| @@ -22,6 +22,7 @@
|  #endif
|  
|  #include <sys/types.h>
| +#include <stdio.h>
|  #include <quotearg.h>
|  #include <xalloc.h>
|  

Why those two?  You say:

| The one and only real stuff fixed is that it needed stdio.h in quote.c and
| quotearg.c to know from type_t.

But clearly you meant something else.  size_t I suppose?

| diff -r -a -u bisonorg/lib/xmalloc.c bisondiff/lib/xmalloc.c
| --- bisonorg/lib/xmalloc.c    Mon Oct  2 09:48:32 2000
| +++ bisondiff/lib/xmalloc.c   Tue Jan 16 12:36:55 2001
| @@ -47,11 +47,11 @@
|  #endif
|  
|  #ifndef HAVE_DONE_WORKING_MALLOC_CHECK
| -you must run the autoconf test for a properly working malloc -- see
| malloc.m4
| +#error you must run the autoconf test for a properly working malloc --
| see malloc.m4
|  #endif

Not portable (well, at least we believe it is not), in the sense that
some compiler would choke on

#if 0
# error Impossible!
#endif

so, no.

| /* coward msvc doesn't know this functions...
| #define stpcpy(dst, src) (strcpy(dst, src) + strlen(src))

Yes, many system don't know it, I will provide the fallback once Im
sure I want to use them.  Thanks!

| #define strndup(src, maxsize) (strncpy(calloc(((strlen(src) < maxsize) ?

Likewise.



reply via email to

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