Dear everyone,

While gentoo-devhelp is a better place for questions, it's been inactive
for years so I sent an email here. Apologies if this is solely for gentoo
developers.

I'm writing an ebuild of ddnet, <http://github.com/ddnet/ddnet> a cmake
argument of which is "-GNinja" controlling the build system to be ninja or
make.  Naturally I decided to add a USE flag "ninja"

Part of my src_configure function is as below:

local mycmakeargs=(
        ......
        -DVULKAN=$(usex vulkan ON OFF)
)
use ninja && mycmakeargs+=( -GNinja )
cmake_src_configure

What confuses me is that portage seems to always use ninja to build, for
htop always indicates user portage is running ( ninja -v -j5 ), whenever
USE=ninja is enabled or disabled.

After trying to read cmake.eclass source code, I think separately denoting
ninja/make in src_compile and src_install might be possible. But
cmake_build still automatically detects the build type so I am confused.

My drafted ebuild file is attached below. It will be much appreciated if
anyone could help  :)


Best regards.

Attachment: ddnet-16.2.2.ebuild
Description: Binary data

Reply via email to