summaryrefslogtreecommitdiffstats
path: root/Tests/IncludeDirectories
diff options
context:
space:
mode:
authorStephen Kelly <steveire@gmail.com>2013-02-25 23:50:49 (GMT)
committerStephen Kelly <steveire@gmail.com>2013-05-16 17:36:31 (GMT)
commita7ba4520c7b15dc9f56d2c4718748b79b12c0c89 (patch)
tree68f4bd469d6bf24fae28fc4b8e8a3c8f859016aa /Tests/IncludeDirectories
parent96ec3147bbafd52b18bcf532b0da8727cd3c8104 (diff)
downloadCMake-a7ba4520c7b15dc9f56d2c4718748b79b12c0c89.zip
CMake-a7ba4520c7b15dc9f56d2c4718748b79b12c0c89.tar.gz
CMake-a7ba4520c7b15dc9f56d2c4718748b79b12c0c89.tar.bz2
Add the JOIN generator expression.
This generator expression joins a list with a separator. The separator may contain arbitrary content, such as commas, which is ordinarily a delimiter in the generator expression syntax.
Diffstat (limited to 'Tests/IncludeDirectories')
-rw-r--r--Tests/IncludeDirectories/TargetIncludeDirectories/CMakeLists.txt5
-rw-r--r--Tests/IncludeDirectories/TargetIncludeDirectories/main.cpp1
2 files changed, 6 insertions, 0 deletions
diff --git a/Tests/IncludeDirectories/TargetIncludeDirectories/CMakeLists.txt b/Tests/IncludeDirectories/TargetIncludeDirectories/CMakeLists.txt
index ad6671f..60d4c6a 100644
--- a/Tests/IncludeDirectories/TargetIncludeDirectories/CMakeLists.txt
+++ b/Tests/IncludeDirectories/TargetIncludeDirectories/CMakeLists.txt
@@ -123,3 +123,8 @@ target_link_libraries(lib5 libbad libgood)
target_include_directories(lib5
BEFORE PRIVATE $<TARGET_PROPERTY:libgood,INTERFACE_INCLUDE_DIRECTORIES>
)
+
+file(MAKE_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/prefix_foo/prefix_bar/prefix_bat")
+file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/prefix_foo/prefix_bar/prefix_bat/prefix_foo_bar_bat.h" "// prefix_foo_bar_bat.h\n")
+
+target_include_directories(TargetIncludeDirectories PRIVATE "${CMAKE_CURRENT_BINARY_DIR}/prefix_$<JOIN:foo;bar;bat,/prefix_>")
diff --git a/Tests/IncludeDirectories/TargetIncludeDirectories/main.cpp b/Tests/IncludeDirectories/TargetIncludeDirectories/main.cpp
index 90909d3..5bb34aa 100644
--- a/Tests/IncludeDirectories/TargetIncludeDirectories/main.cpp
+++ b/Tests/IncludeDirectories/TargetIncludeDirectories/main.cpp
@@ -10,6 +10,7 @@
#include "arguments.h"
#include "list.h"
#include "target.h"
+#include "prefix_foo_bar_bat.h"
int main(int, char**)
{