From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: 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 (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 816B3158030 for ; Tue, 28 Feb 2023 13:12:58 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id DB697E07B3; Tue, 28 Feb 2023 13:12:57 +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 C3938E07B3 for ; Tue, 28 Feb 2023 13:12:57 +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 F3E92340831 for ; Tue, 28 Feb 2023 13:12:56 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 8B3BF7F9 for ; Tue, 28 Feb 2023 13:12:55 +0000 (UTC) From: "Marek Szuba" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Marek Szuba" Message-ID: <1677589960.05e28cce9d058d40e7d2001c1202b315b8a6742d.marecki@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: media-gfx/darktable/files/, media-gfx/darktable/ X-VCS-Repository: repo/gentoo X-VCS-Files: media-gfx/darktable/darktable-4.2.1.ebuild media-gfx/darktable/files/darktable-4.2.1_cmake-musl.patch X-VCS-Directories: media-gfx/darktable/ media-gfx/darktable/files/ X-VCS-Committer: marecki X-VCS-Committer-Name: Marek Szuba X-VCS-Revision: 05e28cce9d058d40e7d2001c1202b315b8a6742d X-VCS-Branch: master Date: Tue, 28 Feb 2023 13:12:55 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 70dd7220-b289-48b3-9c68-a7a48444e34b X-Archives-Hash: f1473d83cd91e02e6160b5dff1376af4 commit: 05e28cce9d058d40e7d2001c1202b315b8a6742d Author: Marek Szuba gentoo org> AuthorDate: Tue Feb 28 12:07:15 2023 +0000 Commit: Marek Szuba gentoo org> CommitDate: Tue Feb 28 13:12:40 2023 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=05e28cce media-gfx/darktable: fix rawspeed CPU-property detection on musl For page-cache size, the sys-libs/musl version currently in the tree does support the relevant syscall so just make sure the test program recognises this correctly. For cache-line length, it does not presently seem to be possible to look this up on a musl system so have CMake fall back to the hard-coded default. It can already do so when in "build binary package" mode so it has been a simple matter of extending one condition to check for the ebuild-specified "am I linking against musl?" option. Closes: https://bugs.gentoo.org/832027 Signed-off-by: Marek Szuba gentoo.org> media-gfx/darktable/darktable-4.2.1.ebuild | 2 ++ .../files/darktable-4.2.1_cmake-musl.patch | 22 ++++++++++++++++++++++ 2 files changed, 24 insertions(+) diff --git a/media-gfx/darktable/darktable-4.2.1.ebuild b/media-gfx/darktable/darktable-4.2.1.ebuild index c9c57caa2f1f..aba89cc810c2 100644 --- a/media-gfx/darktable/darktable-4.2.1.ebuild +++ b/media-gfx/darktable/darktable-4.2.1.ebuild @@ -98,6 +98,7 @@ PATCHES=( "${FILESDIR}"/${PN}-3.0.2_cmake-march-autodetection.patch "${FILESDIR}"/${PN}-3.4.0_jsonschema-automagic.patch "${FILESDIR}"/${PN}-3.4.1_libxcf-cmake.patch + "${FILESDIR}"/${PN}-4.2.1_cmake-musl.patch ) S="${WORKDIR}/${P/_/~}" @@ -140,6 +141,7 @@ src_configure() { -DDONT_USE_INTERNAL_LUA=ON -DRAWSPEED_ENABLE_LTO=$(usex lto) -DRAWSPEED_ENABLE_WERROR=OFF + -DRAWSPEED_MUSL_SYSTEM=$(usex elibc_musl) -DTESTBUILD_OPENCL_PROGRAMS=OFF -DUSE_AVIF=$(usex avif) -DUSE_CAMERA_SUPPORT=$(usex gphoto2) diff --git a/media-gfx/darktable/files/darktable-4.2.1_cmake-musl.patch b/media-gfx/darktable/files/darktable-4.2.1_cmake-musl.patch new file mode 100644 index 000000000000..33ad7f647752 --- /dev/null +++ b/media-gfx/darktable/files/darktable-4.2.1_cmake-musl.patch @@ -0,0 +1,22 @@ +--- a/src/external/rawspeed/cmake/Modules/cpu-cache-line-size.cmake ++++ b/src/external/rawspeed/cmake/Modules/cpu-cache-line-size.cmake +@@ -2,7 +2,7 @@ + + unset(RAWSPEED_CACHELINESIZE) + +-if(BINARY_PACKAGE_BUILD) ++if(BINARY_PACKAGE_BUILD OR RAWSPEED_MUSL_SYSTEM) + message(STATUS "Performing binary package build, using hardcoded value.") + else() + try_run(RAWSPEED_CACHELINESIZE_EXITCODE RAWSPEED_CACHELINESIZE_COMPILED +--- a/src/external/rawspeed/cmake/Modules/cpu-page-size.cpp ++++ b/src/external/rawspeed/cmake/Modules/cpu-page-size.cpp +@@ -4,7 +4,7 @@ + #include // for _POSIX_C_SOURCE, sysconf, _SC_PAGESIZE + #endif + +-#if (defined(_POSIX_C_SOURCE) && _POSIX_C_SOURCE >= 1) || defined(__APPLE__) ++#if defined(_SC_PAGESIZE) + + int main() { + long val = ::sysconf(_SC_PAGESIZE);