Skip to content
This repository has been archived by the owner on Jan 9, 2021. It is now read-only.

Commit

Permalink
CMake: auto-discover project files under the projects/ subdirectory.
Browse files Browse the repository at this point in the history
Patch by Viktar Zviarovich!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66230 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
Oscar Fuentes committed Mar 6, 2009
1 parent abab81f commit 5c6bf65
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
1 change: 1 addition & 0 deletions CMakeLists.txt
Expand Up @@ -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)
Expand Down
9 changes: 9 additions & 0 deletions 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)

0 comments on commit 5c6bf65

Please sign in to comment.