bug-groff
[Top][All Lists]
Advanced

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

groff 1.17 lib.h conflict with strerror declaration


From: Bruce Lilly
Subject: groff 1.17 lib.h conflict with strerror declaration
Date: Thu, 19 Apr 2001 22:03:01 -0400

                           Groff Bug Report

Please read the PROBLEMS file before sending in a bug report.

Please fill in all fields, even if you think they are not relevant.

Please delete the text in brackets before sending it in.

Please report separate bugs separately.

Send the completed form to address@hidden

GROFF VERSION:
1.17

MACHINE:
[The machine you are using.  For example, `Sun SPARCstation 2']

OS:
Microsoft Windows 2000 SP1 with UWIN 2.9
(see http://www.research.att.com/sw/tools/uwin/)

COMPILER:
Microsoft VC++ 6.0 SP5 with UWIN front end

INPUT FILES:
none required

COMMAND LINE:
./configure && make

DESCRIPTION OF INCORRECT BEHAVIOUR:
strerror declaration in lib.h conflicts with standard declaration
in the standard header <string.h> (see ANSI/ISO 9899-1990 section
7.11.6.2).  lib.h wrapper uses #ifndef strerror on the assumption
(incorrect) that strerror is always a macro.  lib.h already
#includes <string.h>, so a redeclaration of strerror is unnecessary
except on systems with a broken string.h (in which case the broken
header should be fixed).

make output:

CC -I. -I/y/groff/groff-current/src/libs/libgroff 
-I/y/groff/groff-current/src/include -I/y/groff/groff-current/src/include 
-DHAVE_STDLIB_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DIRENT_H=1 -DHAVE_LIMITS_H=1 
-DHAVE_SYS_DIR_H=1 -DHAVE_STRING_H=1 -DHAVE_STRINGS_H=1 -DHAVE_MATH_H=1 
-DRET_TYPE_SRAND_IS_VOID=1 -DHAVE_SYS_NERR=1 -DHAVE_SYS_ERRLIST=1 
-DHAVE_CC_LIMITS_H=1 -DRETSIGTYPE=void -DHAVE_UNISTD_H=1 -DHAVE_GETPAGESIZE=1 
-DHAVE_FMOD=1 -DHAVE_STRTOL=1 -DHAVE_GETCWD=1 -DHAVE_STRERROR=1 -DHAVE_PUTENV=1 
-DHAVE_RENAME=1 -DHAVE_MKSTEMP=1 -DHAVE_STRCASECMP=1 -DHAVE_STRNCASECMP=1 
-DHAVE_STRDUP=1  -g  -c illegal.cc
/msdev/VC98/include/string.h(132) : error C2375: 'strerror' : redefinition; 
different linkage
        /y/groff/groff-current/src/include/lib.h(23) : see declaration of 
'strerror'
make[2]: *** [illegal.o] Error 1
make[2]: Leaving directory `/Y/groff/groff-current/src/libs/libgroff'
make[1]: Entering directory `/Y/groff/groff-current'
make[1]: *** [src/libs/libgroff] Error 2
make[1]: Leaving directory `/Y/groff/groff-current'
make: *** [all] Error 2

SUGGESTED FIX [optional]:
*** src/include/lib.h.orig      Thu Apr 19 21:40:56 2001
--- src/include/lib.h   Thu Apr 19 21:42:08 2001
***************
*** 19,27 ****
  Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
  
  extern "C" {
- #ifndef strerror
-   char *strerror(int);
- #endif
    const char *i_to_a(int);
    const char *if_to_a(int, int);
  }
--- 19,24 ----



reply via email to

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