--- /dev/null
+diff -Naur qt_ref/qtbase/src/corelib/global/qendian.h qt/qtbase/src/corelib/global/qendian.h
+--- qt_ref/qtbase/src/corelib/global/qendian.h 2024-06-20 08:48:35.275042443 +0200
++++ qt/qtbase/src/corelib/global/qendian.h 2024-06-19 09:26:15.988364209 +0200
+@@ -47,6 +47,7 @@
+ // include stdlib.h and hope that it defines __GLIBC__ for glibc-based systems
+ #include <stdlib.h>
+ #include <string.h>
++#include <limits>
+
+ #ifdef min // MSVC
+ #undef min
+diff -Naur qt_ref/qtbase/src/corelib/global/qfloat16.h qt/qtbase/src/corelib/global/qfloat16.h
+--- qt_ref/qtbase/src/corelib/global/qfloat16.h 2024-06-20 08:48:35.275042443 +0200
++++ qt/qtbase/src/corelib/global/qfloat16.h 2024-06-19 09:26:58.829940099 +0200
+@@ -44,6 +44,7 @@
+ #include <QtCore/qglobal.h>
+ #include <QtCore/qmetatype.h>
+ #include <string.h>
++#include <limits>
+
+ #if defined(QT_COMPILER_SUPPORTS_F16C) && defined(__AVX2__) && !defined(__F16C__)
+ // All processors that support AVX2 do support F16C too. That doesn't mean
+diff -Naur qt_ref/qtbase/src/corelib/text/qbytearraymatcher.h qt/qtbase/src/corelib/text/qbytearraymatcher.h
+--- qt_ref/qtbase/src/corelib/text/qbytearraymatcher.h 2024-06-20 08:48:35.298042763 +0200
++++ qt/qtbase/src/corelib/text/qbytearraymatcher.h 2024-06-19 09:29:34.864037490 +0200
+@@ -41,6 +41,7 @@
+ #define QBYTEARRAYMATCHER_H
+
+ #include <QtCore/qbytearray.h>
++#include <limits>
+
+ QT_BEGIN_NAMESPACE
+