diff options
author | Oscar Fuentes <ofv@wanadoo.es> | 2009-03-06 01:16:52 +0000 |
---|---|---|
committer | Oscar Fuentes <ofv@wanadoo.es> | 2009-03-06 01:16:52 +0000 |
commit | afbe97542f6fbf2b0dac0ede5e8a38ff0b9f24c7 (patch) | |
tree | a35a6c586ac153684ceebbb9e71c32fbd0c9be6d | |
parent | b3805878d13eab23ab99b01f8a914d9e08a17cc9 (diff) | |
download | bcm5719-llvm-afbe97542f6fbf2b0dac0ede5e8a38ff0b9f24c7.tar.gz bcm5719-llvm-afbe97542f6fbf2b0dac0ede5e8a38ff0b9f24c7.zip |
CMake: auto-discover project files under the projects/ subdirectory.
Patch by Viktar Zviarovich!
llvm-svn: 66230
-rw-r--r-- | llvm/CMakeLists.txt | 1 | ||||
-rw-r--r-- | llvm/projects/CMakeLists.txt | 9 |
2 files changed, 10 insertions, 0 deletions
diff --git a/llvm/CMakeLists.txt b/llvm/CMakeLists.txt index 3dcc5e4f7ff..4ee8d204007 100644 --- a/llvm/CMakeLists.txt +++ b/llvm/CMakeLists.txt @@ -203,6 +203,7 @@ add_subdirectory(lib/AsmParser) add_subdirectory(lib/Debugger) add_subdirectory(lib/Archive) +add_subdirectory(projects) add_subdirectory(tools) add_subdirectory(examples) diff --git a/llvm/projects/CMakeLists.txt b/llvm/projects/CMakeLists.txt new file mode 100644 index 00000000000..78e12fd34a0 --- /dev/null +++ b/llvm/projects/CMakeLists.txt @@ -0,0 +1,9 @@ +# Discover the projects that use CMake in the subdirectories. +# Note that explicit cmake invocation is required every time a new project is +# added or removed. +file(GLOB entries *) +foreach(entry ${entries}) + if(IS_DIRECTORY ${entry} AND EXISTS ${entry}/CMakeLists.txt) + add_subdirectory(${entry}) + endif() +endforeach(entry) |