From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <gentoo-commits+bounces-1696785-garchives=archives.gentoo.org@lists.gentoo.org>
Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature RSA-PSS (4096 bits))
	(No client certificate requested)
	by finch.gentoo.org (Postfix) with ESMTPS id 5A5A11581F3
	for <garchives@archives.gentoo.org>; Tue,  3 Dec 2024 19:22:08 +0000 (UTC)
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id 6FAFBE08ED;
	Tue,  3 Dec 2024 19:22:02 +0000 (UTC)
Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature RSA-PSS (4096 bits))
	(No client certificate requested)
	by pigeon.gentoo.org (Postfix) with ESMTPS id 53BAFE08ED
	for <gentoo-commits@lists.gentoo.org>; Tue,  3 Dec 2024 19:22:02 +0000 (UTC)
Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature RSA-PSS (4096 bits))
	(No client certificate requested)
	by smtp.gentoo.org (Postfix) with ESMTPS id 376B9341B52
	for <gentoo-commits@lists.gentoo.org>; Tue,  3 Dec 2024 19:22:01 +0000 (UTC)
Received: from localhost.localdomain (localhost [IPv6:::1])
	by oystercatcher.gentoo.org (Postfix) with ESMTP id 8F8C822C6
	for <gentoo-commits@lists.gentoo.org>; Tue,  3 Dec 2024 19:21:57 +0000 (UTC)
From: "Andreas Sturmlechner" <asturm@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Content-Transfer-Encoding: 8bit
Content-type: text/plain; charset=UTF-8
Reply-To: gentoo-dev@lists.gentoo.org, "Andreas Sturmlechner" <asturm@gentoo.org>
Message-ID: <1733253686.f9138ef0b29d4418079faa14e9caaf0151fddadc.asturm@gentoo>
Subject: [gentoo-commits] repo/gentoo:master commit in: sci-astronomy/kstars/files/, sci-astronomy/kstars/
X-VCS-Repository: repo/gentoo
X-VCS-Files: sci-astronomy/kstars/files/kstars-3.7.4-cmake.patch sci-astronomy/kstars/kstars-3.7.4.ebuild
X-VCS-Directories: sci-astronomy/kstars/ sci-astronomy/kstars/files/
X-VCS-Committer: asturm
X-VCS-Committer-Name: Andreas Sturmlechner
X-VCS-Revision: f9138ef0b29d4418079faa14e9caaf0151fddadc
X-VCS-Branch: master
Date: Tue,  3 Dec 2024 19:21:57 +0000 (UTC)
Precedence: bulk
List-Post: <mailto:gentoo-commits@lists.gentoo.org>
List-Help: <mailto:gentoo-commits+help@lists.gentoo.org>
List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org>
List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org>
List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org>
X-BeenThere: gentoo-commits@lists.gentoo.org
X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply
X-Archives-Salt: 4b0dcbb7-3324-4c95-860a-292f932f19f4
X-Archives-Hash: d770729c036f0450068b9021690598ac

commit:     f9138ef0b29d4418079faa14e9caaf0151fddadc
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Tue Dec  3 18:49:33 2024 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Tue Dec  3 19:21:26 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f9138ef0

sci-astronomy/kstars: Disable upstream messing around with any flags

Closes: https://bugs.gentoo.org/895892
Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 .../kstars/files/kstars-3.7.4-cmake.patch          | 62 ++++++++++++++++++++++
 sci-astronomy/kstars/kstars-3.7.4.ebuild           |  4 ++
 2 files changed, 66 insertions(+)

diff --git a/sci-astronomy/kstars/files/kstars-3.7.4-cmake.patch b/sci-astronomy/kstars/files/kstars-3.7.4-cmake.patch
new file mode 100644
index 000000000000..8306f1150f7b
--- /dev/null
+++ b/sci-astronomy/kstars/files/kstars-3.7.4-cmake.patch
@@ -0,0 +1,62 @@
+From 5c66594069b836e0fe806653e344f4e36d1e9c1e Mon Sep 17 00:00:00 2001
+From: Andreas Sturmlechner <asturm@gentoo.org>
+Date: Tue, 3 Dec 2024 19:46:01 +0100
+Subject: [PATCH] Thanks, but no thanks
+
+Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
+---
+ CMakeLists.txt | 10 +++++-----
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 091078e4c..af6ec66f4 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -343,7 +343,7 @@ add_definitions(-DQT_NO_CAST_TO_ASCII)
+ # Needed for htmesh, and libraw
+ kde_enable_exceptions()
+ 
+-if (UNIX)
++if (0)
+ 
+   # TEMPORARY: To disable QCustomPlot warning until 2.0.0 is released which fixes these warnings
+   SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-non-virtual-dtor")
+@@ -362,7 +362,7 @@ if (ANDROID)
+ endif ()
+ 
+ # Add security (hardening flags)
+-IF (UNIX OR APPLE OR ANDROID)
++IF (0)
+     SET(SEC_COMP_FLAGS "${SEC_COMP_FLAGS} -fstack-protector-all -Wcast-align -fPIE")
+     # This is ill-defined, but I searched for a solution for quite a long time to no avail
+     # - FORTIFY_SOURCE generates a warning when there is no code optimization, and warnings will become errors at some point
+@@ -394,7 +394,7 @@ IF (UNIX OR APPLE OR ANDROID)
+ ENDIF ()
+ 
+ # Clang Format support
+-IF (UNIX OR APPLE)
++IF (0)
+     SET(FORMAT_CODE OFF CACHE BOOL "Enable Clang Format")
+     IF (FORMAT_CODE MATCHES ON)
+         FILE(GLOB_RECURSE ALL_SOURCE_FILES *.c *.cpp *.h)
+@@ -415,7 +415,7 @@ ENDIF ()
+ 
+ SET(FIX_WARNINGS OFF CACHE BOOL "Enable strict compilation mode to turn compiler warnings to errors")
+ # Warning, debug and linker flags
+-IF (UNIX OR APPLE)
++IF (0)
+     SET(COMP_FLAGS "")
+     SET(LINKER_FLAGS "")
+     # Verbose warnings and turns all to errors
+@@ -479,7 +479,7 @@ ENDIF ()
+ 
+ # Sanitizer support
+ SET(SANITIZERS OFF CACHE BOOL "Sanitizer support for gcc and Clang")
+-IF (SANITIZERS AND
++IF (0 AND
+     ((UNIX AND (CMAKE_CXX_COMPILER_ID STREQUAL "Clang") OR CMAKE_COMPILER_IS_GNUCXX) OR
+      (APPLE AND (CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang" OR CMAKE_COMPILER_IS_GNUCXX))))
+     SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fsanitize=address,undefined -fno-omit-frame-pointer")
+-- 
+2.47.1
+

diff --git a/sci-astronomy/kstars/kstars-3.7.4.ebuild b/sci-astronomy/kstars/kstars-3.7.4.ebuild
index 9377bc58acfe..54123e0ccfc3 100644
--- a/sci-astronomy/kstars/kstars-3.7.4.ebuild
+++ b/sci-astronomy/kstars/kstars-3.7.4.ebuild
@@ -89,6 +89,10 @@ CMAKE_SKIP_TESTS=(
 	TestEkos{Capture,FilterWheel,Focus,Mount,Scheduler{,Ops},Simulator}
 )
 
+PATCHES=(
+	"${FILESDIR}/${P}-cmake.patch" # bug 895892
+)
+
 src_configure() {
 	local mycmakeargs=(
 		-DBUILD_PYKSTARS=OFF