diff options
author | Kelly Rauchenberger <fefferburbia@gmail.com> | 2016-01-27 12:14:10 -0500 |
---|---|---|
committer | Kelly Rauchenberger <fefferburbia@gmail.com> | 2016-01-27 12:14:10 -0500 |
commit | f000c71ebc2520ac845fc67d9920548489f925cd (patch) | |
tree | 9dbed7057757d0e32faa8757596b8944e09049c4 | |
parent | 1d15f748200f093d869c6fcc38d6053903ff5062 (diff) | |
download | rawr-ebooks-f000c71ebc2520ac845fc67d9920548489f925cd.tar.gz rawr-ebooks-f000c71ebc2520ac845fc67d9920548489f925cd.tar.bz2 rawr-ebooks-f000c71ebc2520ac845fc67d9920548489f925cd.zip |
You can now make rawr-gen even if you don't have curl or yaml-cpp
-rw-r--r-- | CMakeLists.txt | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 4f502af..aa63a34 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt | |||
@@ -1,13 +1,17 @@ | |||
1 | cmake_minimum_required (VERSION 2.6) | 1 | cmake_minimum_required (VERSION 2.6) |
2 | project (rawr-ebooks) | 2 | project (rawr-ebooks) |
3 | 3 | ||
4 | add_subdirectory(vendor/twitcurl/libtwitcurl) | ||
5 | |||
6 | find_package(PkgConfig) | 4 | find_package(PkgConfig) |
7 | pkg_check_modules(YamlCpp yaml-cpp REQUIRED) | 5 | pkg_check_modules(YamlCpp yaml-cpp) |
6 | find_package(curl) | ||
8 | 7 | ||
9 | include_directories(vendor/twitcurl/libtwitcurl) | 8 | if (YamlCpp_FOUND AND CURL_FOUND) |
10 | add_executable(rawr-ebooks ebooks.cpp kgramstats.cpp freevars.cpp malaprop.cpp) | 9 | add_subdirectory(vendor/twitcurl/libtwitcurl) |
11 | target_link_libraries(rawr-ebooks ${YamlCpp_LIBRARIES} twitcurl curl) | 10 | include_directories(vendor/twitcurl/libtwitcurl) |
11 | add_executable(rawr-ebooks ebooks.cpp kgramstats.cpp freevars.cpp malaprop.cpp) | ||
12 | target_link_libraries(rawr-ebooks ${YamlCpp_LIBRARIES} twitcurl ${CURL_LIBRARIES}) | ||
13 | else (YamlCpp_FOUND AND CURL_FOUND) | ||
14 | message(STATUS "rawr-ebooks requires yaml-cpp and twitcurl; without these, we will only make rawr-gen") | ||
15 | endif (YamlCpp_FOUND AND CURL_FOUND) | ||
12 | 16 | ||
13 | add_executable(rawr-gen gen.cpp kgramstats.cpp freevars.cpp malaprop.cpp) | 17 | add_executable(rawr-gen gen.cpp kgramstats.cpp freevars.cpp malaprop.cpp) |