From: past-due <30942300+past-due@users.noreply.github.com> Date: Sun, 14 Mar 2021 20:53:07 +0000 (-0400) Subject: [CMake] Add zlibstatic alias when BUILD_SHARED_LIBS is "OFF" X-Git-Tag: 2.0.0~7 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9f1ebac36ed7f74e2413aec07bb74a4793b34b83;p=thirdparty%2Fzlib-ng.git [CMake] Add zlibstatic alias when BUILD_SHARED_LIBS is "OFF" --- diff --git a/CMakeLists.txt b/CMakeLists.txt index 6f5bb42b..7385f6d2 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -900,6 +900,10 @@ if(NOT DEFINED BUILD_SHARED_LIBS) else() add_library(zlib ${ZLIB_ALL_SRCS}) + if(NOT BUILD_SHARED_LIBS) + add_library(zlibstatic ALIAS zlib) + endif() + set(ZLIB_INSTALL_LIBRARIES zlib) endif()