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
#4265 CMake generator IS optional on Windows #4281
Conversation
- When arch is not declared and only os_build is available, both Linux and Macos can run CMake to generate a default build tool e.g. Makefiles. However, on Windows this is not true and raises an error. - This commit returns "MinGW Makefiles" for Windows when arch is not specified. Signed-off-by: Uilian Ries <uilianries@gmail.com>
why |
That's true, but if think about, both OSX Linux and MacOS have default outputs. Also, I agree with NMake and Unix Makefiles, but our most common case on Windows is MinGW Makefiles when MSVC is not listed. |
okay, need to fix the following and we're good:
|
Signed-off-by: Uilian Ries <uilianries@gmail.com>
Signed-off-by: Uilian Ries <uilianries@gmail.com>
Hi @uilianries! The |
@lasote Done I didn't find any information about default generators on Docs, so I omitted. |
I think we could add some words at https://docs.conan.io/en/latest/reference/build_helpers/cmake.html in the generators parameter. Explaining what is the detected generator depending on the settings etc. |
Agreed! I'll do it soon. |
Signed-off-by: Uilian Ries <uilianries@gmail.com>
"dummy.cpp": CPP_CONTENT}) | ||
client.run("create . lasote/testing -s os_build={}".format(os_build)) | ||
finally: | ||
self.assertNotIn("TypeError: argument of type 'NoneType' is not iterable", client.user_io.out) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
client.out also works
In theory these checks for error are not necessary, as client.run()
will raise in this cases.
Hi!
When arch is not declared and only os_build is available,
both Linux and Macos can run CMake to generate a default
build tool e.g. Makefiles. However, on Windows this is not
true and raises an error.
This commit returns "MinGW Makefiles" for Windows when arch
is not specified.
I've added unit tests to check on Windows, Linux and Macos.
Changelog: Fix: Fixes default CMake generator on Windows to use MinGW Makefiles.
Docs: conan-io/docs#1026
closes #4265
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.