Skip to content

Conversation

peterjc123
Copy link
Collaborator

Fixes #38861 (comment).

  1. Error out if msvc env is activated but DISTUTILS_USE_SDK is not set.
  2. Attempt to activate msvc env before running ninja build

1. Error out if msvc env is activated but `DISTUTILS_USE_SDK` is not set.
2. Attempt to activate msvc env before running ninja build
@dr-ci
Copy link

dr-ci bot commented May 21, 2020

💊 CI failures summary and remediations

As of commit b0670df (more details on the Dr. CI page):


  • 1/1 failures possibly* introduced in this PR
    • 1/1 non-CircleCI failure(s)

ci.pytorch.org: 1 failed


This comment was automatically generated by Dr. CI (expand for details).Follow this link to opt-out of these comments for your Pull Requests.

Please report bugs/suggestions on the GitHub issue tracker or post in the (internal) Dr. CI Users group.

See how this bot performed.

This comment has been revised 4 times.

Copy link
Contributor

@ezyang ezyang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@peterjc123 I know this stuff is hard to test, but I guarantee you it will bitrot if we don't exercise this somehow in Windows CI

Copy link
Contributor

@facebook-github-bot facebook-github-bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ezyang is landing this pull request. If you are a Facebook employee, you can view this diff on Phabricator.

@peterjc123
Copy link
Collaborator Author

@ezyang I'll apply to the same logic to tools/build_pytorch_libs.py so that it will be easier to find out what's wrong there.

@facebook-github-bot
Copy link
Contributor

@ezyang merged this pull request in a40049f.

@peterjc123 peterjc123 deleted the better_handling_for_vc_env_when_compiling_cpp_extensions branch May 27, 2020 07:12
@gchanan
Copy link
Contributor

gchanan commented May 28, 2020

@peterjc123 is this fixing a regression (so we should add it to 1.5.1)? It doesn't seem like it, but I wanted to double check.

@peterjc123
Copy link
Collaborator Author

@gchanan Using ninja to build c++ extensions is added in v1.5.0 and this pr fixes the problem that users attempt to trigger a extension build without activating the VC environment, which is an allowed behavior in pre-v1.5.0 builds. So maybe it can be considered as a regression to some extent.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

MSVC compiler is not found when compiling CUDA extensions without ninja

6 participants