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

[bugfix] msvc in legacy cmake generators #10195

Merged
merged 2 commits into from Dec 20, 2021

Conversation

franramirez688
Copy link
Contributor

@franramirez688 franramirez688 commented Dec 17, 2021

Changelog: Bugfix: Compiler msvc was not working for CMake legacy generators.
Docs: omit

Closes: #10185

  • Refer to the issue that supports this Pull Request.
  • If the issue has missing info, explain the purpose/use case/pain/need that covers this Pull Request.
  • I've read the Contributing guide.
  • I've followed the PEP8 style guides for Python code.
  • I've opened another PR in the Conan docs repo to the develop branch, documenting this one.

Note: By default this PR will skip the slower tests and will use a limited set of python versions. Check here how to increase the testing level by writing some tags in the current PR body text.

@franramirez688 franramirez688 requested review from jgsogo, memsharded, czoido and lasote and removed request for jgsogo December 17, 2021 15:43
@franramirez688
Copy link
Contributor Author

franramirez688 commented Dec 17, 2021

TODO: one functional test with msvc compiler

UPDATE: Done

@memsharded memsharded added this to the 1.43.2 milestone Dec 17, 2021
@SSE4
Copy link
Contributor

SSE4 commented Dec 20, 2021

I think it's okay if the legacy generator doesn't support a new compiler, as we discussed in #9370. they are going to die very soon anyway.

@lasote
Copy link
Contributor

lasote commented Dec 20, 2021

The problem is with conan-center, before introducing the new generators we are breaking every recipe just because we now detect the msvc instead of Visual Studio, we want to push the migration, but not too much, this is a trade-off, and the fix is quite easy.

@lasote lasote merged commit b8cbf28 into conan-io:release/1.43 Dec 20, 2021
@LeeRuns
Copy link

LeeRuns commented Feb 20, 2022

PLEASE explain how we are supposed to build a project today in a stable way with vs2022.
For those of us who use this platform, we cannot just wait for 2.0 to release

@memsharded
Copy link
Member

@LeeRuns please check the release notes, this was fixed in #10457 for 1.45, it is now detecting by default Visual Studio instead msvc.

And in any case, using the automatically detected profiles is not recommended for production, but using your own profile, which can define compiler="Visual Studio"

@LeeRuns
Copy link

LeeRuns commented Feb 21, 2022 via email

@memsharded
Copy link
Member

@LeeRuns the modern integrations require very little configuration. Basically this works:

$ conan new hello/0.1 --template=cmake_lib
$ conan create . -c tools.cmake.cmaketoolchain:generator=Ninja

This builds with Visual Studio and Ninja generator, both the package and the consumer project inside the test_package folder.

@LeeRuns
Copy link

LeeRuns commented Feb 23, 2022 via email

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

Successfully merging this pull request may close these issues.

None yet

6 participants