]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
BUILD: Makefile: require SSL_LIB, SSL_INC to be explicitly set
authorIlya Shipitsin <chipitsine@gmail.com>
Tue, 4 Aug 2020 10:36:24 +0000 (15:36 +0500)
committerWilly Tarreau <w@1wt.eu>
Wed, 5 Aug 2020 09:37:32 +0000 (11:37 +0200)
The SSL_INC and SSL_LIB variables were not initialized in the Makefile,
so they could be accidently inherited from the environment. We require
that any makefile variable is explicitly set on the command line so they
must be initialized.

Note that the Travis scripts used to rely only on these variables to be
exported, so it was adjusted as well.

.travis.yml
Makefile

index ca6073ee7cdefd3932c5981c35d72df3135ac31b..942b68be5aacda463657b5a882650ae8f4de543c 100644 (file)
@@ -133,7 +133,7 @@ install:
 script:
   - if [ "${CC%-*}"  = "clang" ]; then export FLAGS="$FLAGS USE_OBSOLETE_LINKER=1" DEBUG_CFLAGS="-g -fsanitize=address" LDFLAGS="-fsanitize=address"; fi
   - make -C contrib/wurfl
-  - make -j3 CC=$CC CPU_CFLAGS.generic="-O1" V=1 ERR=1 TARGET=$TARGET $FLAGS DEBUG_CFLAGS="$DEBUG_CFLAGS" LDFLAGS="$LDFLAGS" ADDLIB="$ADDLIB" 51DEGREES_SRC="$FIFTYONEDEGREES_SRC" EXTRA_OBJS="$EXTRA_OBJS" $DEBUG_OPTIONS
+  - make -j3 CC=$CC CPU_CFLAGS.generic="-O1" V=1 ERR=1 TARGET=$TARGET $FLAGS DEBUG_CFLAGS="$DEBUG_CFLAGS" LDFLAGS="$LDFLAGS" ADDLIB="$ADDLIB" SSL_LIB="$SSL_LIB" SSL_INC="$SSL_INC" 51DEGREES_SRC="$FIFTYONEDEGREES_SRC" EXTRA_OBJS="$EXTRA_OBJS" $DEBUG_OPTIONS
   - ./haproxy -vv
   - if [ "${TRAVIS_OS_NAME}" = "linux" ]; then ldd haproxy; fi
   - if [ "${TRAVIS_OS_NAME}" = "osx" ]; then otool -L haproxy; fi
index 2077ca833045c0dac7686acc5ade917b5a50ddbf..3bfc84b64f7088a2014a53f42828614a46c6e5bf 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -533,6 +533,8 @@ OPTIONS_LDFLAGS += -Wl,$(if $(EXPORT_SYMBOL),$(EXPORT_SYMBOL),--export-dynamic)
 endif
 
 ifneq ($(USE_OPENSSL),)
+SSL_INC =
+SSL_LIB =
 # OpenSSL is packaged in various forms and with various dependencies.
 # In general -lssl is enough, but on some platforms, -lcrypto may be needed,
 # reason why it's added by default. Some even need -lz, then you'll need to