aboutsummaryrefslogtreecommitdiffstats
path: root/coin/provisioning/qtci-linux-Ubuntu-16.04-x86_64
diff options
context:
space:
mode:
authorSami Nurmenniemi <sami.nurmenniemi@qt.io>2017-04-12 15:30:43 +0300
committerSimon Hausmann <simon.hausmann@qt.io>2017-04-27 10:25:56 +0000
commit94e22fcd94f94697984263e2e5b018d05085f535 (patch)
tree42ff8501707e0faa39b41775e96af5e7b5b8e611 /coin/provisioning/qtci-linux-Ubuntu-16.04-x86_64
parented39e440a92552c229a038cc5bd1f3b46bb22138 (diff)
Add preparing of qemu fontconfig to Ubuntu 16.04 provisioning
If normal fontconfig paths are used, qemu parses what ever files it finds from the toolchain sysroot and the rest from the system fonts. Fix by copying the system font configurations to a location which prefix that can't be found from the toolchain sysroot. Links must also be dereferenced or their targets remain pointing to the toolchain sysroot. Task-number: QTBUG-59966 Change-Id: I9710c9fdebe81114080f47f1f59b2a049f87c070 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Tony Sarajärvi <tony.sarajarvi@qt.io>
Diffstat (limited to 'coin/provisioning/qtci-linux-Ubuntu-16.04-x86_64')
-rwxr-xr-xcoin/provisioning/qtci-linux-Ubuntu-16.04-x86_64/003-qemu.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/coin/provisioning/qtci-linux-Ubuntu-16.04-x86_64/003-qemu.sh b/coin/provisioning/qtci-linux-Ubuntu-16.04-x86_64/003-qemu.sh
index f978003b..9c906562 100755
--- a/coin/provisioning/qtci-linux-Ubuntu-16.04-x86_64/003-qemu.sh
+++ b/coin/provisioning/qtci-linux-Ubuntu-16.04-x86_64/003-qemu.sh
@@ -64,3 +64,15 @@ sudo update-binfmts --package qemu-arm --install arm \
# doesn't help since host version creates cache for a wrong architecture and running
# armv7 fc-cache segfaults on QEMU.
sudo DEBIAN_FRONTEND=noninteractive apt-get -y remove fonts-noto-cjk
+
+# If normal fontconfig paths are used, qemu parses what ever files it finds from
+# the toolchain sysroot and the rest from the system fonts. Fix by copying the
+# system font configurations to a location which prefix that can't be found from
+# the toolchain sysroot. Links must also be dereferenced or their targets remain
+# pointing to the toolchain sysroot.
+QEMU_FONTCONFPATH=~/qemu_fonts
+QEMU_FONTCONFFILE=$QEMU_FONTCONFPATH/fonts.qemu.conf
+mkdir -p $QEMU_FONTCONFPATH
+cp -Lr /etc/fonts/* $QEMU_FONTCONFPATH
+sed $QEMU_FONTCONFPATH/fonts.conf -e "s:conf.d:$QEMU_FONTCONFPATH/conf.d:" > $QEMU_FONTCONFFILE
+echo "export QEMU_SET_ENV=\"FONTCONFIG_FILE=$QEMU_FONTCONFFILE,FONTCONFIG_PATH=$QEMU_FONTCONFPATH\"" >> ~/.profile