bug-groff
[Top][All Lists]
Advanced

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

groff 1.17.2 build problems on SCO OpenServer 5.0.6a


From: Roger Cornelius
Subject: groff 1.17.2 build problems on SCO OpenServer 5.0.6a
Date: Wed, 27 Feb 2002 22:07:30 GMT

Building groff 1.17.2 on SCO Openserver 5.0.6a using the native
compiler, configure fails to correctly determine whether some auxiliary
functions (hypot(), popen(), pclose(), putenv(), strncasecmp()) need
declarations.  Compilation of the test program generated by configure
for each of these functions fails with a "syntax error" at the same
line.  E.g.:

char *(*pfn) = (char *(*)) strncasecmp

Here's a brief section from config.log:

configure:3124: checking whether strncasecmp must be declared
configure:3164: CC -c -g  conftest.cc >&5
"configure", line 3157: error: syntax error
1 error
configure:3167: $? = 1
configure: failed program was:
#line 3136 "configure"
#include "confdefs.h"

#include <stdio.h>
#ifdef HAVE_STRING_H
#include <string.h>
#endif
#ifdef HAVE_STRINGS_H
#include <strings.h>
#endif
#ifdef HAVE_STDLIB_H
#include <stdlib.h>
#endif
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#ifdef HAVE_MATH_H
#include <math.h>
#endif
int
main ()
{
char *(*pfn) = (char *(*)) strncasecmp
  ;
  return 0;
}
configure:3184: result: yes

Because the compilation fails, configure incorrectly adds
-DNEED_DECLARATION_<function> to CFLAGS in the Makefile it generates. 
In the case of strncasecmp(), the make phase then ultimately fails on
font.cc with a "two strncasecmp()s with c linkage" error.  If, after
running configure, I manually edit Makefile and remove the
NEED_DECLARATION_* defines, the make phase makes it as far as groff.cc
where it fails with these errors:

"groff.cc", line 424: warning: address of  string constant
"groff.cc", line 342: error: undefined symbol: __0__Q7

Using gcc 3.0.4, configure/make complete successfully and configure
correctly determines declarations are not needed for above functions.
-- 
Roger Cornelius        address@hidden



reply via email to

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