From 3d5e948bb6d403e6267c9bd710169f7b6b7a06ab Mon Sep 17 00:00:00 2001 From: Thomas Jensen Date: Mon, 13 Nov 2023 09:30:15 +0100 Subject: [PATCH] Updates based on @msaft's comments --- .vscode/settings.json | 3 ++- CMakeLists.txt | 2 +- utest/CMakeLists.txt | 11 ++++++----- 3 files changed, 9 insertions(+), 7 deletions(-) diff --git a/.vscode/settings.json b/.vscode/settings.json index ba4c2aea..228e6eec 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -50,5 +50,6 @@ "editor.insertSpaces": false, "editor.detectIndentation": false, "editor.renderWhitespace": "boundary" - } + }, + "cmake.configureOnOpen": true } diff --git a/CMakeLists.txt b/CMakeLists.txt index 608ea16d..4205a3e6 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.25) +cmake_minimum_required(VERSION 3.23) # Build options options option(BUILD_SHARED_LIBS "Build shared libraries" OFF) diff --git a/utest/CMakeLists.txt b/utest/CMakeLists.txt index 01e2eff0..fd1528cf 100644 --- a/utest/CMakeLists.txt +++ b/utest/CMakeLists.txt @@ -26,17 +26,18 @@ set(SOURCES main.c ) +# ----------------------------------------------------------------------------- + +add_executable(${TARGET} + ${SOURCES} +) + if (HAVE_STRINGOP_OVERFLOW) target_compile_options(${TARGET} PRIVATE -Wno-stringop-overflow ) endif (HAVE_STRINGOP_OVERFLOW) -# ----------------------------------------------------------------------------- - -add_executable(${TARGET} - ${SOURCES} -) target_link_libraries(${TARGET} PRIVATE ${SUT}