include(TestFloatFormat)
# Check if the size of numeric types are suitable.
+
check_type_size("short" SIZEOF_SHORT)
if(NOT ${SIZEOF_SHORT} EQUAL 2)
message(FATAL_ERROR "TagLib requires that short is 16-bit wide.")
endif()
# Determine the CPU byte order.
+
test_big_endian(IS_BIG_ENDIAN)
if(NOT IS_BIG_ENDIAN)
endif()
# Check if the format of floating point types are suitable.
+
test_float_format(FP_IEEE754)
if(${FP_IEEE754} EQUAL 1)
set(FLOAT_BYTEORDER 1)
endif()
# Determine which kind of atomic operations your compiler supports.
+
check_cxx_source_compiles("
#include <atomic>
int main() {
endif()
# Determine whether your compiler supports some safer version of sprintf.
+
check_cxx_source_compiles("
#include <cstdio>
int main() {
endif()
# Check for libz using the cmake supplied FindZLIB.cmake
+
if(NOT ZLIB_SOURCE)
find_package(ZLIB)
if(ZLIB_FOUND)