From: William Lallemand Date: Thu, 28 May 2026 14:25:44 +0000 (+0200) Subject: BUILD: addons: convert deviceatlas addon to EXTRA_MAKE X-Git-Tag: v3.4.0~71 X-Git-Url: http://git.ipfire.org/gitweb/index.cgi?a=commitdiff_plain;h=026a038bbdddea071989c199b2393a4caae5c217;p=thirdparty%2Fhaproxy.git 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. --- 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 $@ $<