Skip to content

Update vcpkg configuration, again#64874

Merged
kevingranade merged 1 commit intoCleverRaven:masterfrom
akrieger:transparent_aluminum
Apr 6, 2023
Merged

Update vcpkg configuration, again#64874
kevingranade merged 1 commit intoCleverRaven:masterfrom
akrieger:transparent_aluminum

Conversation

@akrieger
Copy link
Copy Markdown
Member

@akrieger akrieger commented Apr 5, 2023

Summary

None

Purpose of change

Another package has evaporated from the internet, prompting us to need to update vcpkg again. Coincidentally, the run-vcpkg action recently updated and now uses built-in vcpkg caching machinery for build caching instead of its ad-hoc mechanism. We should use that because it'll be more granular and let us share packages across all three Windows builds we do (cdda, object creator and cdda release). To successfully maintain a consistent cachekey, though, we need to install a consistent version of cmake (as the cmake version feeds into the cachekey for many packages).

Describe the solution

Use lukka/get-cmake for a consistent cmake in the builds. Update lukka/run-vcpkg to v11 (implicitly .1 now that it is setup to automatically enable vcpkg's builtin caching). Update the vcpkg commit hash to the minimum version v11 needs.

Describe alternatives you've considered

Testing

Pushed to my repo, got successful builds.
Pushed again to my repo, got some cache hits but not enough. Investigation showed it was due to a differing cmake version.
Pushed to my repo with get-cmake, cache keys were consistent again.

Additional context

Example inconsistent cache key output:
Workflow 1:

         [DEBUG] <abientries for vcpkg-cmake-config:x64-windows-static>
         [DEBUG]   cmake|3.26.2
         [DEBUG]   copyright|04b60f99a43bfd7fefdc8364b24aac704a2160cef969b75ba6a38b62dc4c4b70
         [DEBUG]   features|core
         [DEBUG]   portfile.cmake|832b34e63f5af41ad1b2e4aa79c5bfa507a005b120b51548e674accc706837d7
         [DEBUG]   ports.cmake|47a3510fcec56fae26f4fb082afd972a70a04e26efa73e2de69123139500f02d
         [DEBUG]   post_build_checks|2
         [DEBUG]   powershell|7.2.10
         [DEBUG]   triplet|x64-windows-static
         [DEBUG]   triplet_abi|970059e5d3062703dfb6c76d85edd3e4e131a15053dda64e3c633f1dc770c322-2b9f5a18de013332e7068fafe850651fd91434ba2a08aae552b8565a2236f81b-d8af9437be18a355155567aff5acd748ca04f5ff
         [DEBUG]   vcpkg-port-config.cmake|72bc3093337e633bdd19fe5d4dd1f38ca1918def49608d676a9c98c686d38b1e
         [DEBUG]   vcpkg.json|4ffbabc2feab69abd21267f57669ef5e404bcbfa5ab6d93234374d98f5ff1864
         [DEBUG]   vcpkg_cmake_config_fixup.cmake|f92905382d90e37fa2addd96becce31f5075175196b117de6dd997a4ac1d6d06
         [DEBUG]   vcpkg_list|f5de3ebcbc40a4db90622ade9aca918e2cf404dc0d91342fcde457d730e6fa29
         [DEBUG] </abientries>
         [DEBUG] Trying to hash D:\a\Cataclysm-DDA\b\vcpkg\buildtrees\vcpkg-cmake-config\x64-windows-static.vcpkg_abi_info.txt
         [DEBUG] D:\a\Cataclysm-DDA\b\vcpkg\buildtrees\vcpkg-cmake-config\x64-windows-static.vcpkg_abi_info.txt has hash 4322594241aaee227c8b37b054dabc2b7e72226f698a6cff360dfd1739b99539

Workflow 2:

         [DEBUG] <abientries for vcpkg-cmake-config:x64-windows-static>
         [DEBUG]   cmake|3.26.1
         [DEBUG]   copyright|04b60f99a43bfd7fefdc8364b24aac704a2160cef969b75ba6a38b62dc4c4b70
         [DEBUG]   features|core
         [DEBUG]   portfile.cmake|832b34e63f5af41ad1b2e4aa79c5bfa507a005b120b51548e674accc706837d7
         [DEBUG]   ports.cmake|47a3510fcec56fae26f4fb082afd972a70a04e26efa73e2de69123139500f02d
         [DEBUG]   post_build_checks|2
         [DEBUG]   powershell|7.2.10
         [DEBUG]   triplet|x64-windows-static
         [DEBUG]   triplet_abi|970059e5d3062703dfb6c76d85edd3e4e131a15053dda64e3c633f1dc770c322-2b9f5a18de013332e7068fafe850651fd91434ba2a08aae552b8565a2236f81b-d8af9437be18a355155567aff5acd748ca04f5ff
         [DEBUG]   vcpkg-port-config.cmake|72bc3093337e633bdd19fe5d4dd1f38ca1918def49608d676a9c98c686d38b1e
         [DEBUG]   vcpkg.json|4ffbabc2feab69abd21267f57669ef5e404bcbfa5ab6d93234374d98f5ff1864
         [DEBUG]   vcpkg_cmake_config_fixup.cmake|f92905382d90e37fa2addd96becce31f5075175196b117de6dd997a4ac1d6d06
         [DEBUG]   vcpkg_list|f5de3ebcbc40a4db90622ade9aca918e2cf404dc0d91342fcde457d730e6fa29
         [DEBUG] </abientries>
         [DEBUG] Trying to hash D:\a\Cataclysm-DDA\b\vcpkg\buildtrees\vcpkg-cmake-config\x64-windows-static.vcpkg_abi_info.txt
         [DEBUG] D:\a\Cataclysm-DDA\b\vcpkg\buildtrees\vcpkg-cmake-config\x64-windows-static.vcpkg_abi_info.txt has hash 36facd654b73ffd6ae67d9f5cfee5dddd61f93509a61a31d499a734e643a3d29

@github-actions github-actions bot added <Documentation> Design documents, internal info, guides and help. [JSON] Changes (can be) made in JSON [Markdown] Markdown issues and PRs Code: Tooling Tooling that is not part of the main game but is part of the repo. json-styled JSON lint passed, label assigned by github actions astyled astyled PR, label is assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions labels Apr 5, 2023
@kevingranade kevingranade merged commit d0e1db5 into CleverRaven:master Apr 6, 2023
@akrieger akrieger deleted the transparent_aluminum branch September 10, 2023 05:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

astyled astyled PR, label is assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions Code: Tooling Tooling that is not part of the main game but is part of the repo. <Documentation> Design documents, internal info, guides and help. [JSON] Changes (can be) made in JSON json-styled JSON lint passed, label assigned by github actions [Markdown] Markdown issues and PRs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants