Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[NewEV] Fix Mac Binary Path Resolution
- Fixed resolution of tildes (~) in file paths (realpath doesn't handle that apparently). - Also expanding environment variables, but only if they are at the beginning of the path. - Env var and tilde expansion is done inside a loop to handle cases where an env var points to another one or to the tilde. - Fixed extraction of product name and version signals by making sure the file path used there was pointing to the app bundle and not the end binary. - Resolution of the bundle path is done by walking up the path and loading it via [NSBundle bundleWithPath:] and testing to see if its infoDictionary has values or not (which is what we need in our use-case to get a product name and version out). Unit tests were added and are making use of a test bundle (added to test data). Bug: b:231326198 Change-Id: I24b8d8de5f93386e8c6a0e3f47a8e16d80f5f63d Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3909752 Commit-Queue: Sebastien Lalancette <seblalancette@chromium.org> Reviewed-by: Hamda Mare <hmare@google.com> Cr-Commit-Position: refs/heads/main@{#1054304}
- Loading branch information
Sebastien Lalancette
authored and
Chromium LUCI CQ
committed
Oct 3, 2022
1 parent
94e0e76
commit 4f6ef60
Showing
20 changed files
with
420 additions
and
107 deletions.
There are no files selected for viewing
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
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
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
17 changes: 0 additions & 17 deletions
17
components/device_signals/core/system_signals/linux/BUILD.gn
This file was deleted.
Oops, something went wrong.
13 changes: 0 additions & 13 deletions
13
components/device_signals/core/system_signals/linux/linux_platform_delegate.cc
This file was deleted.
Oops, something went wrong.
20 changes: 0 additions & 20 deletions
20
components/device_signals/core/system_signals/linux/linux_platform_delegate.h
This file was deleted.
Oops, something went wrong.
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
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
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
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
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
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
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
Oops, something went wrong.