This may actually be a GNU gettext problem, so I might have the wrong
list.  Maybe groff is carrying around a stale Autoconf macro.  Please
advise.

(Also, it's surprise to me that Autoconf thinks a sun4u system is not a
"64-bit host".)

checking for 64-bit host... no
checking for iconv... yes
checking for working iconv... yes
checking how to link with libiconv... -liconv
checking for iconv declaration...
         extern size_t iconv (iconv_t cd, const char * *inbuf, size_t 
*inbytesleft, char * *outbuf, size_t *outbytesleft);
...
GNU roff version 1.23.0.4875-777fdc
----------------------------------------------------------------------
 installation directory prefix    : /export/home/gbranden
 command name prefix              : g
 wrappers used for macro packages : an an.ja an.ja_JP.PCK an.ja_JP.UTF-8 ansun 
ansun.ja ansun.ja_JP.PCK ansun.ja_JP.UTF-8 bib m s v vgrind
 C++ compiler and options         : g++ -std=gnu++11 -g -O2  -D_REENTRANT
 use libgroff's memory allocator  : no
 C compiler and options           : gcc -g -O2  -D_REENTRANT
 Perl interpreter version         : 5.12.5
 X11 support                      : disabled
 default paper format             : letter
 'groff -l' uses print spooler    : no
 use URW fonts for PDF output     : yes
 URW fonts directory              : 
/export/home/gbranden/urw-base35-fonts-20200910/fonts
 preconv can use uchardet library : no
 can build groff.{info,html,txt}  : no
 can build groff.{dvi,pdf}        : no
----------------------------------------------------------------------
...
  CXX      src/preproc/preconv/preconv-preconv.o
src/preproc/preconv/preconv.cpp: In function ‘void conversion_iconv(std::FILE*, 
const string&, char*)’:
src/preproc/preconv/preconv.cpp:705:45: error: invalid static_cast from type 
‘char**’ to type ‘const char**’
      static_cast<ICONV_CONST char **>(&inptr),
                                             ^
src/preproc/preconv/preconv.cpp:740:47: error: invalid static_cast from type 
‘char**’ to type ‘const char**’
        static_cast<ICONV_CONST char **>(&inptr),
                                               ^
gmake[2]: *** [Makefile:11770: src/preproc/preconv/preconv-preconv.o] Error 1
gmake[2]: Leaving directory '/export/home/gbranden/groff-1.23.0.4875-777fdc'
gmake[1]: *** [Makefile:13246: all-recursive] Error 1
gmake[1]: Leaving directory '/export/home/gbranden/groff-1.23.0.4875-777fdc'
gmake: *** [Makefile:7557: all] Error 2

-bash-4.4$ nl src/preproc/preconv/preconv.cpp | sed -n '703,707p;738,742p'
   671    while (inbytes_left > 0) {
   672      size_t status = iconv(handle,
   673                            static_cast<ICONV_CONST char **>(&inptr),
   674                            &inbytes_left, &outptr, &outbytes_left);
   675      if (status == static_cast<size_t>(-1)) {
   706      while (inbytes_left > 0) {
   707        size_t status = iconv(handle,
   708                              static_cast<ICONV_CONST char **>(&inptr),
   709                              &inbytes_left, &outptr, &outbytes_left);
   710        if (status == (size_t)-1) {

$ git grep ICONV_CONST Makefile.am
Makefile.am:# ICONV_CONST=const         if declaration of iconv() needs const
-bash-4.4$ head m4/iconv.m4
# iconv.m4 serial 19 (gettext-0.18.2)
dnl Copyright (C) 2000-2018 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
dnl with or without modifications, as long as this notice is preserved.

dnl From Bruno Haible.

AC_DEFUN([AM_ICONV_LINKFLAGS_BODY],
[

-bash-4.4$ uname -a
SunOS gcc-solaris11 5.11 11.3 sun4u sparc SUNW,SPARC-Enterprise
-bash-4.4$ gcc --version
gcc (GCC) 5.5.0
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Distribution archive: https://paste.c-net.org/RetainedNowadays (8.7MB)

Regards,
Branden

Attachment: signature.asc
Description: PGP signature

Reply via email to