Mail Archives: djgpp-workers/2001/12/24/14:32:50
I'm trying to compile libc using gcc 3.03 and get:
e:/djgpp/bin/make.exe -C ansi/stdio
gcc ... -c doprnt.c
cc1.exe: warnings being treated as errors
doprnt.c: In function `_doprnt':
doprnt.c:303: warning: signed and unsigned type in conditional expression
doprnt.c:347: warning: signed and unsigned type in conditional expression
doprnt.c:354: warning: signed and unsigned type in conditional expression
make.exe[3]: *** [doprnt.o] Error 1
make.exe[2]: *** [all_subs] Error 2
make.exe[1]: *** [all] Error 2
make.exe: *** [subs] Error 2
Macro ARG:
#define ARG(basetype) _ulonglong = \
flags&LONGDBL ? va_arg(argp, long long basetype) : \
flags&LONGINT ? va_arg(argp, long basetype) : \
flags&SHORTINT ? (short basetype)va_arg(argp, int) : \
va_arg(argp, int)
Lines around 303:
case 'O':
flags |= LONGINT;
/*FALLTHROUGH*/
case 'o':
ARG(unsigned); /* This is line 303. */
base = 8;
goto nosign;
case 'p':
Lines around 347 and 354:
case 'U':
flags |= LONGINT;
/*FALLTHROUGH*/
case 'u':
ARG(unsigned); /* Line 347. */
base = 10;
goto nosign;
case 'X':
digs = "0123456789ABCDEF";
/* FALLTHROUGH */
case 'x':
ARG(unsigned); /* Line 354. */
base = 16;
/* leading 0x/X only if non-zero */
if (flags & ALT && _ulonglong != 0)
flags |= HEXPREFIX;
I'm not sure what I should do to solve this.
Right,
MartinS
- Raw text -