-
Notifications
You must be signed in to change notification settings - Fork 77
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
SLVS-1167 Feature/cfamily migration #5922
Merged
georgii-borovinskikh-sonarsource
merged 21 commits into
master
from
feature/cfamily-migration
Dec 24, 2024
Merged
SLVS-1167 Feature/cfamily migration #5922
georgii-borovinskikh-sonarsource
merged 21 commits into
master
from
feature/cfamily-migration
Dec 24, 2024
Conversation
This file contains 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
Contributor
[SLVS-1668](https://sonarsource.atlassian.net/browse/SLVS-1668) Part of SLVS-1637 See the linked ticket for details about the problems we identified. This PR introduces the following changes: - To communicate the header file language, I am adding the relevant switches to the generated command in the header case as well. This helps analyze C headers as such when they are located inside C VCX projects. - Since `HeaderFileLanguage` is no longer needed, I am removing it from `FileConfig`. [SLVS-1668]: https://sonarsource.atlassian.net/browse/SLVS-1668?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
[SLVS-1690](https://sonarsource.atlassian.net/browse/SLVS-1690) This is done by including a special environment variable in the compilation database entry generated for header files. This environment variable is recognized starting with CFamily analyzer v6.62 (CPP-5898). Additionally, the PR adds some verbose logs to describe which env variables were overwritten/added (similar to what we used to have [here](https://github.com/SonarSource/sonarlint-visualstudio/blob/6498da7a3788467884af7446966029aaab5625ce/src/CFamily/Subprocess/ProcessRunner.cs#L172-L1930)). [SLVS-1690]: https://sonarsource.atlassian.net/browse/SLVS-1690?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
we add a new fallback way to get the compiler path correctly. This fixes the `clang-cl` support, which is currently broken because the `ClCompilerPath` property we rely on evaluates to `/clang-cl.exe`. The new fallback method searches in the `ExecutablePath` path list for the `ClToolExe` executable, which gives the correct answer in the case of `clang-cl.exe` Co-authored-by: Georgii Borovinskikh <[email protected]> Co-authored-by: Michael Jabbour <[email protected]>
georgii-borovinskikh-sonarsource
requested a review
from gabriela-trutan-sonarsource
December 24, 2024 09:43
Part of SLVS-1167
Quality Gate passedIssues Measures |
gabriela-trutan-sonarsource
approved these changes
Dec 24, 2024
georgii-borovinskikh-sonarsource
deleted the
feature/cfamily-migration
branch
December 24, 2024 10:35
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.
SLVS-1167