From d674e9a17f215d8c0fb3ae9e8c44e9a77952c3d1 Mon Sep 17 00:00:00 2001
From: Sam James <sam@gentoo.org>
Date: Thu, 17 Apr 2025 19:57:46 +0100
Subject: [PATCH] CMake: don't build with -fPIE

Avoid mixing -fPIC objects with -fPIE at LTO link time. This can produce
invalid Qt binaries when Gentoo's default-PIE toolchain is used.

Bug: https://bugs.gentoo.org/941890
---
 CMakeLists.txt | 1 -
 1 file changed, 1 deletion(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index d82a718bf6..c177e46571 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1440,7 +1440,6 @@ if(NOT CMAKE_C_COMPILER_ID MATCHES "MSVC" AND NOT OSS_FUZZ)
 		endif()
 	else()
 		include(CheckPIESupported)
-		check_pie_supported()
 	endif()
 endif()
 
-- 
2.49.0
