Bug 174383 - Make it possible to add custom targets to buildsets
Summary: Make it possible to add custom targets to buildsets
Status: CONFIRMED
Alias: None
Product: kdevelop
Classification: Applications
Component: Build tools: CMake (show other bugs)
Version: unspecified
Platform: Compiled Sources Linux
: NOR wishlist
Target Milestone: ---
Assignee: kdevelop-bugs-null
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-11-05 22:42 UTC by Thomas McGuire
Modified: 2015-02-20 10:16 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 Thomas McGuire 2008-11-05 22:42:54 UTC
Version:            (using Devel)
OS:                Linux
Installed from:    Compiled sources

The "buildset" feature of the project sidebar is a neat feature.
However, currently one can only add targets that are shown in the project tree.
I would like to add custom make targets there.
To be specific, I would use that for the target kmailprivate/fast, which I would like to use instead of the full KMail target. (CMake generates /fast targets, which don't do dependency checking and are therefore faster to build).
Comment 1 Andreas Pakulat 2008-11-06 03:04:46 UTC
Ok, so whats your preference:

a) close this as wontfix, because only custom makefile support can know the special targets in the Makefile (at some point in the future, because I think it doesn't work right now)

b) assign this to cmake plugin and re-declare it as "add auto-generated useful targets into the project tree".

The system doesn't allow to build something thats not available in the project tree.

Of course (once it works again) you can always setup a run-target for your special use-case.
Comment 2 Thomas McGuire 2008-11-06 15:24:13 UTC
> a) close this as wontfix, because only custom makefile support can know the special targets in the Makefile (at some point in the future, because I think it doesn't work right now)

That wouldn't be an option, since that sounds I wouldn't be able to use all the nice things of the CMake plugin, right?

> b) assign this to cmake plugin and re-declare it as "add auto-generated useful targets into the project tree".

That sounds good, although too many targets might clutter the project tree. I'm not sure if it is best to always add them or add options to hide/show those targets. I'll leave that to you to decide.
Comment 3 Andreas Pakulat 2008-11-06 15:47:13 UTC
Hmm, seems bugzilla doesn't allow to change the title of a bugreport, so I'll just re-assign to cmake support and add the comments here:

Having those fast-targets available inside the project tree is indeed not very useful. A better idea may be to just have a switch somewhere/somehow to switch between building the normal or the /fast target - for any target item.

CMake support can automatically create an intermediate item to pass to the builder for building the /fast version. As this is cmake specific a project-config option from cmake support that allows to say "I always want to build the /fast targets" would be a good start I guess.
Comment 4 David Nolden 2008-11-06 15:52:39 UTC
Imo we should still allow inserting arbitrary sell-commands into the build-set..
Comment 5 Thomas McGuire 2009-02-13 00:53:21 UTC
This is how I envision the UI for it:
The context menu of a target (or, if that is not possible, of a directory where the CMakeLists.txt is in) in the project sidebar would have an entry "Add special target to buildset...". That would open a dialog, showing all special targets (like foo/fast, install, clean, install/fast and whatnot) in a listview, with a search line.

Selecting an item from that listview would then add it to the buildset.
Comment 6 Cyrille Berger 2015-02-20 08:44:20 UTC
It would also be useful to be able to select install (and clean?) as targets (currently I have been using the "default target" of the project settings as a workaround).