]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
BUILD: make it possible to specify ZLIB path
authorWilly Tarreau <w@1wt.eu>
Fri, 10 Feb 2012 19:37:26 +0000 (20:37 +0100)
committerWilly Tarreau <w@1wt.eu>
Fri, 26 Oct 2012 19:13:25 +0000 (21:13 +0200)
Makefile

index 02c929105a4112ec2f8025887e9325c2743dc5a8..96417322d06fbc092b8dc64bccb3a1bfeb38d581 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -404,9 +404,12 @@ BUILD_OPTIONS   += $(call ignore_implicit,USE_GETADDRINFO)
 endif
 
 ifneq ($(USE_ZLIB),)
-OPTIONS_CFLAGS  += -DUSE_ZLIB
+# Use ZLIB_INC and ZLIB_LIB to force path to zlib.h and libz.{a,so} if needed.
+ZLIB_INC =
+ZLIB_LIB =
+OPTIONS_CFLAGS  += -DUSE_ZLIB $(if $(ZLIB_INC),-I$(ZLIB_INC))
 BUILD_OPTIONS   += $(call ignore_implicit,USE_ZLIB)
-OPTIONS_LDFLAGS += -lz
+OPTIONS_LDFLAGS += $(if $(ZLIB_LIB),-L$(ZLIB_LIB)) -lz
 endif
 
 ifneq ($(USE_POLL),)