[Help-gnutls] Building gnutls 0.8.10, 0.8.11 fails on gcc 3.2.3 Slackware due to ptrdiff_t conflicting type declaration

Filip Miletic f.miletic at ewi.tudelft.nl
Sun Oct 12 22:02:17 CEST 2003


Greetings everyone.

Building gnutls, either 0.8.10, or 0.8.11 fail on my system (gcc 3.2.3 
that comes with Slackware 9.1) both for the same reason: conflicting 
type declaration for ptrdiff_t. Apparently, the way to test the 
existence of ptrdiff_t is wrong(?) -- or at least inappropriate for gcc 
3.2.3.

I searched the archive of the mailing list and found that I might be 
able to solve the problem by using gnutls 0.9.x. But this gnutls version 
is nowhere (* -- gnutls home page) to be found. Could I 'tweak' 0.8.x to 
work? libgcrypt version is 1.1.42.

Thanking you,
f

What follows are excerpts from various logfiles:

The test for ptrdiff_t fails in ./configure, with:
--- Excerpt from config.log
configure:6742: checking for ptrdiff_t
configure:6770: gcc -c -g -O2 -O2 -finline-functions -pipe  conftest.c >&5
configure: In function `main':
configure:6801: `ptrdiff_t' undeclared (first use in this function)
configure:6801: (Each undeclared identifier is reported only once
configure:6801: for each function it appears in.)
configure:6801: syntax error before ')' token
configure:6773: $? = 1
configure: failed program was:
| #line 6747 "configure"
| /* confdefs.h.  */
|
| #define PACKAGE_NAME ""
| #define PACKAGE_TARNAME ""
| #define PACKAGE_VERSION ""
| #define PACKAGE_STRING ""
| #define PACKAGE_BUGREPORT ""
| #define T_CPU "i686"
| #define T_VENDOR "pc"
| #define T_OS "linux-gnu"
| #define GNUTLS_VERSION "0.8.10"
| #define C99_MACROS 1
| #define STDC_HEADERS 1
| #define TIME_WITH_SYS_TIME 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
| #define HAVE_UNISTD_H 1
| #define HAVE_PWD_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_STDARG_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_SYS_SOCKET_H 1
| #define HAVE_ERRNO_H 1
| #define HAVE_SYS_TIME_H 1
| #define HAVE_TIME_H 1
| #define HAVE_BZERO 1
| #define HAVE_MEMSET 1
| #define HAVE_MEMMOVE 1
| #define HAVE_BCOPY 1
| #define HAVE_MEMCMP 1
| #define HAVE_MEMCPY 1
| #define HAVE_ALLOCA_H 1
| #define HAVE_ALLOCA 1
| #define SIZEOF_UNSIGNED_LONG 4
| #define SIZEOF_UNSIGNED_INT 4
| #define SIZEOF_UNSIGNED_SHORT 2
| #define SIZEOF_UNSIGNED_CHAR 1
| #define SIZEOF_UNSIGNED_CHARP 4
| /* end confdefs.h.  */
|
| # include <sys/types.h>
|
|
| int
| main ()
| {
| if ((ptrdiff_t *) 0)
|   return 0;
| if (sizeof (ptrdiff_t))
|   return 0;| }
configure:6790: result: no


--- compile output:
gcc -DHAVE_CONFIG_H -I. -I. -I.. -I../libextra -Iminitasn1/ 
-I../includes -g -O2 -O2 -finline-functions -pipe -I/usr/local/include 
-MT gnutls_record.lo -MD -MP -MF .deps/gnutls_record.Tpo -c 
gnutls_record.c  -fPIC -DPIC -o .libs/gnutls_record.lo
In file included from /usr/local/include/gpg-error.h:24,
                  from /usr/local/include/gcrypt.h:27,
                  from gnutls_mpi.h:4,
                  from gnutls_int.h:108,
                  from gnutls_record.c:25:
/usr/lib/gcc-lib/i486-slackware-linux/3.2.3/include/stddef.h:151: 
conflicting types for `ptrdiff_t'
defines.h:58: previous declaration of `ptrdiff_t'
In file included from gnutls_int.h:108,
                  from gnutls_record.c:25:
gnutls_mpi.h:27: syntax error before '*' token
gnutls_mpi.h:29: warning: `GCRY_MPI' is deprecated (declared at 
/usr/local/include/gcrypt.h:153)
gnutls_mpi.h:30: warning: `GCRY_MPI' is deprecated (declared at 
/usr/local/include/gcrypt.h:153)
gnutls_mpi.h:32: warning: `GCRY_MPI' is deprecated (declared at 
/usr/local/include/gcrypt.h:153)
gnutls_mpi.h:33: warning: `GCRY_MPI' is deprecated (declared at 
/usr/local/include/gcrypt.h:153)
gnutls_mpi.h:35: syntax error before "MPI"
I






More information about the Gnutls-help mailing list