[Rd] Error compiling on HP-UX

Pascal A. Niklaus pascal.niklaus at ipw.agrl.ethz.ch
Tue Dec 19 12:13:30 CET 2006


> _APP32_64BIT_OFF_T gets defined in sys/stdsyms.h:
> (I've put the file at http://azug.minpet.unibas.ch/~pascal/R/stdsyms.h)
>
> # ifdef _FILE_OFFSET_BITS
> #  if _FILE_OFFSET_BITS == 64
> #    define _FILE64		/* _FILE64 is obsolescent; don't use it */
> #    define __64BIT_OFF_T
> #    if !defined(__LP64__)
> #       define _APP32_64BIT_OFF_T
> #    endif
> #  else
> #    if _FILE_OFFSET_BITS != 32
> 	#error "_FILE_OFFSET_BITS defined to invalid number!!"
> #    endif
> #  endif/* _FILE_OFFSET_BITS == 64 */
> # endif /* _FILE_OFFSET_BITS */
>
> Does that mean that the platform include files are broken or is this a
> problem with the way they are included in R? I fear I have no means to
> change the /usr/include/... files on that machine.

Hmm, I probably did not show the relevant #ifdef into which this is nested:

/* Large (64-bit) Files symbols */

#if defined(__STDC_EXT__) || !defined(__STDC__) || defined(__LP64__)

# ifdef __LP64__
#   ifndef _FILE_OFFSET_BITS
#     define _FILE_OFFSET_BITS 64 
#   else
#    if _FILE_OFFSET_BITS != 64
      #error "_FILE_OFFSET_BITS definition incompatible with __LP64__."
#    endif
#   endif /* _FILE_OFFSET_BITS */

#   ifndef _PSTAT64
#     define _PSTAT64 
#   endif /* _PSTAT64 */

#   ifndef _KI64
#     define _KI64
#   endif /* _KI64 */

# endif /* __LP64__ */

# ifdef _FILE_OFFSET_BITS
#  if _FILE_OFFSET_BITS == 64
#    define _FILE64		/* _FILE64 is obsolescent; don't use it */
#    define __64BIT_OFF_T
#    if !defined(__LP64__)
#       define _APP32_64BIT_OFF_T
#    endif 
#  else
#    if _FILE_OFFSET_BITS != 32
	#error "_FILE_OFFSET_BITS defined to invalid number!!"
#    endif
#  endif/* _FILE_OFFSET_BITS == 64 */
# endif /* _FILE_OFFSET_BITS */

# define _LFS_LARGEFILE   1
# define _LFS64_LARGEFILE 1

# ifdef _LARGEFILE64_SOURCE
#  ifndef _LARGEFILE_SOURCE
#    define _LARGEFILE_SOURCE
#  endif
# endif

#else  /* strict ANSI */

# ifdef  _FILE_OFFSET_BITS
#  if !defined(__LP64__) && _FILE_OFFSET_BITS == 64
    #error "Large Files (ILP32) not supported in strict ANSI mode."
#  endif
# endif

# ifdef _LARGEFILE64_SOURCE
    #error "Large File interfaces not supported in strict ANSI mode."
# endif

# ifdef _PSTAT64
    #error "wide mode pstat interfaces not supported in strict ANSI mode."
# endif

#endif /* __STDC_EXT__ || ! __STDC__  || __LP64__ */



More information about the R-devel mailing list