mirror of
https://git.wownero.com/wownero/wownero.git
synced 2024-08-15 01:03:23 +00:00
cmake: factor out error messages
Instead of using BoldRed and ColourReset everywhere, wrap it up in a function.
This commit is contained in:
parent
9aa48b6c50
commit
a87ce09461
2 changed files with 17 additions and 10 deletions
6
external/CMakeLists.txt
vendored
6
external/CMakeLists.txt
vendored
|
@ -89,14 +89,14 @@ IF(!UNBOUND_INCLUDE_DIR OR STATIC)
|
|||
|
||||
FIND_PACKAGE(OpenSSL QUIET)
|
||||
IF(!OPENSSL_LIBRARIES)
|
||||
MESSAGE(FATAL_ERROR "${BoldRed}Could not find the openssl library. Please make sure you have installed openssl or libssl-dev or the equivalent${ColourReset}")
|
||||
die("Could not find the openssl library. Please make sure you have installed openssl or libssl-dev or the equivalent")
|
||||
ELSE()
|
||||
MESSAGE(STATUS "Found openssl libraries")
|
||||
ENDIF()
|
||||
|
||||
FIND_PACKAGE(Expat QUIET)
|
||||
IF(!EXPAT_LIBRARIES)
|
||||
MESSAGE(FATAL_ERROR "${BoldRed}Could not find the expat library. Please make sure you have installed libexpat or libexpat-dev or the equivalent${ColourReset}")
|
||||
die("Could not find the expat library. Please make sure you have installed libexpat or libexpat-dev or the equivalent")
|
||||
ELSE()
|
||||
MESSAGE(STATUS "Found expat libraries")
|
||||
ENDIF()
|
||||
|
@ -170,6 +170,6 @@ ELSE()
|
|||
set(UNBOUND_INCLUDE ${UNBOUND_INCLUDE_DIR} PARENT_SCOPE)
|
||||
set(UNBOUND_LIBRARY ${UNBOUND_LIBRARIES} PARENT_SCOPE)
|
||||
ELSE()
|
||||
MESSAGE(FATAL_ERROR "${BoldRed}Found libunbound includes, but could not find libunbound library. Please make sure you have installed libunbound or libunbound-dev or the equivalent${ColourReset}")
|
||||
die("Found libunbound includes, but could not find libunbound library. Please make sure you have installed libunbound or libunbound-dev or the equivalent")
|
||||
ENDIF()
|
||||
ENDIF()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue