Filter extra_paths on Windows to only include SharedLibrary targets - #16039
Open
tristan957 wants to merge 2 commits into
Open
Filter extra_paths on Windows to only include SharedLibrary targets#16039tristan957 wants to merge 2 commits into
tristan957 wants to merge 2 commits into
Conversation
tristan957
requested review from
dcbaker and
eli-schwartz
and removed request for
jpakkane
July 27, 2026 18:22
Member
Author
|
cc @lb90 |
We set IFS to do some parsing, but never unset it. This is a problem in
our Windows setups because paths have a colon, which separates the
drive letter from the rest of the path.
/d/a/meson/meson/test cases/common/230 external project/libfoo/configure: line 47: D: command not found
Signed-off-by: Tristan Partin <tristan@partin.io>
determine_windows_extra_paths() on non-Windows is not used for too much.
It is used in two instances. In those two instances, extra_paths has very
narrow use cases.
- Backend::get_devenv(): we add to extra_paths for every
build.Executable. This also happens on Windows.
- Backend::get_executable_serialisation(): extra_paths is empty on
non-Windows.
It is important to remember that Windows has no equivalent to
{DY,}LD_LIBRARY_PATH. Instead it looks up DLLs on PATH. Performing this
filter will have an adverse effect on adding build outputs from
build.CustomTarget to PATH. However, when setting {DY,}LD_LIBRARY_PATH,
we filter for build.SharedLibrary explicitly, so it was an oversight in
the original patch[0] to include this additional behavior.
Link: mesonbuild#14649 [0]
Fixes: mesonbuild#16010
Supersedes: mesonbuild#16011
Signed-off-by: Tristan Partin <tristan@partin.io>
Member
Author
|
This is now rebased on #16041 to hopefully fix a CI issue. Please merge that, and then I can rebase again. |
Member
Author
|
Although it has no effect, it might be good to merge #16040 first, and then I can rebase this PR on master. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
determine_windows_extra_paths() on non-Windows is not used for too much. It is used in two instances. In those two instances, extra_paths has very narrow use cases.
It is important to remember that Windows has no equivalent to {DY,}LD_LIBRARY_PATH. Instead it looks up DLLs on PATH. Performing this filter will have an adverse effect on adding build outputs from build.CustomTarget to PATH. However, when setting {DY,}LD_LIBRARY_PATH, we filter for build.SharedLibrary explicitly, so it was an oversight in the original patch[0] to include this additional behavior.
Link: #14649 [0]
Fixes: #16010
Supersedes: #16011