Skip to content

[vcpkg scripts] Use vcpkg fetch for available tools#43309

Merged
BillyONeal merged 7 commits intomicrosoft:masterfrom
Neumann-A:ninja_from_vcpkg_fetch
Dec 19, 2025
Merged

[vcpkg scripts] Use vcpkg fetch for available tools#43309
BillyONeal merged 7 commits intomicrosoft:masterfrom
Neumann-A:ninja_from_vcpkg_fetch

Conversation

@Neumann-A
Copy link
Copy Markdown
Contributor

No description provided.

@JonLiu1993 JonLiu1993 changed the title Use ninja from vcpkg fetch [vcpkg scripts] Use ninja from vcpkg fetch Jan 17, 2025
@JonLiu1993 JonLiu1993 added the category:tool-update The issue is with build tool or build script, which requires update or should be executed correctly label Jan 17, 2025
@Neumann-A
Copy link
Copy Markdown
Contributor Author

@JonLiu1993: Please mark this as reviewed so that we can get a review from the ms team.

@JonLiu1993 JonLiu1993 added the info:needs-maintainer-attention Lets the current 'on rotation' vcpkg maintainer know they need to look at this. label Feb 5, 2025
@Neumann-A Neumann-A changed the title [vcpkg scripts] Use ninja from vcpkg fetch [vcpkg scripts] Use vcpkg fetch for available tools Feb 6, 2025
@BillyONeal
Copy link
Copy Markdown
Member

@JavierMatosD @AugP @vicroms @ras0219-msft and I discussed today.

We are happy with the direction of the 4 tools in Billy's original list being changed to use fetch.

We observe that some tools in Billy's original 'unsafe' list might be OK to go through fetch, in particular assemblers like nasm or yasm. However, fetch doesn't already know about those tools, so the value in attempting to make a change like this in support of them is probably not worth it, so we aren't interested in going there right now.

@JonLiu1993 JonLiu1993 removed the info:needs-maintainer-attention Lets the current 'on rotation' vcpkg maintainer know they need to look at this. label Feb 7, 2025
@Neumann-A
Copy link
Copy Markdown
Contributor Author

list might be OK to go through fetch, in particular assemblers like nasm or yasm

Wouldn't this break the abi hash if the codegen is different for whatever reason between versions

@Neumann-A
Copy link
Copy Markdown
Contributor Author

Neumann-A commented Feb 7, 2025

@BillyONeal:

Any Idea:

CMake Error at scripts/test_ports/vcpkg-find-acquire-program/portfile.cmake:66 (message):
  The following programs do not exist:

     NUGET:  trying authoritative source https://dist.nuget.org/win-x86-commandline/v6.10.0/nuget.exe

  Successfully downloaded 71d7307b-nuget.exe, storing to
  https://vcpkgassetcachewus.blob.core.windows.net/cache/71d7307bb89de2df3811419c561efa00618a4c68e6ce481b0bdfc94c7c6c6d126a54eb26a0015686fabf99f109744ca41fead99e97139cdc86dde16a5ec3e7cf?***
  SECRET ***

  Store success

  D:\downloads\tools\nuget-6.10.0-windows\nuget.exe

     NUGET (interpreter): A suitable version of nuget was not found (required v6.10.0).

  Trying to download 71d7307b-nuget.exe using asset cache
  https://vcpkgassetcachewus.blob.core.windows.net/cache/71d7307bb89de2df3811419c561efa00618a4c68e6ce481b0bdfc94c7c6c6d126a54eb26a0015686fabf99f109744ca41fead99e97139cdc86dde16a5ec3e7cf?***
  SECRET ***

  Asset cache miss
Call Stack (most recent call first):
  scripts/ports.cmake:196 (include)

The rest looks like baseline regression

@BillyONeal
Copy link
Copy Markdown
Member

Wouldn't this break the abi hash if the codegen is different for whatever reason between versions

The assumption is that an assembler would not do that. To be clear, I'm not saying we should, I just wanted what was said to be recorded should this topic ever come up again.

@BillyONeal
Copy link
Copy Markdown
Member

@BillyONeal:

Any Idea:

This looks like something tried to set the entire vcpkg console output as the path to nuget.exe, including status explanations of what we are doing and why.

I observe that many of our existing uses of fetch run it more than once to try to avoid this happening, there might be tool bugs that need to be tackled here.

@BillyONeal
Copy link
Copy Markdown
Member

Pushed merge to pick up #43509 as the macs in the old pool are being shut down.

@Neumann-A Neumann-A marked this pull request as draft February 14, 2025 14:49
@Neumann-A
Copy link
Copy Markdown
Contributor Author

convert to draft until fetch only outputs the result to stdout (requires vcpkg-tool change)

BillyONeal added a commit to BillyONeal/vcpkg-tool that referenced this pull request Oct 8, 2025
* Fixes the incorrect tracking bug introduced here: https://github.com/microsoft/vcpkg-tool/pull/1715/files#r2414987620
* Gets clean_prepare_dir and the last_write_time fixup into the parallelized region
* Deletes decompress_in_parallel / cmd_execute_and_capture_output_parallel related to microsoft/vcpkg#43309
BillyONeal added a commit to BillyONeal/vcpkg-tool that referenced this pull request Oct 8, 2025
* Fixes the incorrect tracking bug introduced here: https://github.com/microsoft/vcpkg-tool/pull/1715/files#r2414987620
* Gets clean_prepare_dir and the last_write_time fixup into the parallelized region

Related to microsoft/vcpkg#43309

* Plumbs error handling through to one place
* Deletes decompress_in_parallel / cmd_execute_and_capture_output_parallel
BillyONeal added a commit to microsoft/vcpkg-tool that referenced this pull request Oct 9, 2025
* Fixes the incorrect tracking bug introduced here: https://github.com/microsoft/vcpkg-tool/pull/1715/files#r2414987620
* Gets clean_prepare_dir and the last_write_time fixup into the parallelized region

Related to microsoft/vcpkg#43309

* Plumbs error handling through to one place
* Deletes decompress_in_parallel / cmd_execute_and_capture_output_parallel
vicroms pushed a commit to vicroms/vcpkg-tool that referenced this pull request Oct 9, 2025
…1805)

* Fixes the incorrect tracking bug introduced here: https://github.com/microsoft/vcpkg-tool/pull/1715/files#r2414987620
* Gets clean_prepare_dir and the last_write_time fixup into the parallelized region

Related to microsoft/vcpkg#43309

* Plumbs error handling through to one place
* Deletes decompress_in_parallel / cmd_execute_and_capture_output_parallel
BillyONeal added a commit to BillyONeal/vcpkg-tool that referenced this pull request Nov 11, 2025
…cture.

Unblocks microsoft/vcpkg#43309 by making --x-stderr-status actually work to `vcpkg fetch`
# Conflicts:
#	scripts/cmake/vcpkg_find_acquire_program(NINJA).cmake
#	scripts/cmake/vcpkg_find_acquire_program(NUGET).cmake
@BillyONeal BillyONeal removed the category:tool-update The issue is with build tool or build script, which requires update or should be executed correctly label Dec 17, 2025
@BillyONeal BillyONeal marked this pull request as ready for review December 17, 2025 21:29
@BillyONeal BillyONeal merged commit 29647bb into microsoft:master Dec 19, 2025
17 checks passed
@AenBleidd
Copy link
Copy Markdown
Contributor

Ok, now on OSX (Github actions runner image) I have a wonderful build error:

CMake Error: CMake was unable to find a build program corresponding to "Ninja".  CMAKE_MAKE_PROGRAM is not set.  You probably need to select a different build tool.

but the image itself states it has Ninja installed: https://github.com/actions/runner-images/blob/main/images/macos/macos-15-arm64-Readme.md#utilities

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.

7 participants