Fix GSL to work with vcpkg installation (used in test_latest.yml) #1526
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
On
test_latest.yml
, we use Microsoft'svcpkg
manager to install the GSL for all operating systems. Until recently (see #1523), we weren't actually running the GSL tests, so it went unnoticed that this doesn't quite work. In contrast to the installation of GSL viaconda
, we need to manually set the path with theGSL.directory
preference. During fixing this, I also realized that our current GSL code did only use this preference for the include path with isn't enough, we only need it for the library path (and the DLL path on Windows).These tests show that it now runs correctly: https://github.com/brian-team/brian2/actions/runs/8706379543
(The checks in this PR only show that it didn't break anything for code that doesn't need the
GSL.directory
preference).