From 19d892354bdfb426133c72fda8a07c9cae747029 Mon Sep 17 00:00:00 2001 From: Magnus Lundborg Date: Fri, 29 Nov 2013 09:42:31 +0100 Subject: Make all testing code define USE_STD_INTTYPES_H to print properly. diff --git a/src/tests/CMakeLists.txt b/src/tests/CMakeLists.txt index b3ee6a1..3d21a5d 100644 --- a/src/tests/CMakeLists.txt +++ b/src/tests/CMakeLists.txt @@ -54,6 +54,9 @@ if(TNG_BUILD_EXAMPLES) if(UNIX) target_link_libraries(tng_io_read_pos m) endif() + if(HAVE_INTTYPES_H) + set_property(TARGET tng_io_read_pos APPEND PROPERTY COMPILE_DEFINITIONS USE_STD_INTTYPES_H=1) + endif() set_property(TARGET tng_io_read_pos PROPERTY RUNTIME_OUTPUT_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/examples) add_executable(tng_io_read_pos_util tng_io_read_pos_util.c) @@ -61,6 +64,9 @@ if(TNG_BUILD_EXAMPLES) if(UNIX) target_link_libraries(tng_io_read_pos_util m) endif() + if(HAVE_INTTYPES_H) + set_property(TARGET tng_io_read_pos_util APPEND PROPERTY COMPILE_DEFINITIONS USE_STD_INTTYPES_H=1) + endif() set_property(TARGET tng_io_read_pos_util PROPERTY RUNTIME_OUTPUT_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/examples) if(TNG_BUILD_FORTRAN) -- cgit v0.10.1