diff options
author | Viktor Szakats <commit@vsz.me> | 2020-08-22 21:06:06 +0000 |
---|---|---|
committer | Viktor Szakats <commit@vsz.me> | 2020-08-22 21:08:28 +0000 |
commit | 38039da764f9302f3188432895184eeae9ca8eaa (patch) | |
tree | 0e9591a480ee93009cff8d3ee33d0f91dae96ac7 | |
parent | 327bd5d02651442eb4bd7097cb1fcdf8d10b94af (diff) | |
download | curl-38039da764f9302f3188432895184eeae9ca8eaa.tar.gz |
Makefile.m32: add ability to override zstd libs [ci skip]
Similarly to brotli, where this was already possible.
E.g. it allows to link zstd statically to libcurl.dll.
Ref: https://github.com/curl/curl-for-win/issues/12
Ref: https://github.com/curl/curl-for-win/commit/d9b266afd2e5d3f5604483010ef62340b5918c89
Closes https://github.com/curl/curl/pull/5840
-rw-r--r-- | docs/examples/Makefile.m32 | 7 | ||||
-rw-r--r-- | lib/Makefile.m32 | 7 | ||||
-rw-r--r-- | src/Makefile.m32 | 7 |
3 files changed, 18 insertions, 3 deletions
diff --git a/docs/examples/Makefile.m32 b/docs/examples/Makefile.m32 index e8c0d376f..a2dca6bbc 100644 --- a/docs/examples/Makefile.m32 +++ b/docs/examples/Makefile.m32 @@ -294,7 +294,12 @@ endif ifdef ZSTD INCLUDES += -I"$(ZSTD_PATH)/include" CFLAGS += -DHAVE_ZSTD - curl_LDADD += -L"$(ZSTD_PATH)/lib" -lzstd + curl_LDADD += -L"$(ZSTD_PATH)/lib" + ifdef ZSTD_LIBS + curl_LDADD += $(ZSTD_LIBS) + else + curl_LDADD += -lzstd + endif endif ifdef BROTLI INCLUDES += -I"$(BROTLI_PATH)/include" diff --git a/lib/Makefile.m32 b/lib/Makefile.m32 index 02b31106c..37887eed5 100644 --- a/lib/Makefile.m32 +++ b/lib/Makefile.m32 @@ -298,7 +298,12 @@ endif ifdef ZSTD INCLUDES += -I"$(ZSTD_PATH)/include" CFLAGS += -DHAVE_ZSTD - DLL_LIBS += -L"$(ZSTD_PATH)/lib" -lzstd + DLL_LIBS += -L"$(ZSTD_PATH)/lib" + ifdef ZSTD_LIBS + DLL_LIBS += $(ZSTD_LIBS) + else + DLL_LIBS += -lzstd + endif endif ifdef BROTLI INCLUDES += -I"$(BROTLI_PATH)/include" diff --git a/src/Makefile.m32 b/src/Makefile.m32 index afb4fd547..74e7b93d7 100644 --- a/src/Makefile.m32 +++ b/src/Makefile.m32 @@ -312,7 +312,12 @@ endif ifdef ZSTD INCLUDES += -I"$(ZSTD_PATH)/include" CFLAGS += -DHAVE_ZSTD - curl_LDADD += -L"$(ZSTD_PATH)/lib" -lzstd + curl_LDADD += -L"$(ZSTD_PATH)/lib" + ifdef ZSTD_LIBS + curl_LDADD += $(ZSTD_LIBS) + else + curl_LDADD += -lzstd + endif endif ifdef BROTLI INCLUDES += -I"$(BROTLI_PATH)/include" |