Passing absolute path to GN command on MSYS shell doesn't work |
||
Issue descriptionOS: Windows 1. Open Git Bash or other MSYS shell. 2. Run GN command that requires passing a path. Give an absolute path. For instance: gn refs out/Debug "/C:/foo/bar/*" Expected result: Specified path should be accepted as a valid GN-style absolute path. Actual result: GN reports an error: ERROR Bad absolute path. Absolute paths must be of the form /C:\ but this is "C:/foo/bar/*". The root cause is that MSYS shells convert POSIX paths before passing them to Windows native programs. It means that the leading slash character is removed from path before it's passed to GN. See http://www.mingw.org/wiki/Posix_path_conversion
,
Apr 7 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/006cf0f95a92cbd6780b9d85fad3e415fd97bec9 commit 006cf0f95a92cbd6780b9d85fad3e415fd97bec9 Author: tmoniuszko <tmoniuszko@opera.com> Date: Thu Apr 07 07:29:48 2016 Accept absolute Windows paths without leading slash in GN commands Leading slash is removed before path is passed to GN when command is run on MSYS shell. See http://www.mingw.org/wiki/Posix_path_conversion. BUG= 590686 Review URL: https://codereview.chromium.org/1742303002 Cr-Commit-Position: refs/heads/master@{#385686} [modify] https://crrev.com/006cf0f95a92cbd6780b9d85fad3e415fd97bec9/tools/gn/label.cc [modify] https://crrev.com/006cf0f95a92cbd6780b9d85fad3e415fd97bec9/tools/gn/label_pattern.cc [modify] https://crrev.com/006cf0f95a92cbd6780b9d85fad3e415fd97bec9/tools/gn/label_pattern_unittest.cc [modify] https://crrev.com/006cf0f95a92cbd6780b9d85fad3e415fd97bec9/tools/gn/label_unittest.cc
,
Apr 7 2016
|
||
►
Sign in to add a comment |
||
Comment 1 by tmonius...@opera.com
, Feb 29 2016