Török Edwin wrote:
> On 2008-11-29 21:42, Bill McKie wrote:
>> Trying to build clamav-0.94.2 under Fedora-9 Linux (with all the latest 
>> Fedora-9 updates installed).
>>   
> 
> Does this work:
> 
> $ cat <<EOF >foo.c
> #include <limits.h>
> EOF
> $ gcc -v -c foo.c

No, that also fails.  Interestingly, some other 3rd party applications 
build ok from source on this FC9 system, and I assume they are not 
referencing this troublesome limits.h header file.  Also, clamav-0.94.2 
builds ok under FC6 Linux.

gcc -v -c foo.c
Using built-in specs.
Target: i386-redhat-linux
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man 
--infodir=/usr/share/info 
--with-bugurl=http://bugzilla.redhat.com/bugzilla --enable-bootstrap 
--enable-shared --enable-threads=posix --enable-checking=release 
--with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions 
--enable-languages=c,c++,objc,obj-c++,java,fortran,ada 
--enable-java-awt=gtk --disable-dssi --enable-plugin 
--with-java-home=/usr/lib/jvm/java-1.5.0-gcj-1.5.0.0/jre 
--enable-libgcj-multifile --enable-java-maintainer-mode 
--with-ecj-jar=/usr/share/java/eclipse-ecj.jar 
--disable-libjava-multilib --with-cpu=generic --build=i386-redhat-linux
Thread model: posix
gcc version 4.3.0 20080428 (Red Hat 4.3.0-8) (GCC)
COLLECT_GCC_OPTIONS='-v' '-c' '-mtune=generic'
  /usr/libexec/gcc/i386-redhat-linux/4.3.0/cc1 -quiet -v foo.c -quiet 
-dumpbase foo.c -mtune=generic -auxbase foo -version -o /tmp/ccqFwoX4.s
ignoring nonexistent directory 
"/usr/lib/gcc/i386-redhat-linux/4.3.0/include-fixed"
ignoring nonexistent directory 
"/usr/lib/gcc/i386-redhat-linux/4.3.0/../../../../i386-redhat-linux/include"
#include "..." search starts here:
#include <...> search starts here:
  /usr/local/include
  /usr/lib/gcc/i386-redhat-linux/4.3.0/include
  /usr/include
End of search list.
GNU C (GCC) version 4.3.0 20080428 (Red Hat 4.3.0-8) (i386-redhat-linux)
        compiled by GNU C version 4.3.0 20080428 (Red Hat 4.3.0-8), GMP version 
4.2.2, MPFR version 2.3.0-p2.
warning: MPFR header version 2.3.0-p2 differs from library version 2.3.1.
GGC heuristics: --param ggc-min-expand=98 --param ggc-min-heapsize=128087
Compiler executable checksum: a6100d27c113f078654b8bcf6e8eb1d2
In file included from 
/usr/lib/gcc/i386-redhat-linux/4.3.0/include/syslimits.h:7,
                  from 
/usr/lib/gcc/i386-redhat-linux/4.3.0/include/limits.h:11,
                  from foo.c:1:
/usr/lib/gcc/i386-redhat-linux/4.3.0/include/limits.h:122:61: error: 
limits.h: No such file or directory

---------------------------------------------------------------

Following is the FC9 file 
/usr/lib/gcc/i386-redhat-linux/4.3.0/include/limits.h

/* This administrivia gets added to the beginning of limits.h
    if the system has its own version of limits.h.  */

/* We use _GCC_LIMITS_H_ because we want this not to match
    any macros that the system's limits.h uses for its own purposes.  */
#ifndef _GCC_LIMITS_H_  /* Terminated in limity.h.  */
#define _GCC_LIMITS_H_

#ifndef _LIBC_LIMITS_H_
/* Use "..." so that we find syslimits.h only in this same directory.  */
#include "syslimits.h"
#endif
#ifndef _LIMITS_H___
#define _LIMITS_H___

/* Number of bits in a `char'.  */
#undef CHAR_BIT
#define CHAR_BIT __CHAR_BIT__

/* Maximum length of a multibyte character.  */
#ifndef MB_LEN_MAX
#define MB_LEN_MAX 1
#endif

/* Minimum and maximum values a `signed char' can hold.  */
#undef SCHAR_MIN
#define SCHAR_MIN (-SCHAR_MAX - 1)
#undef SCHAR_MAX
#define SCHAR_MAX __SCHAR_MAX__

