Regression: file(RELATIVE_PATH ...) gives unreachable path when symlink is in $PWD
Under certain conditions, file(RELATIVE_PATH <directory> <file>)
gives a path that is not reachable from <directory>
. The specific condition is when the the current working directory path contains a symbolic link to a path component of <directory>
. The errant behavior has been observed on Linux in cmake versions 3.11
and 3.6
, but the correct result is obtained in cmake version 2.8.12
.
The attached bash script relpath.sh exposes the problem.