bug-indent
[Top][All Lists]
Advanced

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

build failures of indent 2.2.9 on linux, with patch


From: Guilhem Bichot
Subject: build failures of indent 2.2.9 on linux, with patch
Date: Fri, 6 Oct 2006 14:17:26 +0200
User-agent: Mutt/1.5.9i

Hello,

I tried to build indent 2.2.9 from source (downloaded from some GNU
mirror), on a Kubuntu Linux Dapper Drake, using gcc 4.0.3, on an
Athlon 32-bit; kernel is 2.6.15. m4 is 1.4.4, autoconf 2.59 and
automake 1.9.6.

I observed that "./configure" (the provided "configure") shows:

PAQ 14:09 /m/logiciels/indent-2.2.9 $] ./configure
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether to enable maintainer-specific portions of Makefiles... no
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ANSI C... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking how to run the C preprocessor... gcc -E
checking for a BSD-compatible install... /usr/bin/install -c
checking for egrep... grep -E
checking for AIX... no
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking minix/config.h usability... no
checking minix/config.h presence... no
checking for minix/config.h... no
checking for library containing strerror... none required
checking for an ANSI C-conforming const... yes
checking for dvips... /m/logiciels/indent-2.2.9/config/missing dvips
checking for texi2pdf... /m/logiciels/indent-2.2.9/config/missing texi2pdf
checking for texi2html... /m/logiciels/indent-2.2.9/config/missing texi2html
checking whether NLS is requested... yes
checking for msgfmt... /usr/bin/msgfmt
checking for gmsgfmt... /usr/bin/msgfmt
checking for xgettext... /usr/bin/xgettext
checking for msgmerge... /usr/bin/msgmerge
checking build system type... i686-pc-linux
checking host system type... i686-pc-linux
checking whether we are using the GNU C Library 2 or newer... yes
checking for ranlib... ranlib
checking for signed... yes
checking for inline... inline
checking for off_t... yes
checking for size_t... yes
checking for long long... yes
checking for long double... yes
checking for wchar_t... yes
checking for wint_t... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for intmax_t... yes
checking whether printf() supports POSIX/XSI format strings... yes
checking for working alloca.h... yes
checking for alloca... yes
checking for stdlib.h... (cached) yes
checking for unistd.h... (cached) yes
checking for getpagesize... yes
checking for working mmap... yes
checking whether we are using the GNU C Library 2.1 or newer... yes
checking whether integer division by zero raises SIGFPE... yes
checking for unsigned long long... yes
checking for inttypes.h... yes
checking whether the inttypes.h PRIxNN macros are broken... no
checking for stdint.h... (cached) yes
checking for SIZE_MAX... yes
checking for stdint.h... (cached) yes
checking for CFPreferencesCopyAppValue... no
checking for CFLocaleCopyCurrent... no
checking for ld used by GCC... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for shared library run path origin... done
checking for ptrdiff_t... yes
checking argz.h usability... yes
checking argz.h presence... yes
checking for argz.h... yes
checking limits.h usability... yes
checking limits.h presence... yes
checking for limits.h... yes
checking locale.h usability... yes
checking locale.h presence... yes
checking for locale.h... yes
checking nl_types.h usability... yes
checking nl_types.h presence... yes
checking for nl_types.h... yes
checking malloc.h usability... yes
checking malloc.h presence... yes
checking for malloc.h... yes
checking stddef.h usability... yes
checking stddef.h presence... yes
checking for stddef.h... yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking for unistd.h... (cached) yes
checking sys/param.h usability... yes
checking sys/param.h presence... yes
checking for sys/param.h... yes
checking for asprintf... yes
checking for fwprintf... yes
checking for getcwd... yes
checking for getegid... yes
checking for geteuid... yes
checking for getgid... yes
checking for getuid... yes
checking for mempcpy... yes
checking for munmap... yes
checking for putenv... yes
checking for setenv... yes
checking for setlocale... yes
checking for snprintf... yes
checking for stpcpy... yes
checking for strcasecmp... yes
checking for strdup... yes
checking for strtoul... yes
checking for tsearch... yes
checking for wcslen... yes
checking for __argz_count... yes
checking for __argz_stringify... yes
checking for __argz_next... yes
checking for __fsetlocking... yes
checking whether _snprintf is declared... no
checking whether _snwprintf is declared... no
checking whether feof_unlocked is declared... yes
checking whether fgets_unlocked is declared... no
checking whether getc_unlocked is declared... yes
checking for iconv... yes
checking for iconv declaration...
         extern size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, 
