mirror of
https://github.com/Kitware/CMake.git
synced 2026-03-09 10:00:12 -05:00
file(REAL_PATH): resolve symlinks before '..' components
Previously REAL_PATH would collapse paths before resolving any symlinks so if `..` crossed a symlink the output from `REAL_PATH` would be wrong. It looked like REAL_PATH did this by mistake since it was a side-effect of ensuring we had an absolute path before resolving symlinks.
This commit is contained in:
@@ -981,6 +981,11 @@ Path Conversion
|
||||
if ``USERPROFILE`` is not defined. On all other platforms, only ``HOME``
|
||||
is used.
|
||||
|
||||
.. versionchanged:: 3.28
|
||||
|
||||
All symlinks are resolved before collapsing ``../`` components.
|
||||
See policy :policy:`CMP0152`.
|
||||
|
||||
.. signature::
|
||||
file(RELATIVE_PATH <variable> <directory> <file>)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user