Created
December 16, 2013 05:23
-
-
Save davidbirdsong/7982677 to your computer and use it in GitHub Desktop.
cmake hack to make hekad work w/ local clones
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| diff --git a/cmake/externals.cmake b/cmake/externals.cmake | |
| index 78c09f0..05e7a08 100644 | |
| --- a/cmake/externals.cmake | |
| +++ b/cmake/externals.cmake | |
| @@ -63,12 +63,19 @@ function(hg_clone url tag) | |
| add_dependencies(GoPackages ${_name}) | |
| endfunction(hg_clone) | |
| +function(local_clone ${_url}) | |
| + string(REGEX REPLACE ".*/" "" _name ${url}) | |
| + add_dependencies(GoPackages ${_name}) | |
| +endfunction(local_clone) | |
| + | |
| function(add_external_plugin vcs url tag) | |
| string(REGEX REPLACE "https?://" "" _path ${url}) | |
| if ("${vcs}" STREQUAL "git") | |
| git_clone(${url} ${tag}) | |
| elseif("${vcs}" STREQUAL "hg") | |
| hg_clone(${url} ${tag}) | |
| + elseif("${vcs}" STREQUAL "local_clone") | |
| + local_clone(${url}) | |
| else() | |
| message(FATAL_ERROR "Unknown version control system ${vcs}") | |
| endif() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment