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

fixbug: for cases when WindowsSDKVersion variable is not available #5411

Merged
merged 2 commits into from
Jul 31, 2024

Conversation

jinke18
Copy link
Contributor

@jinke18 jinke18 commented Jul 29, 2024

find_vstudio.lua

for some cases, the variable WindowsSDKVersion is not available from vcvarsall.bat, i parse it from WindowsSdkBinPath, such as: C:\\Program Files (x86)\\Windows Kits\\8.1\\bin.

@jinke18
Copy link
Contributor Author

jinke18 commented Jul 29, 2024

see #5388

-- then parse it from `WindowsSdkBinPath`, such as: `C:\\Program Files (x86)\\Windows Kits\\8.1\\bin`
local WindowsSdkBinPath = variables["WindowsSdkBinPath"]
if WindowsSdkBinPath then
WindowsSDKVersion = string.match(WindowsSdkBinPath, "\\(%d+%.?%d*)\\bin")
Copy link
Member

@waruqi waruqi Jul 29, 2024

Choose a reason for hiding this comment

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

I think %d+%.%d+ will be better. and add $ behind bin. bin$

@waruqi waruqi added this to the v2.9.4 milestone Jul 30, 2024
@waruqi waruqi merged commit cc2a7d0 into xmake-io:dev Jul 31, 2024
19 checks passed
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

2 participants