From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: 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 finch.gentoo.org (Postfix) with ESMTPS id E2AC2158074 for ; Tue, 24 Jun 2025 19:44:22 +0000 (UTC) Received: from lists.gentoo.org (bobolink.gentoo.org [140.211.166.189]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519) (No client certificate requested) (Authenticated sender: relay-lists.gentoo.org@gentoo.org) by smtp.gentoo.org (Postfix) with ESMTPSA id CB821340E6C for ; Tue, 24 Jun 2025 19:44:22 +0000 (UTC) Received: from bobolink.gentoo.org (localhost [127.0.0.1]) by bobolink.gentoo.org (Postfix) with ESMTP id BE846110362; Tue, 24 Jun 2025 19:44:21 +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) (No client certificate requested) by bobolink.gentoo.org (Postfix) with ESMTPS id B6DDD110362 for ; Tue, 24 Jun 2025 19:44:21 +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) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 6DA81341083 for ; Tue, 24 Jun 2025 19:44:21 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 10B932A73 for ; Tue, 24 Jun 2025 19:44:20 +0000 (UTC) From: "Andreas Sturmlechner" 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" Message-ID: <1750794245.da8dbff8c15a12c4dc1f3e3bbc3995b58786491e.asturm@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: eclass/ X-VCS-Repository: repo/gentoo X-VCS-Files: eclass/cmake.eclass X-VCS-Directories: eclass/ X-VCS-Committer: asturm X-VCS-Committer-Name: Andreas Sturmlechner X-VCS-Revision: da8dbff8c15a12c4dc1f3e3bbc3995b58786491e X-VCS-Branch: master Date: Tue, 24 Jun 2025 19:44:20 +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: 339781d1-666d-41d7-ba75-b697a7ec00ac X-Archives-Hash: dd4f3f35522c843914625a0347bd9239 commit: da8dbff8c15a12c4dc1f3e3bbc3995b58786491e Author: Andreas Sturmlechner gentoo org> AuthorDate: Sun Jun 22 21:08:48 2025 +0000 Commit: Andreas Sturmlechner gentoo org> CommitDate: Tue Jun 24 19:44:05 2025 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=da8dbff8 cmake.eclass: Avoid false positives by ensuring we find a function call Otherwise the regex might pick up a query of the resulting version var, e.g.: > if(CMAKE_MINIMUM_REQUIRED_VERSION VERSION_LESS 2.8.12) Closes: https://bugs.gentoo.org/958923 Closes: https://bugs.gentoo.org/958974 Signed-off-by: Andreas Sturmlechner gentoo.org> eclass/cmake.eclass | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eclass/cmake.eclass b/eclass/cmake.eclass index 109227edfe02..2e799f14352e 100644 --- a/eclass/cmake.eclass +++ b/eclass/cmake.eclass @@ -336,7 +336,7 @@ _cmake_check_build_dir() { # Returns 0 if the regex matched (a lower-than-specified version found). _cmake_minreqver-lt() { local ver chk=1 - ver=$(sed -ne "/cmake_minimum_required/I{s/.*\(\.\.\.*\|\s\)\([0-9][0-9.]*\)\([)]\|\s\).*$/\2/p;q}" \ + ver=$(sed -ne "/^\s*cmake_minimum_required/I{s/.*\(\.\.\.*\|\s\)\([0-9][0-9.]*\)\([)]\|\s\).*$/\2/p;q}" \ "${2}" 2>/dev/null \ ) if [[ -n ${ver} ]] && ver_test "${ver}" -lt "${1}"; then