Hi,
I'm compiling gcc-2.95.3 on a tru64 v5.1 box. It compiles okay, but there
are lots of warnings about conflicting definitions for the cuserid value.
As far as I know this is the definition which determines user name length,
and may be changed depending on if you're using C2 or not?
The warnings I'm getting are that:
include/unistd.h:608: warning: `cuserid' redefined
include/stdio.h:457: warning: this is the location of the previous definition
What should be the correct definition for cuserid on a C2 system?
The following files define it as follows:
--------------------------------------------------------------------------------
unistd.h
--------------------------------------------------------------------------------
#ifndef _XOPEN_SOURCE
#if !defined(_LIBC_POLLUTION_H_) && !defined(__V40_OBJ_COMPAT)
#ifdef __DECC
#pragma extern_prefix "_E"
#else
#define cuserid _Ecuserid
#endif /* __DECC */
#endif /* __V40_OBJ_COMPAT && _LIBC_POLLUTION_H_ */
extern char *__V40_OC(cuserid) __((char *));
--------------------------------------------------------------------------------
stdio.h
--------------------------------------------------------------------------------
/stdio.h gives this definition
/*
* Value to determine the maximum number of bytes allowed in a username.
* This support is versioned to allow applications using the previous
* value to continue working without fear of overwriting buffer space.
* The _O_L_cuserid is the value of L_cuserid prior to V5.0 to help
* applications distinguish between the old and new value.
*/
#define _O_L_cuserid 9
#if !defined(__V40_OBJ_COMPAT)
#define L_cuserid 64
#else
#define L_cuserid 9
#endif
Received on Sat May 19 2001 - 15:30:54 NZST