/* Maximum value an `unsigned char' can hold.  (Minimum is 0).  */
#undef UCHAR_MAX
#if __SCHAR_MAX__ == __INT_MAX__
# define UCHAR_MAX (SCHAR_MAX * 2U + 1U)
#else
# define UCHAR_MAX (SCHAR_MAX * 2 + 1)
#endif

/* Minimum and maximum values a `char' can hold.  */
#ifdef __CHAR_UNSIGNED__
# undef CHAR_MIN
# if __SCHAR_MAX__ == __INT_MAX__
#  define CHAR_MIN 0U
# else
#  define CHAR_MIN 0
# endif
# undef CHAR_MAX
# define CHAR_MAX UCHAR_MAX
#else
# undef CHAR_MIN
# define CHAR_MIN SCHAR_MIN
# undef CHAR_MAX
# define CHAR_MAX SCHAR_MAX
#endif

/* Minimum and maximum values a `signed short int' can hold.  */
#undef SHRT_MIN
#define SHRT_MIN (-SHRT_MAX - 1)
#undef SHRT_MAX
#define SHRT_MAX __SHRT_MAX__

/* Maximum value an `unsigned short int' can hold.  (Minimum is 0).  */
#undef USHRT_MAX
#if __SHRT_MAX__ == __INT_MAX__
# define USHRT_MAX (SHRT_MAX * 2U + 1U)
#else
# define USHRT_MAX (SHRT_MAX * 2 + 1)
#endif

/* Minimum and maximum values a `signed int' can hold.  */
#undef INT_MIN
#define INT_MIN (-INT_MAX - 1)
#undef INT_MAX
#define INT_MAX __INT_MAX__

/* Maximum value an `unsigned int' can hold.  (Minimum is 0).  */
#undef UINT_MAX
#define UINT_MAX (INT_MAX * 2U + 1U)

/* Minimum and maximum values a `signed long int' can hold.
    (Same as `int').  */
#undef LONG_MIN
#define LONG_MIN (-LONG_MAX - 1L)
#undef LONG_MAX
#define LONG_MAX __LONG_MAX__

/* Maximum value an `unsigned long int' can hold.  (Minimum is 0).  */
#undef ULONG_MAX
#define ULONG_MAX (LONG_MAX * 2UL + 1UL)

#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
/* Minimum and maximum values a `signed long long int' can hold.  */
# undef LLONG_MIN
# define LLONG_MIN (-LLONG_MAX - 1LL)
# undef LLONG_MAX
# define LLONG_MAX __LONG_LONG_MAX__

/* Maximum value an `unsigned long long int' can hold.  (Minimum is 0).  */
# undef ULLONG_MAX
# define ULLONG_MAX (LLONG_MAX * 2ULL + 1ULL)
#endif

#if defined (__GNU_LIBRARY__) ? defined (__USE_GNU) : !defined 
(__STRICT_ANSI__)
/* Minimum and maximum values a `signed long long int' can hold.  */
# undef LONG_LONG_MIN
# define LONG_LONG_MIN (-LONG_LONG_MAX - 1LL)
# undef LONG_LONG_MAX
# define LONG_LONG_MAX __LONG_LONG_MAX__

/* Maximum value an `unsigned long long int' can hold.  (Minimum is 0).  */
# undef ULONG_LONG_MAX
# define ULONG_LONG_MAX (LONG_LONG_MAX * 2ULL + 1ULL)
#endif

#endif /* _LIMITS_H___ */
/* This administrivia gets added to the end of limits.h
    if the system has its own version of limits.h.  */

#else /* not _GCC_LIMITS_H_ */

#ifdef _GCC_NEXT_LIMITS_H
#include_next <limits.h>                /* recurse down to the real one */
#endif

#endif /* not _GCC_LIMITS_H_ */


>> ./configure --prefix=/usr/local/clamav
>>
>> fails with a cpp error, apparently involving recursion on a reference of 
>> limits.h within:
>>
>> /usr/lib/gcc/i386-redhat-linux/4.3.0/include/limits.h
_______________________________________________
Help us build a comprehensive ClamAV guide: visit http://wiki.clamav.net
http://www.clamav.net/support/ml

Reply via email to