Reputation: 131
I am trying to use Ninja + CMake to build a project.
This project has a custom target that takes additional arguments.
E.g. make target option=value
It works fine in make
, however I am not sure how to get Ninja to take in additional command line arguments.
Is this possible with a Ninja build?
Upvotes: 4
Views: 5040
Reputation: 2403
I don't think it's possible to do directly through Ninja. I just scanned through the Ninja documentation to double check and didn't see anything.
Instead, you could modify CMake cache variables via CMake (see cmake -D
and cmake -L
). That way you could change your build on the fly, or create a few different build directories with different settings in each one.
Upvotes: 3