From 832df6e2621a825a8877d3916eecb00307a3a2e6 Mon Sep 17 00:00:00 2001 From: Xavier Groleau Date: Tue, 16 Nov 2021 20:14:33 -0500 Subject: [PATCH] use cmakedefine instead of add definition --- src/CMakeLists.txt | 4 ---- src/bittybuzz/config.h.in | 5 +++++ 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index e9d07fc..2a1fa25 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -22,10 +22,6 @@ link_directories(${CMAKE_BINARY_DIR}/bittybuzz) # include(${INCLUDE_FILES_CMAKE}/BittyBuzzConfig.cmake) -if (BBZ_USE_FLOAT) - add_definitions(-DBBZ_USE_FLOAT=1) -endif (BBZ_USE_FLOAT) - # # Host compiler values # diff --git a/src/bittybuzz/config.h.in b/src/bittybuzz/config.h.in index e4ad18b..70ab17a 100644 --- a/src/bittybuzz/config.h.in +++ b/src/bittybuzz/config.h.in @@ -137,6 +137,11 @@ */ #cmakedefine BBZ_BYTEWISE_ASSIGNMENT +/** + * @brief Whether to floats + */ +#cmakedefine BBZ_USE_FLOAT + /** * @brief Whether to use floats for the neighbor's range and bearing * measurments.