char * *outbuf, size_t *outbytesleft);
checking for nl_langinfo and CODESET... yes
checking for LC_MESSAGES... yes
checking for bison... bison
checking version of bison... 2.1, ok
checking for CFPreferencesCopyAppValue... (cached) no
checking for CFLocaleCopyCurrent... (cached) no
checking whether NLS is requested... yes
checking whether included gettext is requested... no
checking for GNU gettext in libc... yes
checking whether to use NLS... yes
checking where the gettext function comes from... libc
checking for ANSI C header files... (cached) yes
checking for strchr... yes
checking for memcpy... yes
checking for memmove... yes
checking for utime... yes
checking for unistd.h... (cached) yes
checking for string.h... (cached) yes
checking for malloc.h... (cached) yes
checking utime.h usability... yes
checking utime.h presence... yes
checking for utime.h... yes
checking sys/utime.h usability... no
checking sys/utime.h presence... no
checking for sys/utime.h... no
./configure: line 10992: indent_UTIMBUF: command not found
checking for dirent.h that defines DIR... yes
checking for library containing opendir... none required
configure: creating ./config.status
config.status: creating m4/Makefile
config.status: creating Makefile
config.status: creating src/Makefile
config.status: creating doc/Makefile
config.status: creating man/Makefile
config.status: creating po/Makefile.in
config.status: creating intl/Makefile
config.status: creating config.h
config.status: config.h is unchanged
config.status: executing depfiles commands
config.status: executing default-1 commands
config.status: creating po/POTFILES
config.status: creating po/Makefile
config.status: executing default commands
[PAQ 14:10 /m/logiciels/indent-2.2.9 $]        

See the message about indent_UTIMBUF above.
I patched configure.ac like this:
***************
*** 7,12 ****
--- 7,15 ----

  AM_MAINTAINER_MODE

+ dnl Include m4
+ sinclude(aclocal/UTIMBUF.m4)
+
  dnl Checks for programs.
  AC_PROG_CC
  AC_PROG_CPP

Then
aclocal: autoheader; autoconf; automake;
./configure

I did get a few warnings:
aclocal/UTIMBUF.m4:6: warning: underquoted definition of indent_UTIMBUF
  run info '(automake)Extending aclocal'
  or see http://sources.redhat.com/automake/automake.html#Extending-aclocal
Makefile.am:43: CFLAGS was already defined in condition TRUE, which includes 
condition MAINTAINER_MODE ...
configure.ac:14: ... `CFLAGS' previously defined here
Makefile.am:45: CFLAGS was already defined in condition TRUE, which includes 
condition !MAINTAINER_MODE ...
Makefile.am:43: ... `CFLAGS' previously defined here

but didn't consider them as critical, then I went to "make" and:

[PAQ 14:12 /m/logiciels/indent-2.2.9 $] make
 cd . && /bin/sh ./config.status Makefile
config.status: creating Makefile
make  all-recursive
make[1]: Entering directory `/home/mysql_src/logiciels/indent-2.2.9'
Making all in intl
make[2]: Entering directory `/home/mysql_src/logiciels/indent-2.2.9/intl'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/mysql_src/logiciels/indent-2.2.9/intl'
Making all in m4
make[2]: Entering directory `/home/mysql_src/logiciels/indent-2.2.9/m4'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/mysql_src/logiciels/indent-2.2.9/m4'
Making all in src
make[2]: Entering directory `/home/mysql_src/logiciels/indent-2.2.9/src'
make  all-am
make[3]: Entering directory `/home/mysql_src/logiciels/indent-2.2.9/src'
if gcc -DHAVE_CONFIG_H -DLOCALEDIR=\"/usr/local/share/locale\" -I. -I. -I.. -I. 
-I. -I../intl    -g -O2 -MT output.o -MD -MP -MF ".deps/output.Tpo" -c -o 
output.o output.c; \
        then mv -f ".deps/output.Tpo" ".deps/output.Po"; else rm -f 
".deps/output.Tpo"; exit 1; fi
output.c:26: error: static declaration of ‘output’ follows non-static 
declaration
indent.h:100: error: previous declaration of ‘output’ was here
output.c: In function ‘open_output’:
output.c:1149: warning: incompatible implicit declaration of built-in function 
‘exit’
make[3]: *** [output.o] Error 1
make[3]: Leaving directory `/home/mysql_src/logiciels/indent-2.2.9/src'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/home/mysql_src/logiciels/indent-2.2.9/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/mysql_src/logiciels/indent-2.2.9'
make: *** [all] Error 2

so I patched src/output.c like this:
***************
*** 23,29 ****

  RCSTAG_CC ("$Id: output.c,v 1.5 2002/12/12 17:36:49 david Exp $");

! static FILE            * output       = NULL;
  static BOOLEAN           inhibited    = 0;
  static buf_break_st_ty * buf_break_list = NULL;

--- 23,29 ----

  RCSTAG_CC ("$Id: output.c,v 1.5 2002/12/12 17:36:49 david Exp $");

! FILE            * output       = NULL;
  static BOOLEAN           inhibited    = 0;
  static buf_break_st_ty * buf_break_list = NULL;


and then it built ok.
Please, would it be possible to include those fixes into the next
source release, if you consider them correct?

Thank you in any case for providing indent!!!

-- 
   __  ___     ___ ____  __
  /  |/  /_ __/ __/ __ \/ /    Mr. Guilhem Bichot <address@hidden>
 / /|_/ / // /\ \/ /_/ / /__   MySQL AB, Full-Time Software Developer
/_/  /_/\_, /___/\___\_\___/   Bordeaux, France
       <___/   www.mysql.com   




reply via email to

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