* [gentoo-dev] [PATCH] cmake.eclass: Fix MYCMAKEARGS breakage with >=dev-util/cmake-3.23
@ 2022-02-16 17:58 Andreas Sturmlechner
2022-02-16 22:21 ` Ionen Wolkens
0 siblings, 1 reply; 3+ messages in thread
From: Andreas Sturmlechner @ 2022-02-16 17:58 UTC (permalink / raw
To: gentoo-dev
[-- Attachment #1: Type: text/plain, Size: 805 bytes --]
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 <asturm@gentoo.org>
---
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
[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 618 bytes --]
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [gentoo-dev] [PATCH] cmake.eclass: Fix MYCMAKEARGS breakage with >=dev-util/cmake-3.23
2022-02-16 17:58 [gentoo-dev] [PATCH] cmake.eclass: Fix MYCMAKEARGS breakage with >=dev-util/cmake-3.23 Andreas Sturmlechner
@ 2022-02-16 22:21 ` Ionen Wolkens
2022-02-16 22:27 ` Ionen Wolkens
0 siblings, 1 reply; 3+ messages in thread
From: Ionen Wolkens @ 2022-02-16 22:21 UTC (permalink / raw
To: gentoo-dev
[-- Attachment #1: Type: text/plain, Size: 966 bytes --]
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
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2022-02-16 22:27 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-02-16 17:58 [gentoo-dev] [PATCH] cmake.eclass: Fix MYCMAKEARGS breakage with >=dev-util/cmake-3.23 Andreas Sturmlechner
2022-02-16 22:21 ` Ionen Wolkens
2022-02-16 22:27 ` Ionen Wolkens
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox