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

github.com/prusa3d/PrusaSlicer.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVojtech Kral <vojtech@kral.hk>2019-01-11 14:24:25 +0300
committerVojtech Kral <vojtech@kral.hk>2019-01-11 14:49:24 +0300
commit6db40feaced23cc63854ae80ba955c5d4745922e (patch)
tree09aa284527cc1d55a9f9fc408153aadc08b53d45
parent04c0b59bc65b1984988b2322ffc2b477ea69cf03 (diff)
Build: Add a flag to disable PCHversion_1.42.0-alpha3
-rw-r--r--CMakeLists.txt13
-rw-r--r--src/libslic3r/CMakeLists.txt2
-rw-r--r--src/slic3r/CMakeLists.txt2
3 files changed, 12 insertions, 5 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 76c937cae..e2677824c 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -27,6 +27,7 @@ option(SLIC3R_GUI "Compile Slic3r with GUI components (OpenGL, wxWidgets)"
option(SLIC3R_FHS "Assume Slic3r is to be installed in a FHS directory structure" 0)
option(SLIC3R_WX_STABLE "Build against wxWidgets stable (3.0) as oppsed to dev (3.1) on Linux" 0)
option(SLIC3R_PROFILE "Compile Slic3r with an invasive Shiny profiler" 0)
+option(SLIC3R_PCH "Use precompiled headers" 1)
option(SLIC3R_MSVC_COMPILE_PARALLEL "Compile on Visual Studio in parallel" 1)
option(SLIC3R_MSVC_PDB "Generate PDB files on MSVC in Release mode" 1)
option(SLIC3R_PERL_XS "Compile XS Perl module and enable Perl unit and integration tests" 0)
@@ -37,6 +38,15 @@ option(SLIC3R_SYNTAXONLY "Only perform source code correctness checking,
option(SLIC3R_BUILD_SANDBOXES "Build development sandboxes" OFF)
option(SLIC3R_BUILD_TESTS "Build unit tests" OFF)
+# Print out the SLIC3R_* cache options
+get_cmake_property(_cache_vars CACHE_VARIABLES)
+list (SORT _cache_vars)
+foreach (_cache_var ${_cache_vars})
+ if("${_cache_var}" MATCHES "^SLIC3R_")
+ message(STATUS "${_cache_var}: ${${_cache_var}}")
+ endif ()
+endforeach()
+
if (MSVC)
if (SLIC3R_MSVC_COMPILE_PARALLEL)
add_compile_options(/MP)
@@ -46,7 +56,6 @@ if (MSVC)
add_compile_options(-bigobj -Zm316)
endif ()
-
# Display and check CMAKE_PREFIX_PATH
message(STATUS "SLIC3R_STATIC: ${SLIC3R_STATIC}")
if (NOT "${CMAKE_PREFIX_PATH}" STREQUAL "")
@@ -65,8 +74,6 @@ foreach (DIR ${PREFIX_PATH_CHECK})
endif ()
endforeach ()
-message(STATUS "SLIC3R_FHS: ${SLIC3R_FHS}")
-
# Add our own cmake module path.
list(APPEND CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake/modules/)
diff --git a/src/libslic3r/CMakeLists.txt b/src/libslic3r/CMakeLists.txt
index 7870bd1fb..c97d3d972 100644
--- a/src/libslic3r/CMakeLists.txt
+++ b/src/libslic3r/CMakeLists.txt
@@ -171,7 +171,7 @@ add_library(libslic3r STATIC
SLA/SLASpatIndex.hpp
)
-if (NOT SLIC3R_SYNTAXONLY)
+if (SLIC3R_PCH AND NOT SLIC3R_SYNTAXONLY)
add_precompiled_header(libslic3r pchheader.hpp FORCEINCLUDE)
endif ()
diff --git a/src/slic3r/CMakeLists.txt b/src/slic3r/CMakeLists.txt
index d79421439..783c65293 100644
--- a/src/slic3r/CMakeLists.txt
+++ b/src/slic3r/CMakeLists.txt
@@ -128,6 +128,6 @@ add_library(libslic3r_gui STATIC
)
target_link_libraries(libslic3r_gui libslic3r avrdude imgui)
-if (NOT SLIC3R_SYNTAXONLY)
+if (SLIC3R_PCH AND NOT SLIC3R_SYNTAXONLY)
add_precompiled_header(libslic3r_gui pchheader.hpp FORCEINCLUDE)
endif ()