Re: [gentoo-dev] [PATCH] cmake.eclass: Fix MYCMAKEARGS breakage with >=dev-util/cmake-3.23
On Wed, Feb 16, 2022 at 05:21:29PM -0500, Ionen Wolkens wrote: > Better fix would've been to remove the quotes I think, so that it > splits arguments and doesn't pass a literal empty "" string. Although I guess it is a behavior change, so may prefer to wait for EAPI change. ..but given ebuilds relying on this is a bug, I think that'd be the ebuild's own problem and there's no need to care about it. -- ionen signature.asc Description: PGP signature
Re: [gentoo-dev] [PATCH] cmake.eclass: Fix MYCMAKEARGS breakage with >=dev-util/cmake-3.23
On Wed, Feb 16, 2022 at 06:58:20PM +0100, Andreas Sturmlechner wrote: > I'm not sure what this variable is about, but we gotta fix it. Mentioned this in the bug too, but it's like MYMESONARGS and EXTRA_ECONF. Not documented but it's still spread around by word of mouth and sometime used by devs too when asking users to try options ("does it work with MYCMAKEARGS=-DFIX emerge ...") Any ebuilds using it directly (e.g. pcsx2) is a bug. > ...and rather drop on next EAPI bump. May result in some annoyed users that will ask for it back, not that I think the use is that widespread unlike EXTRA_ECONF. > - "${MYCMAKEARGS}" > ) > > + if [[ -n ${MYCMAKEARGS} ]] ; then > + cmakeargs+=( "${MYCMAKEARGS}" ) > + fi > + Better fix would've been to remove the quotes I think, so that it splits arguments and doesn't pass a literal empty "" string. i.e. users could MYCMAKEARGS="-DARG1=yes -DARG2=no" through package.env -- ionen signature.asc Description: PGP signature
[gentoo-dev] [PATCH] cmake.eclass: Fix MYCMAKEARGS breakage with >=dev-util/cmake-3.23
I'm not sure what this variable is about, but we gotta fix it. ...and rather drop on next EAPI bump. Bug: https://bugs.gentoo.org/833100 Signed-off-by: Andreas Sturmlechner --- eclass/cmake.eclass | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/eclass/cmake.eclass b/eclass/cmake.eclass index 36f2621e19..64a2931898 100644 --- a/eclass/cmake.eclass +++ b/eclass/cmake.eclass @@ -593,9 +593,12 @@ cmake_src_configure() { "${mycmakeargs_local[@]}" -DCMAKE_BUILD_TYPE="${CMAKE_BUILD_TYPE}" -DCMAKE_TOOLCHAIN_FILE="${toolchain_file}" - "${MYCMAKEARGS}" ) + if [[ -n ${MYCMAKEARGS} ]] ; then + cmakeargs+=( "${MYCMAKEARGS}" ) + fi + if [[ -n "${CMAKE_EXTRA_CACHE_FILE}" ]] ; then cmakeargs+=( -C "${CMAKE_EXTRA_CACHE_FILE}" ) fi -- 2.35.1 signature.asc Description: This is a digitally signed message part.