Package: libvformat1-dev
Version: 1.13-3
Severity: normal

I tried to use vf_iface.h with autoconf 2.59 like this:

$ touch test.c
$ echo 'AC_INIT(test.c)' > configure.in
$ echo 'AC_CHECK_HEADERS([vf_iface.h])' >> configure.in
$ autoconf
$ ./configure

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 how to run the C preprocessor... gcc -E
checking for egrep... grep -E
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 vf_iface.h usability... no
checking vf_iface.h presence... yes
configure: WARNING: vf_iface.h: present but cannot be compiled
configure: WARNING: vf_iface.h:     check for missing prerequisite headers?
configure: WARNING: vf_iface.h: see the Autoconf documentation
configure: WARNING: vf_iface.h:     section "Present But Cannot Be Compiled"
configure: WARNING: vf_iface.h: proceeding with the preprocessor's result
configure: WARNING: vf_iface.h: in the future, the compiler will take precedence
configure: WARNING:     ## ------------------------------------------ ##
configure: WARNING:     ## Report this to the AC_PACKAGE_NAME lists.  ##
configure: WARNING:     ## ------------------------------------------ ##
checking for vf_iface.h... yes

Looking into config.log gives the following:

configure:2709: checking vf_iface.h usability
configure:2721: gcc -c -g -O2  conftest.c >&5
In file included from conftest.c:53:
/usr/include/vf_iface.h:463: error: conflicting types for `uint32_t'
/usr/include/stdint.h:52: error: previous declaration of `uint32_t'
configure:2727: $? = 1
configure: failed program was:
| /* confdefs.h.  */
| 
| #define PACKAGE_NAME ""
| #define PACKAGE_TARNAME ""
| #define PACKAGE_VERSION ""
| #define PACKAGE_STRING ""
| #define PACKAGE_BUGREPORT ""
| #define STDC_HEADERS 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRING_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_STDINT_H 1
| #define HAVE_UNISTD_H 1
| /* end confdefs.h.  */
| #include <stdio.h>
| #if HAVE_SYS_TYPES_H
| # include <sys/types.h>
| #endif
| #if HAVE_SYS_STAT_H
| # include <sys/stat.h>
| #endif
| #if STDC_HEADERS
| # include <stdlib.h>
| # include <stddef.h>
| #else
| # if HAVE_STDLIB_H
| #  include <stdlib.h>
| # endif
| #endif
| #if HAVE_STRING_H
| # if !STDC_HEADERS && HAVE_MEMORY_H
| #  include <memory.h>
| # endif
| # include <string.h>
| #endif
| #if HAVE_STRINGS_H
| # include <strings.h>
| #endif
| #if HAVE_INTTYPES_H
| # include <inttypes.h>
| #else
| # if HAVE_STDINT_H
| #  include <stdint.h>
| # endif
| #endif
| #if HAVE_UNISTD_H
| # include <unistd.h>
| #endif
| #include <vf_iface.h>
configure:2749: result: no


As you can see, the problem is, that stdint.h is included before
vf_iface.h but both of them have a different typedef for uint32_t.
The one in vf_iface.h is guarded:

#if defined(USE_INTTYPES_H)
#include <inttypes.h>
#else
typedef unsigned char       uint8_t;
typedef unsigned short int  uint16_t;
typedef unsigned long int   uint32_t;
#endif

but as you can see in the above autoconf test C code, only
HAVE_INTTYPES_H is defined but not USE_INTTYPES_H, so uint32_t is
defined again in vf_iface.h, which causes the trouble.

I'm not fully sure, whether this is a bug in vf_iface.h or in autoconf
(which shouldn't try to use vf_iface.h and stdint.h in one C program),
maybe you want to reassign the bug report or show me a better autoconf
command to check for availability of vf_iface.h.

-- System Information:
Debian Release: 3.1
  APT prefers testing
  APT policy: (80, 'testing'), (70, 'unstable'), (1, 'experimental')
Architecture: i386 (i686)
Kernel: Linux 2.4.31
Locale: LANG=de_DE, LC_CTYPE=de_DE (charmap=ISO-8859-1)

Versions of packages libvformat1-dev depends on:
ii  libc6-dev                   2.3.2.ds1-22 GNU C Library: Development Librari
ii  libvformat1                 1.13-3       Library to read and write vcard fi

-- no debconf information

Tschoeeee

        Roland

-- 
 * [EMAIL PROTECTED] * http://www.spinnaker.de/ *


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to