Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRay Molenkamp <github@lazydodo.com>2019-04-17 22:26:02 +0300
committerRay Molenkamp <github@lazydodo.com>2019-04-17 22:26:02 +0300
commitb46245470f79cdacf879954bfa9f6e4cc0d80f0e (patch)
treee66fd6e6260c0b1f68782585a9fa1e5b4c96c5cf /build_files/cmake/macros.cmake
parent1a4b60c30db319b71bdc2e2fed2612c873fa8757 (diff)
cmake: Fix python linker issues on windows.
Recent cmake work made the debug build link both python37.dll and python37_d.dll
Diffstat (limited to 'build_files/cmake/macros.cmake')
-rw-r--r--build_files/cmake/macros.cmake14
1 files changed, 3 insertions, 11 deletions
diff --git a/build_files/cmake/macros.cmake b/build_files/cmake/macros.cmake
index 699f9cb1a99..56d9117e560 100644
--- a/build_files/cmake/macros.cmake
+++ b/build_files/cmake/macros.cmake
@@ -383,18 +383,10 @@ function(setup_liblinks
${FREETYPE_LIBRARY}
)
- # since we are using the local libs for python when compiling msvc projects, we need to add _d when compiling debug versions
- if(WITH_PYTHON) # AND NOT WITH_PYTHON_MODULE # WIN32 needs
- target_link_libraries(${target} ${PYTHON_LINKFLAGS})
- if(WIN32 AND NOT UNIX)
- file_list_suffix(PYTHON_LIBRARIES_DEBUG "${PYTHON_LIBRARIES}" "_d")
- target_link_libraries_debug(${target} "${PYTHON_LIBRARIES_DEBUG}")
- target_link_libraries_optimized(${target} "${PYTHON_LIBRARIES}")
- unset(PYTHON_LIBRARIES_DEBUG)
- else()
- target_link_libraries(${target} ${PYTHON_LIBRARIES})
- endif()
+ if(WITH_PYTHON)
+ target_link_libraries(${target} ${PYTHON_LINKFLAGS})
+ target_link_libraries(${target} ${PYTHON_LIBRARIES})
endif()
if(WITH_LZO AND WITH_SYSTEM_LZO)