Skip to content

Addressing vcpkg warning related to binary caching #253

@mcraveiro

Description

@mcraveiro

Hi,

Thanks very much for an extremely useful project, on which I rely on a daily basis. I just noticed that my builds started to show:

Additional packages (*) will be modified to complete this operation.
$VCPKG_BINARY_SOURCES: warning: The 'x-gha' binary caching backend has been removed. Consider using a NuGet-based binary caching provider instead, see extended documentation at https://learn.microsoft.com/vcpkg/users/binarycaching?WT.mc_id=vcpkg_inproduct_cli.
  on expression: clear;x-gha,readwrite

According to Grok, this is because:

The CMake/vcpkg warning about the x-gha binary caching backend indicates that you're using an outdated or removed binary caching method (x-gha, previously used for GitHub Actions). The warning suggests switching to a NuGet-based binary caching provider or another supported method. [...]

Is there a plan to support the nuget based binary caching by any chance?

Many thanks for your time.

Related issues:

Links

Grok Solution

  1. Remove or Update VCPKG_BINARY_SOURCES:
  • Check your vcpkg configuration for the VCPKG_BINARY_SOURCES environment variable or setting.
  • If set to clear;x-gha,readwrite, it’s using the deprecated x-gha backend.
  1. Modify vcpkg Configuration:

Option 1: Use NuGet-based Binary Caching:

  • Set up a NuGet-based cache as recommended. Create a vcpkg.json in your project root or modify the vcpkg triplet file.
  • Add to vcpkg.json:
{
    "name": "my-project",
    "version-string": "1.0.0",
    "builtin-baseline": "<commit-hash>",
    "binary-caching": {
        "method": "nuget",
        "source": "path/to/nuget/cache"
     }
}
  • Or set the environment variable:
    VCPKG_BINARY_SOURCES="clear;nuget,readwrite"

Install a NuGet client if needed and configure a local or remote NuGet cache (see [vcpkg binary caching docs]> (https://learn.microsoft.com/vcpkg/users/binarycaching)).
[...]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions