summarylogtreecommitdiffstats
path: root/0014-Fix-setting-exception-flags-of-plugin-targets.patch
blob: d211ff6eb803a336d48abc9a8258096b42a4e56d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
From 6c8a7d0c0e4b69a383f120dc87aaeb495a1c3a24 Mon Sep 17 00:00:00 2001
From: Martchus <martchus@gmx.net>
Date: Sat, 17 Feb 2024 20:48:21 +0100
Subject: [PATCH 14/18] Fix setting exception flags of plugin targets

Change-Id: I93b1b5fa55f3e35e13351d9c981409f1593bf8a8
---
 cmake/QtPluginHelpers.cmake | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/cmake/QtPluginHelpers.cmake b/cmake/QtPluginHelpers.cmake
index fc036cf6a54..108b545e3db 100644
--- a/cmake/QtPluginHelpers.cmake
+++ b/cmake/QtPluginHelpers.cmake
@@ -318,8 +318,11 @@ function(qt_internal_add_plugin target)
 
     qt_internal_add_repo_local_defines("${target}")
 
-    qt_internal_set_exceptions_flags("${target}" ${arg_EXCEPTIONS})
-
+    if(NOT arg_EXCEPTIONS AND NOT ${arg_HEADER_MODULE})
+        qt_internal_set_exceptions_flags("${target}" FALSE)
+    elseif(arg_EXCEPTIONS)
+        qt_internal_set_exceptions_flags("${target}" TRUE)
+    endif()
 
     set(qt_libs_private "")
     qt_internal_get_qt_all_known_modules(known_modules)
-- 
2.47.0