fix: SLIC3R_PCH=OFF now builds on Windows, allowing compiler caching (#15552)

This commit is contained in:
Kris Austin
2026-09-06 18:06:18 -03:00
committed by GitHub
parent 0365304ae0
commit 43ce8c5e46
14 changed files with 159 additions and 4 deletions
+7
View File
@@ -665,6 +665,13 @@ if(SLIC3R_PROFILE)
target_link_libraries(libslic3r PRIVATE Shiny)
endif()
if (WIN32)
# Public, since BlacklistedLibraryCheck.hpp includes windows.h. Empty
# WIN32_LEAN_AND_MEAN matches the sources that define it themselves; bare
# NOMINMAX matches the one libigl already passes.
target_compile_definitions(libslic3r PUBLIC "WIN32_LEAN_AND_MEAN=" "NOMINMAX")
endif ()
if (SLIC3R_PCH AND NOT SLIC3R_SYNTAXONLY)
add_precompiled_header(libslic3r pchheader.hpp FORCEINCLUDE)
endif ()