mirror of
https://sourceware.org/git/glibc.git
synced 2024-12-22 02:40:08 +00:00
* include/features.h (__GLIBC_HAVE_LONG_LONG): Define for
compilers that support it. * posix/sys/types.h: Use __GLIBC_HAVE_LONG_LONG. * sysdeps/unix/sysv/linux/bits/types.h: Likewise. * stdlib/stdlib.h: Likewise.
This commit is contained in:
parent
a41179fd9e
commit
5224e27c9e
@ -277,6 +277,14 @@
|
||||
#define __GLIBC_PREREQ(maj, min) \
|
||||
((__GLIBC__ << 16) + __GLIBC_MINOR__ >= ((maj) << 16) + (min))
|
||||
|
||||
/* Decide whether a compiler supports the long long datatypes. */
|
||||
#if defined __GNUC__ \
|
||||
|| (defined __PGI && defined __i386__ ) \
|
||||
|| (defined __INTEL_COMPILER && (defined __i386__ || defined __ia64__)) \
|
||||
|| (defined __STDC_VERSION && __STDC_VERSION >= 199901L)
|
||||
# define __GLIBC_HAVE_LONG_LONG 1
|
||||
#endif
|
||||
|
||||
/* This is here only because every header file already includes this one. */
|
||||
#ifndef __ASSEMBLER__
|
||||
# ifndef _SYS_CDEFS_H
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* Copyright (C) 1991,92,94,95,96,97,98,99,2000 Free Software Foundation, Inc.
|
||||
/* Copyright (C) 1991,92,94,95,96,97,98,99,2000,2001 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
@ -162,7 +162,7 @@ typedef unsigned int uint;
|
||||
typedef char int8_t;
|
||||
typedef short int int16_t;
|
||||
typedef int int32_t;
|
||||
# ifdef __GNUC__
|
||||
# if __GLIBC_HAVE_LONG_LONG
|
||||
__extension__ typedef long long int int64_t;
|
||||
# endif
|
||||
# endif
|
||||
@ -171,7 +171,7 @@ __extension__ typedef long long int int64_t;
|
||||
typedef unsigned char u_int8_t;
|
||||
typedef unsigned short int u_int16_t;
|
||||
typedef unsigned int u_int32_t;
|
||||
# ifdef __GNUC__
|
||||
# if __GLIBC_HAVE_LONG_LONG
|
||||
__extension__ typedef unsigned long long int u_int64_t;
|
||||
# endif
|
||||
|
||||
|
@ -140,7 +140,7 @@ extern int atoi (__const char *__nptr) __THROW __attribute_pure__;
|
||||
/* Convert a string to a long integer. */
|
||||
extern long int atol (__const char *__nptr) __THROW __attribute_pure__;
|
||||
|
||||
#if defined __USE_ISOC99 || (defined __GNUC__ && defined __USE_MISC)
|
||||
#if defined __USE_ISOC99 || (defined __GLIBC_HAVE_LONG_LONG && defined __USE_MISC)
|
||||
/* Convert a string to a long long integer. */
|
||||
__extension__ extern long long int atoll (__const char *__nptr)
|
||||
__THROW __attribute_pure__;
|
||||
@ -167,7 +167,7 @@ extern unsigned long int strtoul (__const char *__restrict __nptr,
|
||||
char **__restrict __endptr, int __base)
|
||||
__THROW;
|
||||
|
||||
#if defined __GNUC__ && defined __USE_BSD
|
||||
#if defined __GLIBC_HAVE_LONG_LONG && defined __USE_BSD
|
||||
/* Convert a string to a quadword integer. */
|
||||
__extension__
|
||||
extern long long int strtoq (__const char *__restrict __nptr,
|
||||
@ -179,7 +179,7 @@ extern unsigned long long int strtouq (__const char *__restrict __nptr,
|
||||
__THROW;
|
||||
#endif /* GCC and use BSD. */
|
||||
|
||||
#if defined __USE_ISOC99 || (defined __GNUC__ && defined __USE_MISC)
|
||||
#if defined __USE_ISOC99 || (defined __GLIBC_HAVE_LONG_LONG && defined __USE_MISC)
|
||||
/* These functions will part of the standard C library in ISO C99. */
|
||||
|
||||
/* Convert a string to a quadword integer. */
|
||||
|
@ -33,7 +33,7 @@ typedef unsigned char __u_char;
|
||||
typedef unsigned short __u_short;
|
||||
typedef unsigned int __u_int;
|
||||
typedef unsigned long __u_long;
|
||||
#ifdef __GNUC__
|
||||
#ifdef __GLIBC_HAVE_LONG_LONG
|
||||
__extension__ typedef unsigned long long int __u_quad_t;
|
||||
__extension__ typedef long long int __quad_t;
|
||||
#else
|
||||
@ -52,7 +52,7 @@ typedef signed short int __int16_t;
|
||||
typedef unsigned short int __uint16_t;
|
||||
typedef signed int __int32_t;
|
||||
typedef unsigned int __uint32_t;
|
||||
#ifdef __GNUC__
|
||||
#ifdef __GLIBC_HAVE_LONG_LONG
|
||||
__extension__ typedef signed long long int __int64_t;
|
||||
__extension__ typedef unsigned long long int __uint64_t;
|
||||
#endif
|
||||
@ -63,7 +63,7 @@ typedef __u_int __uid_t; /* Type of user identifications. */
|
||||
typedef __u_int __gid_t; /* Type of group identifications. */
|
||||
typedef __u_long __ino_t; /* Type of file serial numbers. */
|
||||
typedef __u_int __mode_t; /* Type of file attribute bitmasks. */
|
||||
typedef __u_int __nlink_t; /* Type of file link counts. */
|
||||
typedef __u_int __nlink_t; /* Type of file link counts. */
|
||||
typedef long int __off_t; /* Type of file sizes and offsets. */
|
||||
typedef __quad_t __loff_t; /* Type of file sizes and offsets. */
|
||||
typedef int __pid_t; /* Type of process identifications. */
|
||||
|
Loading…
Reference in New Issue
Block a user