summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@qt.io>2021-05-18 08:43:52 +0200
committerAllan Sandfeld Jensen <allan.jensen@qt.io>2021-05-18 13:49:30 +0200
commit4341f6763b8a737ebc07bb78ead22bc05a1a515b (patch)
tree01b5b41993c6142074bfd66f752306b1db8123fd /src
parent0c8eb58ba07e248701ff28891c79dfe2fa32dc23 (diff)
Cherry-pick upstream patch for non-gcc/clang/msvc compilersv5.12.115.12.11
Fix build w/ non-GCC-compatible Un*x/Arm compilers Fixes: QTBUG-93779 Pick-to: dev 6.1 6.0 5.15 5.12 Change-Id: Ib52e9ded6e2814c7998d6cd798e945da0f87f7a1 Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
Diffstat (limited to 'src')
-rw-r--r--src/3rdparty/libjpeg/src/ChangeLog.md9
-rw-r--r--src/3rdparty/libjpeg/src/jchuff.c5
-rw-r--r--src/3rdparty/libjpeg/src/jcphuff.c5
3 files changed, 15 insertions, 4 deletions
diff --git a/src/3rdparty/libjpeg/src/ChangeLog.md b/src/3rdparty/libjpeg/src/ChangeLog.md
index 498b8f2729..5ecbf3b510 100644
--- a/src/3rdparty/libjpeg/src/ChangeLog.md
+++ b/src/3rdparty/libjpeg/src/ChangeLog.md
@@ -1,3 +1,12 @@
+2.1.1
+=====
+
+### Significant changes relative to 2.1.0
+
+1. Fixed a regression introduced in 2.1.0 that caused build failures with
+non-GCC-compatible compilers for Un*x/Arm platforms.
+
+
2.1.0
=====
diff --git a/src/3rdparty/libjpeg/src/jchuff.c b/src/3rdparty/libjpeg/src/jchuff.c
index 2bce767ebd..8ff817b151 100644
--- a/src/3rdparty/libjpeg/src/jchuff.c
+++ b/src/3rdparty/libjpeg/src/jchuff.c
@@ -44,8 +44,9 @@
* flags (this defines __thumb__).
*/
-#if defined(__arm__) || defined(__aarch64__) || defined(_M_ARM) || \
- defined(_M_ARM64)
+/* NOTE: Both GCC and Clang define __GNUC__ */
+#if (defined(__GNUC__) && (defined(__arm__) || defined(__aarch64__))) || \
+ defined(_M_ARM) || defined(_M_ARM64)
#if !defined(__thumb__) || defined(__thumb2__)
#define USE_CLZ_INTRINSIC
#endif
diff --git a/src/3rdparty/libjpeg/src/jcphuff.c b/src/3rdparty/libjpeg/src/jcphuff.c
index bd14fc27d5..9bf96124b4 100644
--- a/src/3rdparty/libjpeg/src/jcphuff.c
+++ b/src/3rdparty/libjpeg/src/jcphuff.c
@@ -52,8 +52,9 @@
* flags (this defines __thumb__).
*/
-#if defined(__arm__) || defined(__aarch64__) || defined(_M_ARM) || \
- defined(_M_ARM64)
+/* NOTE: Both GCC and Clang define __GNUC__ */
+#if (defined(__GNUC__) && (defined(__arm__) || defined(__aarch64__))) || \
+ defined(_M_ARM) || defined(_M_ARM64)
#if !defined(__thumb__) || defined(__thumb2__)
#define USE_CLZ_INTRINSIC
#endif