Skip to content
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

[feature] include CMAKE_<LANG>_COMPILER in generated CMakePresets.json #17543

Open
1 task done
melak47 opened this issue Dec 31, 2024 · 0 comments
Open
1 task done

[feature] include CMAKE_<LANG>_COMPILER in generated CMakePresets.json #17543

melak47 opened this issue Dec 31, 2024 · 0 comments

Comments

@melak47
Copy link
Contributor

melak47 commented Dec 31, 2024

What is your suggestion?

Currently, VSCode's cmake-tools extension seems to check for "CMAKE_<C/CXX>_COMPILER": "cl" being present in the preset to determine if it should set up the vcvars environment for your build tasks.

When using the CMakeDeps + CMakeToolchain generators (with the Ninja CMake generator),
the preset generated by conan does not set those cache variables (because they are set in the toolchain file).

As a result, cmake-tools does not set up the environment, meaning you have to activate the environment manually before starting VSCode, or write another preset inheriting from the conan generated preset to add the variables.

I was wondering if these variables could just be included in the preset to avoid this?

Have you read the CONTRIBUTING guide?

  • I've read the CONTRIBUTING guide
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant