public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Andreas Sturmlechner" <asturm@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: media-gfx/krita/files/, media-gfx/krita/
Date: Wed, 29 Dec 2021 16:34:58 +0000 (UTC)	[thread overview]
Message-ID: <1640792482.8e8f74afb6662f813be78b857d6a88a852548e17.asturm@gentoo> (raw)

commit:     8e8f74afb6662f813be78b857d6a88a852548e17
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Wed Dec 29 11:50:41 2021 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Wed Dec 29 15:41:22 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8e8f74af

media-gfx/krita: Fix build with clang

Reported-by: Michael Egger <egger.m <AT> protonmail.com>
Closes: https://bugs.gentoo.org/830225
Package-Manager: Portage-3.0.30, Repoman-3.0.3
Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 media-gfx/krita/files/krita-5.0.0-clang.patch      | 50 ++++++++++++++++++++++
 .../{krita-5.0.0.ebuild => krita-5.0.0-r1.ebuild}  |  5 ++-
 2 files changed, 54 insertions(+), 1 deletion(-)

diff --git a/media-gfx/krita/files/krita-5.0.0-clang.patch b/media-gfx/krita/files/krita-5.0.0-clang.patch
new file mode 100644
index 000000000000..6c9c71d4fca2
--- /dev/null
+++ b/media-gfx/krita/files/krita-5.0.0-clang.patch
@@ -0,0 +1,50 @@
+From 0b755beaa1fdba03d38f887b93a15a58fc0830c7 Mon Sep 17 00:00:00 2001
+From: Sharaf Zaman <shzam@sdf.org>
+Date: Wed, 27 Oct 2021 22:19:07 +0000
+Subject: [PATCH] Fix build on linux clang targets
+
+In CheckAtomic.cmake we include is_lock_free because these routines
+don't seem to be included in the compiler's "simple atomics". This
+triggers a failure in clang toolchain, forcing it to link libatomic.
+
+Resulting in error: ld.lld: error: undefined symbol: __atomic_is_lock_free
+
+CCBUG:444247
+CCBUG:444547
+---
+ cmake/modules/CheckAtomic.cmake | 1 +
+ libs/image/CMakeLists.txt       | 6 ++----
+ 2 files changed, 3 insertions(+), 4 deletions(-)
+
+diff --git a/cmake/modules/CheckAtomic.cmake b/cmake/modules/CheckAtomic.cmake
+index b061e2d65b..df6b70504c 100644
+--- a/cmake/modules/CheckAtomic.cmake
++++ b/cmake/modules/CheckAtomic.cmake
+@@ -46,6 +46,7 @@ function(check_working_cxx_atomics64 varname)
+ 	std::atomic<uint64_t> x (0);
+ 	int main() {
+ 		uint64_t i = x.load(std::memory_order_relaxed);
++		x.is_lock_free();
+ 		return 0;
+ 	}
+ 	" ${varname})
+diff --git a/libs/image/CMakeLists.txt b/libs/image/CMakeLists.txt
+index e883c7f1c8..43c945fad3 100644
+--- a/libs/image/CMakeLists.txt
++++ b/libs/image/CMakeLists.txt
+@@ -372,10 +372,8 @@ target_link_libraries(kritaimage
+ 
+ target_link_libraries(kritaimage PUBLIC ${Boost_SYSTEM_LIBRARY})
+ 
+-if(NOT HAVE_CXX_ATOMICS_WITHOUT_LIB)
+-    if(NOT HAVE_CXX_ATOMICS64_WITHOUT_LIB)
+-        target_link_libraries(kritaimage PUBLIC atomic)
+-    endif()
++if(HAVE_CXX_ATOMICS_WITH_LIB OR HAVE_CXX_ATOMICS64_WITH_LIB)
++   target_link_libraries(kritaimage PUBLIC atomic)
+ endif()
+ 
+ if(OpenEXR_FOUND)
+-- 
+GitLab
+

diff --git a/media-gfx/krita/krita-5.0.0.ebuild b/media-gfx/krita/krita-5.0.0-r1.ebuild
similarity index 96%
rename from media-gfx/krita/krita-5.0.0.ebuild
rename to media-gfx/krita/krita-5.0.0-r1.ebuild
index 80d88c6840a7..757396adc400 100644
--- a/media-gfx/krita/krita-5.0.0.ebuild
+++ b/media-gfx/krita/krita-5.0.0-r1.ebuild
@@ -86,7 +86,10 @@ BDEPEND="
 	sys-devel/gettext
 "
 
-PATCHES=( "${FILESDIR}"/${PN}-4.3.1-tests-optional.patch )
+PATCHES=(
+	"${FILESDIR}"/${PN}-4.3.1-tests-optional.patch
+	"${FILESDIR}"/${P}-clang.patch # bug 830225
+)
 
 pkg_setup() {
 	python-single-r1_pkg_setup


             reply	other threads:[~2021-12-29 16:35 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-29 16:34 Andreas Sturmlechner [this message]
  -- strict thread matches above, loose matches on Subject: below --
2025-10-04 12:44 [gentoo-commits] repo/gentoo:master commit in: media-gfx/krita/files/, media-gfx/krita/ Andreas Sturmlechner
2025-02-28  8:19 Andreas Sturmlechner
2024-11-28 17:34 Andreas Sturmlechner
2024-11-25 22:39 Andreas Sturmlechner
2024-11-09 15:21 Andreas Sturmlechner
2024-07-13 19:59 Andreas Sturmlechner
2024-07-13 18:02 Sam James
2024-01-21 19:15 Andreas Sturmlechner
2023-10-03 19:21 Andreas Sturmlechner
2023-01-24 16:12 Andreas Sturmlechner
2022-06-06  1:27 Sam James
2022-02-19 16:27 Andreas Sturmlechner
2021-02-23 19:53 Andreas Sturmlechner
2020-10-31  9:23 Andreas Sturmlechner
2020-04-18 19:33 Andreas Sturmlechner
2019-11-15 17:37 Andreas Sturmlechner
2019-07-31  9:45 Andreas Sturmlechner
2019-07-16 11:00 Andreas Sturmlechner
2019-06-27 17:21 Andreas Sturmlechner
2019-06-27 17:21 Andreas Sturmlechner
2019-06-01 14:26 Andreas Sturmlechner
2019-04-03 18:59 Andreas Sturmlechner
2019-01-05 21:08 Andreas Sturmlechner
2018-10-15 16:46 Andreas Sturmlechner
2017-10-18  0:35 Andreas Sturmlechner
2017-10-15 20:47 Andreas Sturmlechner
2017-08-19 22:57 Andreas Sturmlechner
2017-02-15 16:40 Guilherme Amadio
2016-12-17 17:51 Johannes Huber
2016-09-22 11:40 Michael Palimaka

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1640792482.8e8f74afb6662f813be78b857d6a88a852548e17.asturm@gentoo \
    --to=asturm@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox