From: Bertrand Jacquin Date: Wed, 5 Oct 2016 23:32:39 +0000 (+0100) Subject: MINOR: build: Allow linking to device-atlas library file X-Git-Tag: v1.7-dev5~2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3a2661d6b4218704c828c8a712c87d651bfe29b5;p=thirdparty%2Fhaproxy.git MINOR: build: Allow linking to device-atlas library file DeviceAtlas might be installed in a location where a user might not have enough permissions to write json.o and dac.o --- diff --git a/Makefile b/Makefile index f055a08272..b4afcfb39e 100644 --- a/Makefile +++ b/Makefile @@ -623,8 +623,12 @@ endif DEVICEATLAS_SRC = DEVICEATLAS_INC = $(DEVICEATLAS_SRC) DEVICEATLAS_LIB = $(DEVICEATLAS_SRC) +ifeq ($(DEVICEATLAS_SRC),) +OPTIONS_LDFLAGS += -lda +else OPTIONS_OBJS += $(DEVICEATLAS_LIB)/json.o OPTIONS_OBJS += $(DEVICEATLAS_LIB)/dac.o +endif OPTIONS_OBJS += src/da.o OPTIONS_CFLAGS += -DUSE_DEVICEATLAS $(if $(DEVICEATLAS_INC),-I$(DEVICEATLAS_INC)) BUILD_OPTIONS += $(call ignore_implicit,USE_DEVICEATLAS)