summaryrefslogtreecommitdiffstats
path: root/mkspecs/features/cmake_functions.prf
diff options
context:
space:
mode:
Diffstat (limited to 'mkspecs/features/cmake_functions.prf')
-rw-r--r--mkspecs/features/cmake_functions.prf5
1 files changed, 5 insertions, 0 deletions
diff --git a/mkspecs/features/cmake_functions.prf b/mkspecs/features/cmake_functions.prf
index f48ef43b88..31096a0cd7 100644
--- a/mkspecs/features/cmake_functions.prf
+++ b/mkspecs/features/cmake_functions.prf
@@ -63,3 +63,8 @@ defineReplace(cmakeProcessLibs) {
}
return ($$join(out, ";"))
}
+
+defineReplace(cmakeRelativePath) {
+ path = $$relative_path($$1, $$2)
+ return($$replace(path, ([^/])$, \\1/))
+}