diff options
author | psychocrypt <psychocrypt@users.noreply.github.com> | 2017-11-27 21:25:03 +0100 |
---|---|---|
committer | psychocrypt <psychocrypt@users.noreply.github.com> | 2017-11-27 21:25:03 +0100 |
commit | 47a487a4a9855567fbd1e69d9e107c5ef01e81df (patch) | |
tree | 18bb4a8ff344ee661292950a70769aeb45e4c5aa /CMakeLists.txt | |
parent | 7cec1ca8426930a6ffa66d0af450052536edb563 (diff) | |
download | xmr-stak-47a487a4a9855567fbd1e69d9e107c5ef01e81df.zip xmr-stak-47a487a4a9855567fbd1e69d9e107c5ef01e81df.tar.gz |
fix CMake
- fix wrong compare for HWLOC not found
- remove usage of microhttpd variable if microhttpd is disabled
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 87c0e8a..4025973 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -361,7 +361,7 @@ if(HWLOC_ENABLE) PATH_SUFFIXES lib) - if("${HWLOC}" STREQUAL "MHTD-NOTFOUND" OR ${HWLOC_INCLUDE_DIR} STREQUAL "HWLOC_INCLUDE_DIR-NOTFOUND") + if("${HWLOC}" STREQUAL "HWLOC-NOTFOUND" OR ${HWLOC_INCLUDE_DIR} STREQUAL "HWLOC_INCLUDE_DIR-NOTFOUND") message(FATAL_ERROR "hwloc NOT found: use `-DHWLOC_ENABLE=OFF` to build without hwloc support") else() set(LIBS ${LIBS} ${HWLOC}) @@ -446,7 +446,10 @@ add_library(xmr-stak-c ${SRCFILES_C} ) set_property(TARGET xmr-stak-c PROPERTY C_STANDARD 99) -target_link_libraries(xmr-stak-c ${MHTD} ${LIBS}) +if(MICROHTTPD_ENABLE) + target_link_libraries(xmr-stak-c ${MHTD}) +endif() +target_link_libraries(xmr-stak-c ${LIBS}) # compile generic backend files file(GLOB BACKEND_CPP |