| 1 |
/* |
| 2 |
Standard definitions for neon headers |
| 3 |
Copyright (C) 2003-2008, 2010, Joe Orton <[email protected]> |
| 4 |
|
| 5 |
This library is free software; you can redistribute it and/or |
| 6 |
modify it under the terms of the GNU Library General Public |
| 7 |
License as published by the Free Software Foundation; either |
| 8 |
version 2 of the License, or (at your option) any later version. |
| 9 |
|
| 10 |
This library is distributed in the hope that it will be useful, |
| 11 |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 13 |
Library General Public License for more details. |
| 14 |
|
| 15 |
You should have received a copy of the GNU Library General Public |
| 16 |
License along with this library; if not, write to the Free |
| 17 |
Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, |
| 18 |
MA 02111-1307, USA |
| 19 |
|
| 20 |
*/ |
| 21 |
|
| 22 |
#undef NE_BEGIN_DECLS |
| 23 |
#undef NE_END_DECLS |
| 24 |
#ifdef __cplusplus |
| 25 |
# define NE_BEGIN_DECLS extern "C" { |
| 26 |
# define NE_END_DECLS } |
| 27 |
#else |
| 28 |
# define NE_BEGIN_DECLS /* empty */ |
| 29 |
# define NE_END_DECLS /* empty */ |
| 30 |
#endif |
| 31 |
|
| 32 |
#ifndef NE_DEFS_H |
| 33 |
#define NE_DEFS_H |
| 34 |
|
| 35 |
#include <sys/types.h> |
| 36 |
|
| 37 |
#ifdef NE_LFS |
| 38 |
typedef off64_t ne_off_t; |
| 39 |
#else |
| 40 |
typedef off_t ne_off_t; |
| 41 |
#endif |
| 42 |
|
| 43 |
/* define ssize_t for Win32 */ |
| 44 |
#if defined(WIN32) && !defined(ssize_t) |
| 45 |
#define ssize_t int |
| 46 |
#endif |
| 47 |
|
| 48 |
#ifdef __NETWARE__ |
| 49 |
#include <time.h> /* for time_t */ |
| 50 |
#endif |
| 51 |
|
| 52 |
#ifdef __GNUC__ |
| 53 |
#if __GNUC__ >= 3 |
| 54 |
#ifndef NE_PRIVATE |
| 55 |
#define NE_PRIVATE __attribute__((visibility ("hidden"))) |
| 56 |
#endif |
| 57 |
#define ne_attribute_malloc __attribute__((malloc)) |
| 58 |
#else |
| 59 |
#define ne_attribute_malloc |
| 60 |
#endif |
| 61 |
#if __GNUC__ > 3 |
| 62 |
#define ne_attribute_sentinel __attribute__((sentinel)) |
| 63 |
#else |
| 64 |
#define ne_attribute_sentinel |
| 65 |
#endif |
| 66 |
#define ne_attribute(x) __attribute__(x) |
| 67 |
#else |
| 68 |
#define ne_attribute(x) |
| 69 |
#define ne_attribute_malloc |
| 70 |
#define ne_attribute_sentinel |
| 71 |
#endif |
| 72 |
|
| 73 |
#ifndef NE_PRIVATE |
| 74 |
#define NE_PRIVATE |
| 75 |
#endif |
| 76 |
|
| 77 |
#ifndef NE_BUFSIZ |
| 78 |
#define NE_BUFSIZ 8192 |
| 79 |
#endif |
| 80 |
|
| 81 |
#ifndef NE_BUFSIZ_LARGE |
| 82 |
#define NE_BUFSIZ_LARGE (1 << 18) |
| 83 |
#endif |
| 84 |
|
| 85 |
#endif /* NE_DEFS_H */ |