Skip to content

Compiling from msbuild incorrectly uses target build tools for build scripts #1308

Closed
@dlon

Description

@dlon

The problem arises when running cargo build from within a VS project and targeting something other than the native arch (e.g., using msbuild.exe myproj.sln /p:Platform=otherarch). When cargo builds a build script, it uses the target tools (added to PATH by Visual Studio) instead of the host tools, which naturally fails.

This is a problem as of Rust 1.83 due to the following fix: #1201. That PR also contains some discussion about this issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    O-windowsWindows targets and toolchains

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions