git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [RFH] CMake: detect if being run via Visual Studio, independent of build generator?

From
Philip Oakley <philipoakley@iee.email>
Date
May 30, 2021, 10:52 UTC
Message-ID
<953d685c-3c89-7377-ed49-b79fb4e0acb5@iee.email>
In-Reply-To
<CAOjrSZtRH-sqh8RJm3W00dUWTbT-xcpzDWCQFt=3CNaVnOyVWQ@mail.gmail.com>

quick thoughts.. On 30/05/2021 01:14, Matt Rogers wrote:

> (resending because client reconfigured to not use plaintext)
;-)
>
> Reading through the documentation, Visual Studio seems to support
> CmakePresets.json [1]

Is that stored with the project, or with the VS installation (still to read [1] beyond a v quick scan..)

>  for handling configuration of cmake options.  It
> might be worth it to keep the defaults as is.

Given that it's just changed, do you mean ' keep it as new - Ninja' or 'keep it as old - VS generator'..

Show 6 quoted lines
>  But provide a variable
> for forcing vcpkg and a CMakePresets.json for Visual Studio
> (and other such tools) to use.
>
> This is nice since Visual Studio users wouldn't need to rely on the
> slower Visual Studio * generators to run their builds, 
[implies, keep as Ninja, I think ?]
> while leaving
> non Visual Studio users still able to easily run builds.  So maybe there's
> a way for everyone to be happy?

I'm hoping to ensure the project builds 'straight out of the tin' [mixed metaphor 2,3], for those who are cross disciplinary (such as myself;-)

I'll have a good look at [1], thanks.
Philip
>
> 1: https://devblogs.microsoft.com/cppblog/cmake-presets-integration-in-visual-studio-and-visual-studio-code/
>

[2] https://en.wikipedia.org/wiki/Out_of_the_box_(feature) [3] https://www.ronseal.com/the-ronseal-phrase/ (UK)

Previous: Matt RogersNext: Matt Rogers
Message 8 of 14 in “[RFH] CMake: detect if being run via Visual Studio, independent of build generator?”
  1. Philip OakleyMay 29, 2021
  2. Matt RogersMay 29, 2021
  3. Philip OakleyMay 29, 2021
  4. Sibi SiddharthanMay 29, 2021
  5. Philip OakleyMay 29, 2021
  6. Sibi SiddharthanMay 29, 2021
  7. Matt RogersMay 30, 2021
  8. Philip OakleyMay 30, 2021
  9. Matt RogersMay 30, 2021
  10. Sibi SiddharthanMay 30, 2021
  11. Philip OakleyMay 30, 2021
  12. Philip OakleyMay 30, 2021
  13. Matt RogersMay 31, 2021
  14. Philip OakleyMay 31, 2021

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.