mirror of
https://github.com/thelsing/knx.git
synced 2026-04-06 03:21:49 +02:00
update pybind11
This commit is contained in:
@@ -9,6 +9,8 @@
|
||||
# CATCH_INCLUDE_DIR - path to catch.hpp
|
||||
# CATCH_VERSION - version number
|
||||
|
||||
option(DOWNLOAD_CATCH "Download catch2 if not found")
|
||||
|
||||
if(NOT Catch_FIND_VERSION)
|
||||
message(FATAL_ERROR "A version number must be specified.")
|
||||
elseif(Catch_FIND_REQUIRED)
|
||||
@@ -34,10 +36,14 @@ endfunction()
|
||||
function(_download_catch version destination_dir)
|
||||
message(STATUS "Downloading catch v${version}...")
|
||||
set(url https://github.com/philsquared/Catch/releases/download/v${version}/catch.hpp)
|
||||
file(DOWNLOAD ${url} "${destination_dir}/catch.hpp" STATUS status)
|
||||
file(
|
||||
DOWNLOAD ${url} "${destination_dir}/catch.hpp"
|
||||
STATUS status
|
||||
LOG log)
|
||||
list(GET status 0 error)
|
||||
if(error)
|
||||
message(FATAL_ERROR "Could not download ${url}")
|
||||
string(REPLACE "\n" "\n " log " ${log}")
|
||||
message(FATAL_ERROR "Could not download URL:\n" " ${url}\n" "Log:\n" "${log}")
|
||||
endif()
|
||||
set(CATCH_INCLUDE_DIR
|
||||
"${destination_dir}"
|
||||
|
||||
Reference in New Issue
Block a user