Skip to content

CI: Do not let vcpkg copy its DLLs next to the Windows test build - #9253

Merged
Esteban82 merged 2 commits into
masterfrom
fix-windows-applocal-deps
Oct 9, 2026
Merged

Esteban82 merged 2 commits into
masterfrom
fix-windows-applocal-deps

Conversation

@Esteban82

Copy link
Copy Markdown
Member

Attempt to fix the "Failure while closing GMT z shared library" error in the Windows tests.

Claude's:

The vcpkg toolchain runs vcpkg z-applocal after every add_library(), which copies its dependencies (hdf5, netcdf, libcurl, z, proj, ...) into build/src and build/src/plugins. Those DLLs are found through PATH anyway, so this passes -DVCPKG_APPLOCAL_DEPS=OFF in the Windows job of tests.yml, which keeps the plugin directory as in a regular build (only supplements).

It works if the error "Failure while closing GMT z shared library" no longer shows up in the log of the Windows job. This does not replace #9251: the uninitialized entries in gmtapi_init_sharedlibs are still a bug for anyone with 9 or more libraries. build.yml and docs.yml are left as they are.

Reviewed with Claude Opus 5.5 (read-only review of the diff). Written with Claude Sonnet 5.5.

The vcpkg toolchain runs "vcpkg z-applocal" after each add_library(), which copies
hdf5, netcdf, libcurl, z, proj, etc. into build/src and build/src/plugins. GMT loads every
DLL found in the plugin directory, so the Windows test job ran with 9 shared library entries
and hit the uninitialized-entries bug in gmtapi_init_sharedlibs, and proj_9.dll in build/src
also hid the vcpkg share/proj lookup. The dependencies are already found through PATH
(ci/install-dependencies-windows.sh), so turn the applocal copy off in tests.yml.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@Esteban82 Esteban82 added the maintenance Boring but important stuff for the core devs label Oct 9, 2026
…ows too

Same change as in tests.yml, so that the three Windows builds are configured alike.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@Esteban82

Copy link
Copy Markdown
Member Author

Result of the Windows job (https://github.com/GenericMappingTools/gmt/actions/runs/37935561631):

  • The "Failure while closing GMT z shared library" message no longer appears in the log.
  • Two tests that failed on master now pass: pssolar_missing_plusd and proj4_nox0y0.
  • dataserver_alias and WL_example_2 now fail with a libcurl timeout. They also fail on Linux and macOS, so they are not related to this change.

I just pushed a second commit that adds the same flag to build.yml and docs.yml, so the three Windows builds are configured alike.

I think this can be approved.

@Esteban82
Esteban82 requested a review from joa-quim October 9, 2026 14:40
@Esteban82
Esteban82 merged commit c583a3a into master Oct 9, 2026
13 of 16 checks passed
@Esteban82
Esteban82 deleted the fix-windows-applocal-deps branch October 9, 2026 18:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintenance Boring but important stuff for the core devs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants