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 A1FF915800A for ; Mon, 19 May 2025 18:59:25 +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 server-signature RSA-PSS (4096 bits)) (No client certificate requested) (Authenticated sender: relay-lists.gentoo.org@gentoo.org) by smtp.gentoo.org (Postfix) with ESMTPSA id 8C80B343157 for ; Mon, 19 May 2025 18:59:25 +0000 (UTC) Received: from bobolink.gentoo.org (localhost [127.0.0.1]) by bobolink.gentoo.org (Postfix) with ESMTP id 2801B1104A8; Mon, 19 May 2025 18:58:42 +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 bobolink.gentoo.org (Postfix) with ESMTPS id 6808F1103DD for ; Mon, 19 May 2025 18:58:41 +0000 (UTC) Received: from tuxbrain.fritz.box (unknown [IPv6:2a04:9546:191d:b501:676c:7b0c:c3fa:aa8e]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: asturm) by smtp.gentoo.org (Postfix) with ESMTPSA id 33EEA34305B; Mon, 19 May 2025 18:58:40 +0000 (UTC) From: Andreas Sturmlechner To: gentoo-dev@lists.gentoo.org, kde@gentoo.org, base-system@gentoo.org Cc: =?UTF-8?B?TWljaGHFgiBHw7Nybnk=?= Subject: Re: [gentoo-dev] [PATCH v2 1/3] cmake.eclass: Add recursive CMakeLists.txt unsupported version detection Date: Mon, 19 May 2025 20:58:36 +0200 Message-ID: <22709973.EfDdHjke4D@tuxbrain.fritz.box> In-Reply-To: <4c331af88b5ec74a6971fb2942fd7fbcdd5409a2.camel@gentoo.org> References: <12677532.O9o76ZdvQC@tuxbrain.fritz.box> <6166619.lOV4Wx5bFT@tuxbrain.fritz.box> <4c331af88b5ec74a6971fb2942fd7fbcdd5409a2.camel@gentoo.org> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@lists.gentoo.org Reply-to: gentoo-dev@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart7814963.EvYhyI6sBW"; micalg="pgp-sha512"; protocol="application/pgp-signature" X-Archives-Salt: 229c6ec9-f2dc-4ee5-979b-2dc3d8e195b2 X-Archives-Hash: 1a6dc3f334a7aa6e467a2194ade648e4 --nextPart7814963.EvYhyI6sBW Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8"; protected-headers="v1" From: Andreas Sturmlechner Cc: =?UTF-8?B?TWljaGHFgiBHw7Nybnk=?= Date: Mon, 19 May 2025 20:58:36 +0200 Message-ID: <22709973.EfDdHjke4D@tuxbrain.fritz.box> MIME-Version: 1.0 On Montag, 19. Mai 2025 20:51:49 Mitteleurop=C3=A4ische Sommerzeit Micha=C5= =82 G=C3=B3rny=20 wrote: > > --- a/eclass/cmake.eclass > > +++ b/eclass/cmake.eclass > > @@ -362,6 +362,18 @@ cmake_src_configure() { > >=20 > > # Fix xdg collision with sandbox > > xdg_environment_reset > >=20 > > + local file re=3D"cmake_minimum_required *\( *VERSION( .*\.\.\.| > > )(([[:digit:]]+)\.([[:digit:]]+))" + local ver cmreq_isold > > + while read -d '' -r file ; do > > + [[ $(grep -hi "cmake_minimum_required" "$file") =3D~ $re ]] > > + ver=3D"${BASH_REMATCH[2]}" >=20 > So... you're using grep to find a line containing > "cmake_minimum_required", then applying another regexp to that line? > This really looks like a case for a single sed call. I'm glad for any suggestions there. >=20 > > + echo $file $ver >=20 > Is this leftover debug? Indeed, thanks. PR is here: https://github.com/gentoo/kde/pull/1043 Regards --nextPart7814963.EvYhyI6sBW Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part. Content-Transfer-Encoding: 7Bit -----BEGIN PGP SIGNATURE----- iQITBAABCgB9FiEEmaksxp6GvcraXyZQrlkbvHPk3V4FAmgrf1xfFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDk5 QTkyQ0M2OUU4NkJEQ0FEQTVGMjY1MEFFNTkxQkJDNzNFNERENUUACgkQrlkbvHPk 3V4RVwwAmKAfvjkgikY5kEEiuTegDeb2vafCxh1pEkl7lFwlAMFYNuXaP+Rwm2Oa bi0TNIFkwyjimj3N/czJqOy9QTvpuTi1pkGlhbB8wu4mhxM+GCZt34MbcLVJgt57 w64ACmCX4lgQUeOjuE3GagBomp/5KlbOsRYzYlKTF7udK6CSni0LV+/dvXJJAT09 nORCLi0zJ4CxqxdzsOrgsxRRtaPVsW6xpl0SxkNWWLR6l8+7CS5fWJO94/wReuIM ANSt+eHztidxuw7VN7CkukDSLwvNhcwsc2C9M30JVQC9Xubqum4UtOiJDaq5KA4i EYXy1onAGLXCfqZV3Xl2ADHekImRf/j+GnHwgYa6wqBZ3nFVGOZVPCMn7bT5zkld cQB8dabrILbH2S0ttmAlk0cNbR1FifBneQ3RK1yyiiJUaNe21BGShC5qB+4w273h PtJQn0LzRvN7t/U+muTdxW/OPNV7M5VoYBhs0QZSijtJYRAqoGhITGM/Mml8PPmf 7oXm2IbV =rct7 -----END PGP SIGNATURE----- --nextPart7814963.EvYhyI6sBW--