Skip to content

Commit

Permalink
Fix win32 build
Browse files Browse the repository at this point in the history
  • Loading branch information
alesapin committed Oct 2, 2024
1 parent a91cf26 commit 7fd05c6
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
5 changes: 5 additions & 0 deletions cmake/os.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,11 @@ elseif (CMAKE_SYSTEM_NAME MATCHES "SunOS")
set (OS_SUNOS 1)
add_definitions(-D OS_SUNOS)
elseif (CMAKE_SYSTEM_NAME MATCHES "Windows")
if(NOT "${CMAKE_GENERATOR}" MATCHES "(Win64|IA64)")
set(WINDOWS_32 1)
MESSAGE(STATUS "WIN32")
endif()

set (OS_WINDOWS 1)
add_definitions(-D OS_WINDOWS)
else ()
Expand Down
5 changes: 3 additions & 2 deletions contrib/zlib-ng-cmake/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,9 @@ elseif (OS_WINDOWS)
endif()

add_definitions(-DHAVE_BUILTIN_CTZ)
add_definitions(-DHAVE_BUILTIN_CTZLL)

if (NOT WINDOWS_32)
add_definitions(-DHAVE_BUILTIN_CTZLL)
endif()

set(ZLIB_ARCH_SRCS)
set(ZLIB_ARCH_HDRS)
Expand Down

0 comments on commit 7fd05c6

Please sign in to comment.