From 3717ccf4e5f020d6706102d7c594efa985cba363 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Mon, 4 May 2026 08:31:38 +0000 Subject: [PATCH 2/2] fix(external): disable -Werror=format-security for cspice ExternalProject on Linux Agent-Logs-Url: https://github.com/f4exb/sdrangel/sessions/6836e1ac-619b-460b-a5f8-21c542826bc8 Co-authored-by: f4exb <6192319+f4exb@users.noreply.github.com> --- external/CMakeLists.txt | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/external/CMakeLists.txt b/external/CMakeLists.txt index ee34be837..9985c9650 100644 --- a/external/CMakeLists.txt +++ b/external/CMakeLists.txt @@ -864,7 +864,11 @@ if(ENABLE_FEATURE_STARTRACKER) elseif (LINUX) # We need a shared library on Linux, as the static library has non PIC code, and we need to link it into a shared library set(CSPICE_LIBRARIES "${EXTERNAL_BUILD_LIBRARIES}/lib${LIB_SUFFIX}/libcspice.so" CACHE INTERNAL "") - set(CSPICE_ARGS "-DCSPICE_BUILD_STATIC_LIBRARY=OFF") + # Disable -Werror=format-security for cspice only: distro hardening flags (e.g. Ubuntu Noble) + # inject -Werror=format-security which fails cspice sources that lack -Wformat. + set(CSPICE_ARGS "-DCSPICE_BUILD_STATIC_LIBRARY=OFF" + "-DCMAKE_C_FLAGS=-Wno-error=format-security" + "-DCMAKE_CXX_FLAGS=-Wno-error=format-security") elseif (APPLE) set(CSPICE_LIBRARIES "${EXTERNAL_BUILD_LIBRARIES}/cspice/src/cspice-build/lib/libcspice.a" CACHE INTERNAL "") endif()