myx-cmake/MyxCMake/modules/MyxCMakeHighPrecisionMath.cmake

17 lines
365 B
CMake

include_guard(GLOBAL)
function(myx_cmake_enable_high_precision_math)
find_package(Quadmath)
if(QUADMATH_FOUND)
add_definitions(-DHAVE_QUADMATH=1)
else()
find_package(MPFR)
if(MPFR_FOUND)
find_package(MPFRCppThirdparty)
else()
myx_cmake_message_error("MyxCMake: Nor Quadmath, nor MPFR found.")
endif()
endif()
endfunction()