mirror of
https://git.proxmox.com/git/libgit2
synced 2025-05-09 22:39:38 +00:00
Fix for a cmake bug when using MSVC + Win64 + static libraries
(see http://public.kitware.com/Bug/view.php?id=11240)
This commit is contained in:
parent
08f32085ab
commit
d66a7c061a
@ -282,6 +282,12 @@ ADD_LIBRARY(git2 ${SRC_GIT2} ${SRC_OS} ${SRC_ZLIB} ${SRC_HTTP} ${SRC_REGEX} ${SR
|
|||||||
TARGET_LINK_LIBRARIES(git2 ${SSL_LIBRARIES})
|
TARGET_LINK_LIBRARIES(git2 ${SSL_LIBRARIES})
|
||||||
TARGET_OS_LIBRARIES(git2)
|
TARGET_OS_LIBRARIES(git2)
|
||||||
|
|
||||||
|
# Workaround for Cmake bug #0011240 (see http://public.kitware.com/Bug/view.php?id=11240)
|
||||||
|
# Win64+MSVC+static libs = linker error
|
||||||
|
IF(MSVC AND NOT BUILD_SHARED_LIBS AND (${CMAKE_SIZEOF_VOID_P} MATCHES "8") )
|
||||||
|
SET_TARGET_PROPERTIES(git2 PROPERTIES STATIC_LIBRARY_FLAGS "/MACHINE:x64")
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
MSVC_SPLIT_SOURCES(git2)
|
MSVC_SPLIT_SOURCES(git2)
|
||||||
|
|
||||||
IF (SONAME)
|
IF (SONAME)
|
||||||
|
Loading…
Reference in New Issue
Block a user