mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-08-11 04:19:01 +08:00
More fixes
- Fix xs dll copy with wrong dirs - Fix wxWidgets build on Unixes : gtk version not being forwarded for debug build - Digging deeper into wxWidgets debug builds on Unix platforms. Seems to be discontinued
This commit is contained in:
parent
01bc9dd380
commit
27c7b04d6d
@ -56,7 +56,7 @@ function(add_cmake_project projectname)
|
||||
-DCMAKE_INSTALL_PREFIX:STRING=${DESTDIR}/usr/local
|
||||
-DCMAKE_MODULE_PATH:STRING=${CMAKE_MODULE_PATH}
|
||||
-DCMAKE_PREFIX_PATH:STRING=${DESTDIR}/usr/local
|
||||
-DCMAKE_DEBUG_POSTFIX:STRING=d
|
||||
-DCMAKE_DEBUG_POSTFIX:STRING=${CMAKE_DEBUG_POSTFIX}
|
||||
-DCMAKE_C_COMPILER:STRING=${CMAKE_C_COMPILER}
|
||||
-DCMAKE_CXX_COMPILER:STRING=${CMAKE_CXX_COMPILER}
|
||||
-DCMAKE_CXX_FLAGS_${_build_type_upper}:STRING=${CMAKE_CXX_FLAGS_${_build_type_upper}}
|
||||
|
2
deps/+wxWidgets/wxWidgets.cmake
vendored
2
deps/+wxWidgets/wxWidgets.cmake
vendored
@ -20,8 +20,6 @@ add_cmake_project(wxWidgets
|
||||
CMAKE_ARGS
|
||||
-DwxBUILD_PRECOMP=ON
|
||||
${_wx_toolkit}
|
||||
"-DCMAKE_DEBUG_POSTFIX:STRING="
|
||||
-DwxBUILD_DEBUG_LEVEL=0
|
||||
-DwxUSE_MEDIACTRL=OFF
|
||||
-DwxUSE_DETECT_SM=OFF
|
||||
-DwxUSE_UNICODE=ON
|
||||
|
11
deps/CMakeLists.txt
vendored
11
deps/CMakeLists.txt
vendored
@ -215,6 +215,10 @@ if (DEP_DEBUG AND NOT CMAKE_BUILD_TYPE STREQUAL "Debug")
|
||||
# Exclude the libraries which have no problem to link to Debug builds in
|
||||
# Release mode (mostly C libraries)
|
||||
set(DEP_DEBUG_EXCLUDES GMP MPFR OpenSSL NanoSVG TIFF JPEG ZLIB)
|
||||
if (UNIX)
|
||||
# Making a separate debug build on Unix of wx is a nightmare
|
||||
list(APPEND DEP_DEBUG_EXCLUDES wxWidgets)
|
||||
endif ()
|
||||
|
||||
# Create the list of targets needed in debug mode
|
||||
set(_build_list_dbg "")
|
||||
@ -230,10 +234,15 @@ if (DEP_DEBUG AND NOT CMAKE_BUILD_TYPE STREQUAL "Debug")
|
||||
file(MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/DebugBuild)
|
||||
execute_process(
|
||||
COMMAND ${CMAKE_COMMAND} ${CMAKE_CURRENT_SOURCE_DIR} -G${CMAKE_GENERATOR}
|
||||
-DCMAKE_BUILD_TYPE=Debug
|
||||
-DCMAKE_BUILD_TYPE=Debug
|
||||
-DDEP_WX_GTK3=${DEP_WX_GTK3}
|
||||
-DDEP_DOWNLOAD_DIR=${DEP_DOWNLOAD_DIR}
|
||||
-DDESTDIR=${DESTDIR}
|
||||
-D${PROJECT_NAME}_PACKAGE_EXCLUDES="${_excl_regexp}"
|
||||
-D${PROJECT_NAME}_SELECT_ALL=${${PROJECT_NAME}_SELECT_ALL}
|
||||
-DDEP_BUILD_VERBOSE=${DEP_BUILD_VERBOSE}
|
||||
-DCMAKE_DEBUG_POSTFIX=d
|
||||
#TODO: forward per-package selector variables
|
||||
-DDEP_MESSAGES_WRITTEN=ON
|
||||
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/DebugBuild
|
||||
OUTPUT_QUIET
|
||||
|
@ -372,11 +372,11 @@ elseif (APPLE)
|
||||
target_link_libraries(libslic3r_gui ${DISKARBITRATION_LIBRARY} ${COREWLAN_LIBRARY})
|
||||
endif()
|
||||
|
||||
if (SLIC3R_STATIC)
|
||||
#if (SLIC3R_STATIC)
|
||||
# FIXME: This was previously exported by wx-config but the wxWidgets
|
||||
# cmake build forgets this and the build fails in debug mode (or on raspberry release)
|
||||
target_compile_definitions(libslic3r_gui PUBLIC -DwxDEBUG_LEVEL=0)
|
||||
endif()
|
||||
# target_compile_definitions(libslic3r_gui PUBLIC -DwxDEBUG_LEVEL=0)
|
||||
#endif()
|
||||
|
||||
if (SLIC3R_PCH AND NOT SLIC3R_SYNTAXONLY)
|
||||
add_precompiled_header(libslic3r_gui pchheader.hpp FORCEINCLUDE)
|
||||
|
@ -172,12 +172,12 @@ if (MSVC)
|
||||
set(_bits 32)
|
||||
endif ()
|
||||
add_custom_command(TARGET XS POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${TOP_LEVEL_PROJECT_DIR}/deps/GMP/gmp/lib/win${_bits}/libgmp-10.dll "${PERL_LOCAL_LIB_ARCH_DIR}/auto/Slic3r/XS/"
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${TOP_LEVEL_PROJECT_DIR}/deps/+GMP/gmp/lib/win${_bits}/libgmp-10.dll "${PERL_LOCAL_LIB_ARCH_DIR}/auto/Slic3r/XS/"
|
||||
COMMENT "Installing gmp runtime into the local-lib directory ..."
|
||||
VERBATIM)
|
||||
|
||||
add_custom_command(TARGET XS POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${TOP_LEVEL_PROJECT_DIR}/deps/MPFR/mpfr/lib/win${_bits}/libmpfr-4.dll "${PERL_LOCAL_LIB_ARCH_DIR}/auto/Slic3r/XS/"
|
||||
COMMAND ${CMAKE_COMMAND} -E copy ${TOP_LEVEL_PROJECT_DIR}/deps/+MPFR/mpfr/lib/win${_bits}/libmpfr-4.dll "${PERL_LOCAL_LIB_ARCH_DIR}/auto/Slic3r/XS/"
|
||||
COMMENT "Installing mpfr runtime into the local-lib directory ..."
|
||||
VERBATIM)
|
||||
endif()
|
||||
|
Loading…
x
Reference in New Issue
Block a user