| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
#ifndef __PYPY_PRECOMMONDEFS_H |
| 8 |
#define __PYPY_PRECOMMONDEFS_H |
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
#define _DARWIN_C_SOURCE 1 |
| 13 |
|
| 14 |
#if defined(i386) || defined(__i386__) || defined(__i386) || defined(_M_IX86) || defined(__arm__) |
| 15 |
#define _FILE_OFFSET_BITS 64 |
| 16 |
#define _LARGEFILE_SOURCE 1 |
| 17 |
#endif |
| 18 |
|
| 19 |
#define _GNU_SOURCE 1 |
| 20 |
|
| 21 |
#define _NETBSD_SOURCE 1 |
| 22 |
|
| 23 |
|
| 24 |
#ifndef __APPLE__ |
| 25 |
# ifndef _POSIX_C_SOURCE |
| 26 |
# define _POSIX_C_SOURCE 200809L |
| 27 |
# endif |
| 28 |
#endif |
| 29 |
|
| 30 |
#define __BSD_VISIBLE 1 |
| 31 |
#define __XSI_VISIBLE 700 |
| 32 |
|
| 33 |
#define WIN32_LEAN_AND_MEAN |
| 34 |
#ifdef _WIN64 |
| 35 |
typedef __int64 Signed; |
| 36 |
typedef unsigned __int64 Unsigned; |
| 37 |
# define SIGNED_MIN LLONG_MIN |
| 38 |
#else |
| 39 |
typedef long Signed; |
| 40 |
typedef unsigned long Unsigned; |
| 41 |
# define SIGNED_MIN LONG_MIN |
| 42 |
#endif |
| 43 |
|
| 44 |
#if !defined(RPY_ASSERT) && !defined(RPY_LL_ASSERT) |
| 45 |
# define NDEBUG |
| 46 |
#endif |
| 47 |
|
| 48 |
|
| 49 |
|
| 50 |
|
| 51 |
|
| 52 |
|
| 53 |
|
| 54 |
|
| 55 |
|
| 56 |
|
| 57 |
|
| 58 |
|
| 59 |
|
| 60 |
|
| 61 |
|
| 62 |
|
| 63 |
|
| 64 |
|
| 65 |
|
| 66 |
|
| 67 |
#ifdef __GNUC__ |
| 68 |
# define RPY_EXPORTED extern __attribute__((visibility("default"))) |
| 69 |
# define _RPY_HIDDEN __attribute__((visibility("hidden"))) |
| 70 |
# define RPY_UNUSED __attribute__ ((__unused__)) |
| 71 |
#else |
| 72 |
# define RPY_EXPORTED extern __declspec(dllexport) |
| 73 |
# define _RPY_HIDDEN |
| 74 |
# define RPY_UNUSED |
| 75 |
#endif |
| 76 |
#ifndef RPY_EXTERN |
| 77 |
# define RPY_EXTERN extern _RPY_HIDDEN |
| 78 |
#endif |
| 79 |
|
| 80 |
#if defined(_MSC_VER) |
| 81 |
#define INLINE __inline |
| 82 |
#elif defined(__GNUC__) |
| 83 |
#define INLINE __inline__ |
| 84 |
#else |
| 85 |
#error define inline for this compiler |
| 86 |
#endif |
| 87 |
|
| 88 |
#endif |
| 89 |
|
| 90 |
|