i've tried to get the MSVC 2008 linker to do incremental linking, see the attached patch.
the linker is very picky and spits out an error message that it does a full link if anything touches the .dll or .ilk file and modifies the timestamp after it was linked. but with the patch i don't get that error message for DLLs any more, but still the linking does not seem to happen any faster. i've tried in vcl and tookit modules, in an --enable-pch --enable-dbgutil build, touch a single file and rebuild the module, roughly as fast with incremental as without. when i add -verbose to the linker options, i see what looks like something adds additional parameters, among them a "/fullbuild" that is documented nowhere apparently. it's a mystery what is going on there. maybe somebody more familiar with MSVC has some insight into this that i'm missing (also i haven't got MSVC 2010 or 2012 installed so don't know what happens there).
>From 789f939ca4efea5544ede15667c2e4b4468bf424 Mon Sep 17 00:00:00 2001 From: Michael Stahl <[email protected]> Date: Mon, 8 Apr 2013 13:52:00 +0200 Subject: [PATCH] try -incremental Change-Id: I5553248530d08af54f3aac4bd881f9c2af6e2a15 --- solenv/gbuild/LinkTarget.mk | 2 +- solenv/gbuild/platform/com_MSC_class.mk | 7 +++---- 2 files changed, 4 insertions(+), 5 deletions(-) mode change 100644 => 100755 solenv/gbuild/LinkTarget.mk diff --git a/solenv/gbuild/LinkTarget.mk b/solenv/gbuild/LinkTarget.mk old mode 100644 new mode 100755 index 46952c8..4825f21 --- a/solenv/gbuild/LinkTarget.mk +++ b/solenv/gbuild/LinkTarget.mk @@ -1179,7 +1179,7 @@ endef # gb_LinkTarget_add_auxtarget linktarget auxtarget define gb_LinkTarget_add_auxtarget $(2) : $(call gb_LinkTarget_get_target,$(1)) - touch $$@ + true $(call gb_LinkTarget_get_clean_target,$(1)) : AUXTARGETS += $(2) diff --git a/solenv/gbuild/platform/com_MSC_class.mk b/solenv/gbuild/platform/com_MSC_class.mk index 55aff01..8c10bf6 100755 --- a/solenv/gbuild/platform/com_MSC_class.mk +++ b/solenv/gbuild/platform/com_MSC_class.mk @@ -213,8 +213,6 @@ $(call gb_Helper_abbreviate_dirs,\ $(if $(filter-out StaticLibrary,$(TARGETTYPE)),user32.lib) \ $(if $(DLLTARGET),-out:$(DLLTARGET) -implib:$(1),-out:$(1)); RC=$$?; rm $${RESPONSEFILE} \ $(if $(DLLTARGET),; if [ ! -f $(DLLTARGET) ]; then rm -f $(1) && false; fi) \ - $(if $(filter Library,$(TARGETTYPE)),; if [ -f $(DLLTARGET).manifest ]; then mt.exe $(MTFLAGS) -nologo -manifest $(DLLTARGET).manifest -outputresource:$(DLLTARGET)\;2; fi) \ - $(if $(filter Executable,$(TARGETTYPE)),; if [ -f $(1).manifest ]; then mt.exe $(MTFLAGS) -nologo -manifest $(1).manifest -outputresource:$(1)\;1; fi) \ ; exit $$RC) endef @@ -224,9 +222,10 @@ endef # Flags common for PE executables (EXEs and DLLs) gb_Windows_PE_TARGETTYPEFLAGS := \ - -release \ + $(if $(gb_ENABLE_DBGUTIL),\ + -incremental,\ + -release -incremental:no) \ -opt:noref \ - -incremental:no \ -debug \ -nxcompat \ -dynamicbase \ -- 1.7.9
_______________________________________________ LibreOffice mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/libreoffice
