]> gitweb.stoutner.com Git - PrivacyBrowserPC.git/blobdiff - CMakeLists.txt
Partial filter list implementation.
[PrivacyBrowserPC.git] / CMakeLists.txt
index 7f2eac8935db648fe35312c21d362eb38d28c0d7..16aec1623e54d106bc31d68c86700e32f1812080 100644 (file)
@@ -1,6 +1,6 @@
 # Copyright 2022-2023 Soren Stoutner <soren@stoutner.com>.
 #
-# This file is part of Privacy Browser PC <https://www.stoutner.com/privacy-browser-pc>.
+# This file is part of Privacy Browser PC <https://www.stoutner.com/privacy-browser-pc/>.
 #
 # Privacy Browser PC is free software: you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -42,10 +42,20 @@ include(ECMInstallIcons)
 include(ECMQtDeclareLoggingCategory)
 include(FeatureSummary)
 
+# Include the Position Independent Executable checker.  <https://cmake.org/cmake/help/latest/policy/CMP0083.html>
+include(CheckPIESupported)
+
+# Check to see if Position Independent Executable is supported in the current linker and environment.
+check_pie_supported()
+
+# Add the Position Independent Executable compiler flag if it is supported in the current linker and environment.  <https://cmake.org/cmake/help/latest/variable/CMAKE_POSITION_INDEPENDENT_CODE.html>
+set(CMAKE_POSITION_INDEPENDENT_CODE TRUE)
+
 # Load the Qt components.
 find_package(Qt5 ${QT_MIN_VERSION} CONFIG REQUIRED COMPONENTS
     Core
     Gui
+    PrintSupport
     Sql
     WebEngineCore
     WebEngineWidgets