THRIFT-5810: install static MSVC libraries to lib/
With THRIFT-5109 the LIB_INSTALL_DIR for MSVC libs chanaged from lib/
to bin/ which makes sense for shared libs but is not consistent with the
usual treatment of static libs.
Install the static libs to lib/, similar to other platforms and projects.
diff --git a/build/cmake/DefineInstallationPaths.cmake b/build/cmake/DefineInstallationPaths.cmake
index 23962b4..0c3dd09 100644
--- a/build/cmake/DefineInstallationPaths.cmake
+++ b/build/cmake/DefineInstallationPaths.cmake
@@ -20,7 +20,9 @@
# Define the default install paths
set(BIN_INSTALL_DIR "bin" CACHE PATH "The binary install dir (default: bin)")
-if(MSVC)
+# For MSVC builds, install shared libs to bin/, while keeping the install
+# dir for static libs as lib/.
+if(MSVC AND BUILD_SHARED_LIBS)
set(LIB_INSTALL_DIR "bin${LIB_SUFFIX}" CACHE PATH "The library install dir (default: bin${LIB_SUFFIX})")
else()
set(LIB_INSTALL_DIR "lib${LIB_SUFFIX}" CACHE PATH "The library install dir (default: lib${LIB_SUFFIX})")