-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Handling of CMake _buildPresets_ #7
Comments
Just a clarification, the preset the the user currently chooses is the "configure preset". Then, when building, it's assumed that a "build preset" with the same name exists. One possibility is to check in
We can also not use build presets until we can think about a good way to do it. Right now assuming that there exists a build preset with the same name of the configure preset when configure presets are used is an unnecessary limitation. |
As I suggested earlier, I would completely separate normal builds from preset builds by using two separate commands. The last configure preset could then still be used for normal builds as an easier way to select the binaryDir (instead of manually setting But buildPresets would be handled independent from the configurePresets (maybe, when selecting a buildPreset which doesn't have a binaryDir, it could get generated automatically by first calling Footnotes
|
Build presets can also set things like the number of parallel jobs (for make generator), environments variables, a target name (so that you do not need to specify it) and a few other things. But the most important information, including From the documentation for build presets, they either need to have a
We can use configure presets without using any build presets, bit it seems that if we want to use build presets we also need to use configure presets, since each build preset needs to have an associated configure preset somehow (directly of by inheriting from another preset). I agree that the user should still be able to choose them separately (instead of assuming you have both kinds of presets and they have the same name), as well as being able to use only configure presets. |
Before merging #4 (s. issue #3 for details) cmake-integration.el used buildPresets to
After the merge, the way multi-config targets are handled has changed. In 2. the buildPreset configuration is now ignored (it gets overruled with the config selected by the user via the completion interface). That could easily be fixed by updating
cmake-integration-get-cmake-targets-from-codemodel-json-file
to add an additional config-less target for each target name. I.e.:These additional targets would then automatically build the
And I would probably also add a new command in addition to `cmake-integration-save-and-compile` where the completion list just offers the configured _buildPresets_. E.g. rename `cmake-integration-save-and-compile` to `cmake-integration-build-target` and add `cmake-integration-build-preset`.
What do you think?
The text was updated successfully, but these errors were encountered: