From 026a038bbdddea071989c199b2393a4caae5c217 Mon Sep 17 00:00:00 2001 From: William Lallemand Date: Thu, 28 May 2026 16:25:44 +0200 Subject: [PATCH] BUILD: addons: convert deviceatlas addon to EXTRA_MAKE Move the deviceatlas Makefile.inc to Makefile.mk so it can be used with EXTRA_MAKE and allow to cleanup the main Makefile. EXTRA_MAKE paths are appended with /Makefile.mk via addsuffix, so the path must not have a trailing slash. Shouldn't have impact on the build system, every build variable previously used are the same. --- Makefile | 9 +-------- addons/deviceatlas/{Makefile.inc => Makefile.mk} | 9 +++++++++ 2 files changed, 10 insertions(+), 8 deletions(-) rename addons/deviceatlas/{Makefile.inc => Makefile.mk} (71%) diff --git a/Makefile b/Makefile index e799a19ac..ff72d0f95 100644 --- a/Makefile +++ b/Makefile @@ -722,14 +722,7 @@ ifneq ($(USE_PROMEX:0=),) endif ifneq ($(USE_DEVICEATLAS:0=),) - # Use DEVICEATLAS_SRC and possibly DEVICEATLAS_INC and DEVICEATLAS_LIB to force path - # to DeviceAtlas headers and libraries if needed. In this context, DEVICEATLAS_NOCACHE - # can be used to disable the cache support if needed (this also removes the necessity of having - # a C++ toolchain installed). - DEVICEATLAS_INC = $(DEVICEATLAS_SRC) - DEVICEATLAS_LIB = $(DEVICEATLAS_SRC) - include addons/deviceatlas/Makefile.inc - OPTIONS_OBJS += addons/deviceatlas/da.o + EXTRA_MAKE += addons/deviceatlas endif ifneq ($(USE_51DEGREES:0=),) diff --git a/addons/deviceatlas/Makefile.inc b/addons/deviceatlas/Makefile.mk similarity index 71% rename from addons/deviceatlas/Makefile.inc rename to addons/deviceatlas/Makefile.mk index b144f883b..00ec04dbe 100644 --- a/addons/deviceatlas/Makefile.inc +++ b/addons/deviceatlas/Makefile.mk @@ -1,6 +1,13 @@ # DEVICEATLAS_SRC : DeviceAtlas API source root path +# Use DEVICEATLAS_SRC and possibly DEVICEATLAS_INC and DEVICEATLAS_LIB to force path +# to DeviceAtlas headers and libraries if needed. In this context, DEVICEATLAS_NOCACHE +# can be used to disable the cache support if needed (this also removes the necessity of having +# a C++ toolchain installed). +DEVICEATLAS_INC = $(DEVICEATLAS_SRC) +DEVICEATLAS_LIB = $(DEVICEATLAS_SRC) + CXX := c++ CXXLIB := -lstdc++ @@ -28,5 +35,7 @@ OPTIONS_OBJS += $(DEVICEATLAS_SRC)/dadwcurl.o OPTIONS_OBJS += $(DEVICEATLAS_SRC)/Os/daunix.o endif +OPTIONS_OBJS += addons/deviceatlas/da.o + addons/deviceatlas/dummy/%.o: addons/deviceatlas/dummy/%.cpp $(cmd_CXX) $(CXXFLAGS) -c -o $@ $<