Add SIZEOF_{SHORT,INT,LONGLONG,PTHREAD_T} (GH PR #20)
This commit is contained in:
parent
7d2082cbb2
commit
0364b16e8c
16
libbuild2-autoconf/libbuild2/autoconf/checks/SIZEOF_INT.h
Normal file
16
libbuild2-autoconf/libbuild2/autoconf/checks/SIZEOF_INT.h
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
// SIZEOF_INT
|
||||||
|
|
||||||
|
#undef SIZEOF_INT
|
||||||
|
|
||||||
|
#ifdef _MSC_VER
|
||||||
|
# define SIZEOF_INT 4
|
||||||
|
#else
|
||||||
|
/* Both GCC and Clang (and maybe others) define __SIZEOF_INT__. */
|
||||||
|
# ifdef __SIZEOF_INT__
|
||||||
|
# define SIZEOF_INT __SIZEOF_INT__
|
||||||
|
# endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef SIZEOF_INT
|
||||||
|
# error unable to determine size of int
|
||||||
|
#endif
|
@ -0,0 +1,16 @@
|
|||||||
|
// SIZEOF_LONG_LONG
|
||||||
|
|
||||||
|
#undef SIZEOF_LONG_LONG
|
||||||
|
|
||||||
|
#ifdef _MSC_VER
|
||||||
|
# define SIZEOF_LONG_LONG 8
|
||||||
|
#else
|
||||||
|
/* Both GCC and Clang (and maybe others) define __SIZEOF_LONG_LONG__. */
|
||||||
|
# ifdef __SIZEOF_LONG_LONG__
|
||||||
|
# define SIZEOF_LONG_LONG __SIZEOF_LONG_LONG__
|
||||||
|
# endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef SIZEOF_LONG_LONG
|
||||||
|
# error unable to determine size of long long
|
||||||
|
#endif
|
@ -0,0 +1,15 @@
|
|||||||
|
// SIZEOF_PTHREAD_T
|
||||||
|
|
||||||
|
#undef SIZEOF_PTHREAD_T
|
||||||
|
|
||||||
|
#ifndef _WIN32
|
||||||
|
# ifdef defined(__APPLE__)
|
||||||
|
# ifdef __LP64__
|
||||||
|
# define SIZEOF_PTHREAD_T 8
|
||||||
|
# else
|
||||||
|
# define SIZEOF_PTHREAD_T 4
|
||||||
|
# endif
|
||||||
|
# else
|
||||||
|
# define SIZEOF_PTHREAD_T 4
|
||||||
|
# endif
|
||||||
|
#endif
|
16
libbuild2-autoconf/libbuild2/autoconf/checks/SIZEOF_SHORT.h
Normal file
16
libbuild2-autoconf/libbuild2/autoconf/checks/SIZEOF_SHORT.h
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
// SIZEOF_SHORT
|
||||||
|
|
||||||
|
#undef SIZEOF_SHORT
|
||||||
|
|
||||||
|
#ifdef _MSC_VER
|
||||||
|
# define SIZEOF_SHORT 2
|
||||||
|
#else
|
||||||
|
/* Both GCC and Clang (and maybe others) define __SIZEOF_SHORT__. */
|
||||||
|
# ifdef __SIZEOF_SHORT__
|
||||||
|
# define SIZEOF_SHORT __SIZEOF_SHORT__
|
||||||
|
# endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef SIZEOF_SHORT
|
||||||
|
# error unable to determine size of short
|
||||||
|
#endif
|
Loading…
Reference in New Issue
Block a user