From f03f830e711ead302fa48ba67dc101a9a834d260 Mon Sep 17 00:00:00 2001 From: Ivan Solovev Date: Wed, 5 Oct 2022 18:34:26 +0200 Subject: Bootstrap: explicitly include stdlib.h to check for __GLIBC_PREREQ Previously the code was relying on the includes in qglobal.h, but now when we try to get rid of qglobal.h we can end up in a situation when qconfig-bootstrap.h was first included before qglobal.h (__GLIBC_PREREQ not defined), and also included once again after qglobal.h (__GLIBC_PREREQ defined, at least on linux). This resulted in redefenition of Qt features dependent on __GLIBC_PREREQ. This patch fixes it by explicitly including the stdlib.h header which will provide __GLIBC_PREREQ definition when it is available. Task-number: QTBUG-107046 Change-Id: Idbf7a11151c5f81723131daf25c06ef454ff5cbb Reviewed-by: Fabian Kosmale --- src/corelib/global/qconfig-bootstrapped.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/corelib/global') diff --git a/src/corelib/global/qconfig-bootstrapped.h b/src/corelib/global/qconfig-bootstrapped.h index 61fd6479b1..5d42facca3 100644 --- a/src/corelib/global/qconfig-bootstrapped.h +++ b/src/corelib/global/qconfig-bootstrapped.h @@ -23,6 +23,8 @@ #ifdef QT_BOOTSTRAPPED +#include // for __GLIBC_PREREQ + #ifndef QT_NO_EXCEPTIONS #define QT_NO_EXCEPTIONS #endif -- cgit v1.2.3