reframe-hpc / reframe

A powerful Python framework for writing and running portable regression tests and benchmarks for HPC systems.
https://reframe-hpc.readthedocs.org
BSD 3-Clause "New" or "Revised" License
214 stars 101 forks source link

[feat] Adding support for CMake + Ninja #3101

Open OliverPerks opened 7 months ago

OliverPerks commented 7 months ago

Previously the CMake config would just run 'make'. This commit runs 'cmake --build .' which enables you to specify different build systems within cmake. Specifically this is useful for Ninja, using the 'cmake -GNinja' flag. If no build system is set it will fall back to make.

jenkins-cscs commented 7 months ago

Can I test this patch?

vkarak commented 7 months ago

I think the unit tests should be updated (I expect them to fail). Another question: does this change require a specific/recent version of CMake that would otherwise make reframe's backend break for users with older version? We could add a build system variable to control whether to emit make or cmake --build in this case.

teojgo commented 4 months ago

This needs a little bit more thought. In particular, since we now assume that the build system is Make, all the options are passed to make verbatim. So if you pass the 'install' as an option the command will be make install. With the above syntax it would have to be changed to cmake --build . -t install -j <n> or cmake --build . -j -- install.