Albert Chin-A-Young
Fri, 14 Dec 2001 05:33:18 -0800
With the HP C compiler, mbstate_t is not defined. With their C++
compiler it is. This has the unfortunate side effect of defining
mbstate_t to 'int' in include/config.h which causes havoc when
building some of the .cc files:
aCC -DHAVE_CONFIG_H -I. -I. -I../include -I../include
-I/opt/TWWfsw/readline42/include +O2 -AA -z +Onofltacc +ESlit
+DAportable +Oentrysched +Odataprefetch
-I/opt/TWWfsw/readline42/include -c -o FileSetOutput.o `test -f
FileSetOutput.cc || echo './'`FileSetOutput.cc
Error 161: "/opt/aCC/include_std/cwchar", line 91 # Bad type specifier
combination; are you missing a ';' at the end of a class/union
definition?
typedef struct {
^^^^^^^^^^^^^^^^
The offending code in /opt/aCC/include_std/cwchar looks like:
# ifndef _MBSTATE_T
# define _MBSTATE_T
typedef struct {
unsigned char __parse_size:3;
unsigned char __dummy:4;
unsigned char __shift_state:1;
char __parse_buf[7];
} mbstate_t;
# endif
which gets cpp'd to:
# ifndef _MBSTATE_T
# define _MBSTATE_T
typedef struct {
unsigned char __parse_size:3;
unsigned char __dummy:4;
unsigned char __shift_state:1;
char __parse_buf[7];
} int;
# endif
So, do we need a C and C++ check for mbstate_t?
Note that mbstate_t is usred in lib/fnmatch.c and lib/regex.c but in
2.4.4, there was no autoconf check for it. Any reason the autoconf
check was introduced?
--
albert chin ([EMAIL PROTECTED])