Skip to content

CompilationDatabaseBuildSystem should account for working directory #1856

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

Closed
bkolb opened this issue Dec 5, 2024 · 1 comment · Fixed by #1888
Closed

CompilationDatabaseBuildSystem should account for working directory #1856

bkolb opened this issue Dec 5, 2024 · 1 comment · Fixed by #1888
Labels
bug Something isn't working

Comments

@bkolb
Copy link

bkolb commented Dec 5, 2024

Swift version

swiftlang-6.1.0.101.24 clang-1700.0.4.22

Platform

macOS

Editor

VSCode

Description

I have configured sourcekit-lsp in VSCode to use compile-commands extracted from bazel.
Trying to resolve reverse references fails. The reason is that my path pointing to the global index is relative to the working directory. Once converted to an absolute path, it works.
The candidate could be here: https://github.com/swiftlang/sourcekit-lsp/blob/main/Sources/BuildSystemIntegration/CompilationDatabaseBuildSystem.swift#L91-L109

Steps to Reproduce

No response

Logging

No response

@bkolb bkolb added the bug Something isn't working label Dec 5, 2024
@ahoppen
Copy link
Member

ahoppen commented Dec 5, 2024

Synced to Apple’s issue tracker as rdar://141004197

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants