summaryrefslogtreecommitdiff
path: root/solenv/gbuild/gbuild.mk
diff options
context:
space:
mode:
Diffstat (limited to 'solenv/gbuild/gbuild.mk')
-rw-r--r--solenv/gbuild/gbuild.mk7
1 files changed, 7 insertions, 0 deletions
diff --git a/solenv/gbuild/gbuild.mk b/solenv/gbuild/gbuild.mk
index 774bb5adfc8b..94bb0f93e866 100644
--- a/solenv/gbuild/gbuild.mk
+++ b/solenv/gbuild/gbuild.mk
@@ -142,7 +142,14 @@ ifeq ($(gb_ENABLE_SYMBOLS_FOR),no)
gb_ENABLE_SYMBOLS_FOR :=
endif
+ifeq ($(BLOCK_PCH),)
gb_ENABLE_PCH := $(ENABLE_PCH)
+else
+# Setting BLOCK_PCH effectively disables PCH, but the extra object file will be still linked in.
+# This is useful for rebuilding only some files with PCH disabled, e.g. to check #include's,
+# disabling the whole ENABLE_PCH would lead to unresolved symbols at link time.
+gb_ENABLE_PCH :=
+endif
ifneq ($(nodep)$(ENABLE_PRINT_DEPS),)
gb_FULLDEPS := $(false)