diff options
author | Sebastian Dransfeld <sd@tango.flipp.net> | 2012-11-23 20:25:52 +0000 |
---|---|---|
committer | Sebastian Dransfeld <sd@tango.flipp.net> | 2012-11-23 20:25:52 +0000 |
commit | c2b4b45023f85407a9874c600cecb78c7fdfbacf (patch) | |
tree | f1b72c57c5a880c8277bfdc250a1438f33bea64d /legacy/ecore/src/lib/ecore/ecore_getopt.c | |
parent | b67bef4ed00df6f95f12dfe1e6ee653c9f623821 (diff) |
ecore: alloca
SVN revision: 79577
Diffstat (limited to '')
-rw-r--r-- | legacy/ecore/src/lib/ecore/ecore_getopt.c | 35 |
1 files changed, 18 insertions, 17 deletions
diff --git a/legacy/ecore/src/lib/ecore/ecore_getopt.c b/legacy/ecore/src/lib/ecore/ecore_getopt.c index 377d310f53..d3ffb282f3 100644 --- a/legacy/ecore/src/lib/ecore/ecore_getopt.c +++ b/legacy/ecore/src/lib/ecore/ecore_getopt.c | |||
@@ -2,6 +2,24 @@ | |||
2 | # include <config.h> | 2 | # include <config.h> |
3 | #endif | 3 | #endif |
4 | 4 | ||
5 | #undef alloca | ||
6 | #ifdef HAVE_ALLOCA_H | ||
7 | # include <alloca.h> | ||
8 | #elif defined __GNUC__ | ||
9 | # define alloca __builtin_alloca | ||
10 | #elif defined _AIX | ||
11 | # define alloca __alloca | ||
12 | #elif defined _MSC_VER | ||
13 | # include <malloc.h> | ||
14 | # define alloca _alloca | ||
15 | #else | ||
16 | # include <stddef.h> | ||
17 | # ifdef __cplusplus | ||
18 | extern "C" | ||
19 | # endif | ||
20 | void *alloca (size_t); | ||
21 | #endif | ||
22 | |||
5 | #ifdef STDC_HEADERS | 23 | #ifdef STDC_HEADERS |
6 | # include <stdlib.h> | 24 | # include <stdlib.h> |
7 | # include <stddef.h> | 25 | # include <stddef.h> |
@@ -10,23 +28,6 @@ | |||
10 | # include <stdlib.h> | 28 | # include <stdlib.h> |
11 | # endif | 29 | # endif |
12 | #endif | 30 | #endif |
13 | #ifdef HAVE_ALLOCA_H | ||
14 | # include <alloca.h> | ||
15 | #elif !defined alloca | ||
16 | # ifdef __GNUC__ | ||
17 | # define alloca __builtin_alloca | ||
18 | # elif defined _AIX | ||
19 | # define alloca __alloca | ||
20 | # elif defined _MSC_VER | ||
21 | # include <malloc.h> | ||
22 | # define alloca _alloca | ||
23 | # elif !defined HAVE_ALLOCA | ||
24 | # ifdef __cplusplus | ||
25 | extern "C" | ||
26 | # endif | ||
27 | void *alloca (size_t); | ||
28 | # endif | ||
29 | #endif | ||
30 | 31 | ||
31 | #include <stdlib.h> | 32 | #include <stdlib.h> |
32 | #include <stdio.h> | 33 | #include <stdio.h> |