Bug 297928 - RFE: add ninja support
Summary: RFE: add ninja support
Status: RESOLVED FIXED
Alias: None
Product: kdevelop
Classification: Applications
Component: Build tools: Ninja (show other bugs)
Version: 4.3.0
Platform: Fedora RPMs Linux
: NOR wishlist
Target Milestone: 4.3.0
Assignee: kdevelop-bugs-null
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-04-11 20:44 UTC by Matthew Woehlke
Modified: 2017-02-16 11:08 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Matthew Woehlke 2012-04-11 20:44:02 UTC
It would be great if kdevelop properly supported the ninja (http://martine.github.com/ninja) build tool.

It seems like support shouldn't be hard, as ninja is mostly like make, except that:

a. building subtargets must be done by giving the name of a subtarget rather than descending into a subdirectory.

b. '-k' needs to be '-k <num>, where <num> is the number of errors to permit (INT_MAX is probably best until/unless modifying the GUI to allow a number to be specified).

Right now I am using ninja by telling kdevelop that the 'make' binary is spelled 'ninja', which works well enough for top-level builds, but has no subtarget support.
Comment 1 Milian Wolff 2012-04-17 09:19:09 UTC
since none of us developers use that yet, you should probably try to patch kdevelop yourself and send the patch to git.reviewboard.kde.org to get it in. otherwise you'll potentially have to wait quite a long time - just saying.

cheers
Comment 3 Matthew Woehlke 2013-04-18 20:54:37 UTC
Er... yes and no. When will this be either part of the official release or at least picked up and packaged by distributions?

I'm not sure "...only if you build from source" qualifies as "fixed".
Comment 4 Matthew Woehlke 2013-04-18 20:58:31 UTC
...and looking closer at that, it is impossible to package, as there are no release tarballs and kde.org does not (or not that I could figure out, anyway) provide git archive tarballs.

Thus, it is not usable except by manually checking out the source code, which is not suitable for end users. Thus, not fixed.
Comment 5 Michael G. Hansen 2013-06-12 18:54:47 UTC
KDevelop 4.5 contains a setting to use ninja build instead of make under "Configure KDevelop"->CMake, so I guess the plugin is no longer needed?

Would be nice if the build system could be set for each project instead of being a global setting, because then you can gradually change to ninja without having to re-compile all projects at once. Also, exiv2 for example does not build with ninja on my system.

The per-project build configuration also has no "Make" tab anymore when using ninja, and the "Make" tab was also used to set things like the number of threads.
Comment 6 Aleix Pol 2013-06-13 12:34:29 UTC
That setting is only for newly generated build directories. When you decide to use ninja, but you have a make build directory configured, make is used.

Also there's a ninja project configuration tab, but we don't support specifying the number of jobs in ninja, I considered it not very useful.

In any case, this is a different thing than what the bug report so please open a new one if you think there are more things to discuss
Comment 7 Matthew Woehlke 2014-01-24 23:18:24 UTC
I'm going to close this as ninja support is integrated now... If anyone objects, squawk and I can re-open it.