Skip to content
Permalink
Browse files
Don't look for zlib and zstd manually on Windows
  • Loading branch information
sfan5 committed Sep 1, 2021
1 parent e5edda2 commit 31d2b9edcdf3215aa047d54254c192fc46a7a517
Showing with 10 additions and 14 deletions.
  1. +8 −12 src/CMakeLists.txt
  2. +1 −1 util/buildbot/buildwin32.sh
  3. +1 −1 util/buildbot/buildwin64.sh
@@ -203,6 +203,7 @@ endif(ENABLE_REDIS)

find_package(SQLite3 REQUIRED)


OPTION(ENABLE_PROMETHEUS "Enable prometheus client support" FALSE)
set(USE_PROMETHEUS FALSE)

@@ -239,6 +240,10 @@ if(ENABLE_SPATIAL)
endif(ENABLE_SPATIAL)


find_package(ZLIB REQUIRED)
find_package(Zstd REQUIRED)


if(NOT MSVC)
set(USE_GPROF FALSE CACHE BOOL "Use -pg flag for g++")
endif()
@@ -267,17 +272,10 @@ if(WIN32)
endif()
set(PLATFORM_LIBS ws2_32.lib version.lib shlwapi.lib ${PLATFORM_LIBS})

# Zlib stuff
find_path(ZLIB_INCLUDE_DIR "zlib.h" DOC "Zlib include directory")
find_library(ZLIB_LIBRARIES "zlib" DOC "Path to zlib library")

find_path(ZSTD_INCLUDE_DIR "zstd.h" DOC "Zstd include directory")
find_library(ZSTD_LIBRARY "zstd" DOC "Path to zstd library")

# Dll's are automatically copied to the output directory by vcpkg when VCPKG_APPLOCAL_DEPS=ON
# DLLs are automatically copied to the output directory by vcpkg when VCPKG_APPLOCAL_DEPS=ON
if(NOT VCPKG_APPLOCAL_DEPS)
find_file(ZLIB_DLL NAMES "zlib.dll" "zlib1.dll" DOC "Path to zlib.dll for installation (optional)")
find_file(ZSTD_DLL NAMES "zstd.dll" DOC "Path to zstd.dll for installation (optional)")
find_file(ZLIB_DLL NAMES "" DOC "Path to Zlib DLL for installation (optional)")
find_file(ZSTD_DLL NAMES "" DOC "Path to Zstd DLL for installation (optional)")
if(ENABLE_SOUND)
set(OPENAL_DLL "" CACHE FILEPATH "Path to OpenAL32.dll for installation (optional)")
set(OGG_DLL "" CACHE FILEPATH "Path to libogg.dll for installation (optional)")
@@ -299,8 +297,6 @@ else()
endif(NOT HAIKU AND NOT APPLE)
endif()

find_package(ZLIB REQUIRED)
find_package(Zstd REQUIRED)
set(PLATFORM_LIBS -lpthread ${CMAKE_DL_LIBS})
if(APPLE)
set(PLATFORM_LIBS "-framework CoreFoundation" ${PLATFORM_LIBS})
@@ -119,7 +119,7 @@ cmake -S $sourcedir -B . \
-DIRRLICHT_DLL="$irr_dlls" \
\
-DZLIB_INCLUDE_DIR=$libdir/zlib/include \
-DZLIB_LIBRARIES=$libdir/zlib/lib/libz.dll.a \
-DZLIB_LIBRARY=$libdir/zlib/lib/libz.dll.a \
-DZLIB_DLL=$libdir/zlib/bin/zlib1.dll \
\
-DZSTD_INCLUDE_DIR=$libdir/zstd/include \
@@ -119,7 +119,7 @@ cmake -S $sourcedir -B . \
-DIRRLICHT_DLL="$irr_dlls" \
\
-DZLIB_INCLUDE_DIR=$libdir/zlib/include \
-DZLIB_LIBRARIES=$libdir/zlib/lib/libz.dll.a \
-DZLIB_LIBRARY=$libdir/zlib/lib/libz.dll.a \
-DZLIB_DLL=$libdir/zlib/bin/zlib1.dll \
\
-DZSTD_INCLUDE_DIR=$libdir/zstd/include \

0 comments on commit 31d2b9e

Please sign in to comment.