summaryrefslogtreecommitdiff
path: root/solenv
diff options
context:
space:
mode:
authorJan-Marek Glogowski <jan-marek.glogowski@extern.cib.de>2019-11-30 01:56:46 +0100
committerJan-Marek Glogowski <glogow@fbihome.de>2019-12-04 20:23:52 +0100
commitd10db7846602c16701dde019f12f61fd536e9ae4 (patch)
tree76e5e81b87fcf227693cdc4118c6e296fb127464 /solenv
parent0fa95852b0968fa2a35efb8ca816949c58af56e0 (diff)
tdf#128133 WIN don't exit after link-output filter
The linker output filter command (gb_filter_link_output) ends with an exit "${PIPESTATUS[0]}", which will quit the current Makefile shell command always after calling the linker. This prevents the later shell code of that line to run, which includes the merge of the DeclareDPIAware.manifest. That manifest would tell Windows that LO binaries are "<dpiAware>true</dpiAware>", to prevent System DPI scaling. Since it's not merged, LO is scaled by the OS, resulting in blurry fonts. Since there is no reason to have an extra make "function", like ifeq or multiple definitions, this includes the code directly. Additionally the MS linker has localized output, so this patch uses a more generic regexp to filter-out the default link message, which works with the English and German locale. Change-Id: I0099f6c38ca0eda18c7b0c108529bc73189c1504 Reviewed-on: https://gerrit.libreoffice.org/84099 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
Diffstat (limited to 'solenv')
-rw-r--r--solenv/gbuild/platform/com_MSC_class.mk2
-rw-r--r--solenv/gbuild/platform/com_MSC_defs.mk4
-rwxr-xr-xsolenv/gbuild/platform/filter-creatingLibrary.awk4
3 files changed, 3 insertions, 7 deletions
diff --git a/solenv/gbuild/platform/com_MSC_class.mk b/solenv/gbuild/platform/com_MSC_class.mk
index 4eadee362148..ec23efc08df7 100644
--- a/solenv/gbuild/platform/com_MSC_class.mk
+++ b/solenv/gbuild/platform/com_MSC_class.mk
@@ -232,7 +232,7 @@ $(call gb_Helper_abbreviate_dirs,\
-manifestfile:$(WORKDIR)/LinkTarget/$(2).manifest \
-pdb:$(call gb_LinkTarget__get_pdb_filename,$(WORKDIR)/LinkTarget/$(2))) \
$(if $(ILIBTARGET),-out:$(1) -implib:$(ILIBTARGET),-out:$(1)) \
- $(call gb_filter_link_output); RC=$$?; rm $${RESPONSEFILE} \
+ | LC_ALL=C $(GBUILDDIR)/platform/filter-creatingLibrary.awk; RC=$${PIPESTATUS[0]}; rm $${RESPONSEFILE} \
$(if $(filter Library,$(TARGETTYPE)),; if [ ! -f $(ILIBTARGET) ]; then rm -f $(1); exit 42; fi) \
$(if $(filter Library,$(TARGETTYPE)),&& if [ -f $(WORKDIR)/LinkTarget/$(2).manifest ]; then mt.exe $(MTFLAGS) -nologo -manifest $(WORKDIR)/LinkTarget/$(2).manifest $(SRCDIR)/solenv/gbuild/platform/win_compatibility.manifest -outputresource:$(1)\;2 && touch -r $(1) $(WORKDIR)/LinkTarget/$(2).manifest $(ILIBTARGET); fi) \
$(if $(filter Executable,$(TARGETTYPE)),&& if [ -f $(WORKDIR)/LinkTarget/$(2).manifest ]; then mt.exe $(MTFLAGS) -nologo -manifest $(WORKDIR)/LinkTarget/$(2).manifest $(SRCDIR)/solenv/gbuild/platform/win_compatibility.manifest -outputresource:$(1)\;1 && touch -r $(1) $(WORKDIR)/LinkTarget/$(2).manifest; fi) \
diff --git a/solenv/gbuild/platform/com_MSC_defs.mk b/solenv/gbuild/platform/com_MSC_defs.mk
index 9c0425c7efec..8ba47447df32 100644
--- a/solenv/gbuild/platform/com_MSC_defs.mk
+++ b/solenv/gbuild/platform/com_MSC_defs.mk
@@ -279,10 +279,6 @@ define gb_create_deps
endef
endif
-define gb_filter_link_output
-| LC_ALL=C $(GBUILDDIR)/platform/filter-creatingLibrary.awk; exit $${PIPESTATUS[0]}
-endef
-
gb_LTOFLAGS := $(if $(filter TRUE,$(ENABLE_LTO)),-GL)
# When compiling for CLR, disable "warning C4339: use of undefined type detected
diff --git a/solenv/gbuild/platform/filter-creatingLibrary.awk b/solenv/gbuild/platform/filter-creatingLibrary.awk
index 943ba64179e3..5b3335ce8724 100755
--- a/solenv/gbuild/platform/filter-creatingLibrary.awk
+++ b/solenv/gbuild/platform/filter-creatingLibrary.awk
@@ -14,13 +14,13 @@
BEGIN {
creatinglibrary_prefix = ENVIRON["CREATINGLIBRARY_PREFIX"];
if (!creatinglibrary_prefix) {
- creatinglibrary_prefix = " Creating library "
+ creatinglibrary_prefix = "\\.lib.*\\.exp"
}
firstline = 1
}
{
- if (firstline && index($0, creatinglibrary_prefix) == 1) {
+ if (firstline && match($0, creatinglibrary_prefix)) {
# ignore
} else {
# because MSVC stupidly prints errors on stdout, it's