tdf#155446 Fix problem with ccache on Windows
This patch fixes the recent problem with building LibreOffice with ccache
on Windows which was caused by the lack of double quotation mark between
ccache.exe and path to the MSVC compiler.
Change-Id: I1a714513ccb8cd674895d0c887013ea862d3b544
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152277
Tested-by: Jenkins
Reviewed-by: Hossein <hossein@libreoffice.org>
(cherry picked from commit 0c9f095a01682d8cb99a596e568bd81ae96906a5)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163505
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
(cherry picked from commit aeca67238e26cd148083055e0f223753f7462c14)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163530
Tested-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
diff --git a/solenv/gbuild/platform/com_MSC_class.mk b/solenv/gbuild/platform/com_MSC_class.mk
index ba42b0b..d8cab84 100644
--- a/solenv/gbuild/platform/com_MSC_class.mk
+++ b/solenv/gbuild/platform/com_MSC_class.mk
@@ -179,7 +179,7 @@ define gb_AsmObject__command
$(call gb_Output_announce,$(2),$(true),ASM,3)
$(call gb_Helper_abbreviate_dirs,\
mkdir -p $(dir $(1)) $(dir $(4)) && \
"$(CC)" -nologo -EP -D_M_ARM64 $(SOLARINC) $(3) > $(subst .o,.asm,$(1)) && \
$(CC) -nologo -EP -D_M_ARM64 $(SOLARINC) $(3) > $(subst .o,.asm,$(1)) && \
"$(ML_EXE)" $(gb_AFLAGS) -g -errorReport:prompt -o $(1) $(subst .o,.asm,$(1)), \
) && \
echo "$(1) : $(3)" > $(4)
@@ -664,8 +664,12 @@ gb_AUTOCONF_WRAPPERS = \
gb_ExternalProject_INCLUDE := \
$(subst -I,,$(subst $(WHITESPACE),;,$(SOLARINC)))
# Workaround for openssl build - it puts the CC var into additional pair of quotes. This breaks if
# CC consists of more than a single element such as when using "ccache compiler". In case the
# variables are exported for openssl, it closes and reopens the quotes after each element.
gb_NMAKE_VARS = \
CC="$(shell cygpath -w $(filter-out -%,$(CC))) $(filter -%,$(CC))" \
CC="$(subst $(WHITESPACE),$(if $(filter openssl,$(1)),\" \", ),$(strip \
$(shell cygpath -ws $(filter-out -%,$(CC))) $(filter -%,$(CC))))" \
INCLUDE="$(gb_ExternalProject_INCLUDE)" \
LIB="$(ILIB)" \
MAKEFLAGS= \