summaryrefslogtreecommitdiffstats
path: root/src/corelib/global
diff options
context:
space:
mode:
authorOswald Buddenhagen <oswald.buddenhagen@qt.io>2017-04-28 13:27:43 +0200
committerOswald Buddenhagen <oswald.buddenhagen@qt.io>2017-05-03 12:19:57 +0000
commit98c1d516b7f7624f7fcd7b9046783e3903a6a42b (patch)
tree2ae34970877411c731d3348d51a1b06409cb0ec5 /src/corelib/global
parentfe04eade5559370bdb44e1a74a0a96326265358e (diff)
alloca: detect whether alloca.h exists
We can't depend on QT_HAS_INCLUDE for such an important functionality in QtQml, so detect at configure time. alloca() is not a POSIX function (it apparently first appeared in Version 32V AT&T UNIX), so the actual header that defines it varies from system to system. Clearly, if alloca.h exists, that's the one, so we try it first. On most other systems that don't define it, it's in stdlib.h. The only exception is Windows, where it's actually defined in malloc.h. Task-number: QTBUG-59700 Started-by: Thiago Macieira <thiago.macieira@intel.com> Change-Id: Icd0e0d4b27cb4e5eb892fffd14b4b2b389a4684e Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'src/corelib/global')
-rw-r--r--src/corelib/global/qconfig-bootstrapped.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/corelib/global/qconfig-bootstrapped.h b/src/corelib/global/qconfig-bootstrapped.h
index bda8ad7916..0b02ecc8ec 100644
--- a/src/corelib/global/qconfig-bootstrapped.h
+++ b/src/corelib/global/qconfig-bootstrapped.h
@@ -68,6 +68,13 @@
#define QT_CRYPTOGRAPHICHASH_ONLY_SHA1
#define QT_NO_DATASTREAM
+#define QT_FEATURE_alloca 1
+#define QT_FEATURE_alloca_h -1
+#ifdef _WIN32
+# define QT_FEATURE_alloca_malloc_h 1
+#else
+# define QT_FEATURE_alloca_malloc_h -1
+#endif
#define QT_FEATURE_iconv -1
#define QT_FEATURE_icu -1
#define QT_FEATURE_journald -1