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

vcvars regression #3918

Merged
merged 2 commits into from Nov 8, 2018
Merged

Conversation

@memsharded
Copy link
Member

@memsharded memsharded commented Nov 6, 2018

Changelog: Fix: Fix regression introduced in 1.7, setting amd64_x86 when no arch_build is defined.

  • Refer to the issue that supports this Pull Request.
    Close #3917

To pass CI, maybe a specific test that covers it is needed.

@ghost ghost assigned memsharded Nov 6, 2018
@ghost ghost added the stage: review label Nov 6, 2018
claasd
claasd approved these changes Nov 7, 2018
danimtb
danimtb approved these changes Nov 7, 2018
# Keep the VS default, which is x86 toolset
# This will probably be changed in conan 2.0
if ((settings.get_safe("arch_build") or
os.getenv("PreferredToolArchitecture") == "x64")
Copy link
Contributor

@lasote lasote Nov 7, 2018

PreferredToolArchitecture is not an env var normally, right? in that case, I would name it CONAN_PREFERRED_TOOL_ARCHITECTURE. And it has to be documented (and mentioned in the changelog)

Copy link
Member Author

@memsharded memsharded Nov 7, 2018

It seems that it is an env-var: https://developercommunity.visualstudio.com/comments/282434/view.html, but I fail to find more compelling evidence on how is it used.

From: https://msdn.microsoft.com/en-us/library/ee662426.aspx

The PreferredToolArchitecture property determines whether the 32-bit or 64-bit compiler and tools are used in the build. This property does not affect the output platform architecture or configuration. By default, MSBuild uses the x86 version of the compiler and tools if this property is not set, or is set to any value other than x64.

Set the PreferredToolArchitecture property to x64 to use the 64-bit compiler and tools to build your application.

msbuild myProject.vcxproj /p:PreferredToolArchitecture=x64

Copy link
Contributor

@lasote lasote Nov 7, 2018

ok then. I can't find it either, just people saying it works but no-official docs. Anyway this is ok.

lasote
lasote approved these changes Nov 7, 2018
@lasote lasote added this to the 1.9.1 milestone Nov 8, 2018
@lasote lasote merged commit 46ef0c5 into conan-io:release/1.9.1 Nov 8, 2018
2 checks passed
@ghost ghost removed the stage: review label Nov 8, 2018
@memsharded memsharded deleted the hotfix/vcvars_regression branch Nov 9, 2018
grisumbras pushed a commit to grisumbras/conan that referenced this issue Dec 27, 2018
* vcvars regression

* using env var PreferredToolArchitecture
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

4 participants