Skip to content

TSCBasic: rework relative path construction on Windows #298

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 21, 2022

Conversation

compnerd
Copy link
Member

When constructing a path relative to a root, compose the final path
before canonicalization as the canonicalization may require lookups
in the base location.

We additionally pay a small penalty to convert the slashes to native
separators. This is purely for aesthetic purposes, it ensures that the
path is computed initially rather than delayed until use.

This in conjunction with swiftlang/swift-package-manager#4237 enables the
use of header search paths in SPM which are based in other targets.

When constructing a path relative to a root, compose the final path
before canonicalization as the canonicalization may require lookups
in the base location.

We additionally pay a small penalty to convert the slashes to native
separators.  This is purely for aesthetic purposes, it ensures that the
path is computed initially rather than delayed until use.

This in conjunction with swiftlang/swift-package-manager#4237 enables the
use of header search paths in SPM which are based in other targets.
@millenomi
Copy link

cc @tomerd This is the second part of the fix in swiftlang/swift-package-manager#4237

@tomerd
Copy link
Contributor

tomerd commented Mar 19, 2022

@swift-ci please test

@tomerd tomerd merged commit 367fa68 into swiftlang:main Mar 21, 2022
@compnerd compnerd deleted the relative branch March 21, 2022 16:55
compnerd added a commit to compnerd/swift-tools-support-core that referenced this pull request Apr 1, 2022
When constructing a path relative to a root, compose the final path
before canonicalization as the canonicalization may require lookups
in the base location.

We additionally pay a small penalty to convert the slashes to native
separators.  This is purely for aesthetic purposes, it ensures that the
path is computed initially rather than delayed until use.

This in conjunction with swiftlang/swift-package-manager#4237 enables the
use of header search paths in SPM which are based in other targets.
abertelrud pushed a commit that referenced this pull request Apr 4, 2022
When constructing a path relative to a root, compose the final path
before canonicalization as the canonicalization may require lookups
in the base location.

We additionally pay a small penalty to convert the slashes to native
separators.  This is purely for aesthetic purposes, it ensures that the
path is computed initially rather than delayed until use.

This in conjunction with swiftlang/swift-package-manager#4237 enables the
use of header search paths in SPM which are based in other targets.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants