From d55b41ee266d5bfbe7067ed44d47ab37a4e619cc Mon Sep 17 00:00:00 2001 From: Justin Newberry Date: Wed, 25 Oct 2023 14:02:02 -0700 Subject: [PATCH] separate that out --- Dockerfile.agnos | 11 ++++++---- userspace/compile-qtwayland5.sh | 22 +++++++++++++++++++ .../qtwayland/libQt5WaylandClient.so.5.12.8 | 3 --- 3 files changed, 29 insertions(+), 7 deletions(-) create mode 100755 userspace/compile-qtwayland5.sh delete mode 100755 userspace/qtwayland/libQt5WaylandClient.so.5.12.8 diff --git a/Dockerfile.agnos b/Dockerfile.agnos index 2f15f7d1..797445a0 100644 --- a/Dockerfile.agnos +++ b/Dockerfile.agnos @@ -47,6 +47,11 @@ FROM agnos-compiler as agnos-compiler-mapbox-gl-native COPY ./userspace/compile-mapbox-gl-native.sh /tmp/agnos/ RUN /tmp/agnos/compile-mapbox-gl-native.sh +FROM agnos-compiler as agnos-compiler-qtwayland5 +COPY ./userspace/compile-qtwayland5.sh /tmp/agnos/ +COPY ./userspace/qtwayland/patch /tmp/agnos/ +RUN /tmp/agnos/compile-qtwayland5.sh + # ################### # # ###### AGNOS ###### # # ################### # @@ -109,10 +114,8 @@ RUN /tmp/agnos/install_extras.sh COPY ./userspace/qtwayland/libffi.so.6 /lib/aarch64-linux-gnu/ COPY ./userspace/qtwayland/libwayland-client.so.0 /lib/aarch64-linux-gnu/libwayland-client.so.0 -# Patched qtwayland that does not use EGL EXT, and outputs a fixed screen size -# Clone qtwayland submodule, checkout 5.12.9 (5.12.8 leaks timers, see https://bugreports.qt.io/browse/QTBUG-82914), apply patch, qmake, make -COPY ./userspace/qtwayland/libqwayland-egl.so /lib/aarch64-linux-gnu/qt5/plugins/platforms/libqwayland-egl.so -COPY ./userspace/qtwayland/libQt5WaylandClient.so.5.12.8 /lib/aarch64-linux-gnu/libQt5WaylandClient.so.5.12.8 +COPY --from=agnos-compiler-qtwayland5 /tmp/qtwayland5.deb /tmp/qtwayland5.deb +RUN cd /tmp && apt-get -o Dpkg::Options::="--force-overwrite" install -yq --allow-downgrades ./qtwayland5.deb # Patched libeglSubDriverWayland with fixed nullptr deref in CommitBuffer COPY ./userspace/files/libeglSubDriverWayland.so.patched /lib/aarch64-linux-gnu/libeglSubDriverWayland.so diff --git a/userspace/compile-qtwayland5.sh b/userspace/compile-qtwayland5.sh new file mode 100755 index 00000000..0408f89b --- /dev/null +++ b/userspace/compile-qtwayland5.sh @@ -0,0 +1,22 @@ +#!/bin/bash +set -e + +# Patched qtwayland that outputs a fixed screen size +# Clone qtwayland submodule, checkout 5.12.9 (5.12.8 leaks timers, see https://bugreports.qt.io/browse/QTBUG-82914), apply patch, qmake, make + +apt update && apt install -y qt5-qmake qtbase5-dev qtbase5-dev-tools + +cd /tmp +git clone --branch v5.12.9 https://github.com/qt/qtwayland.git +cd qtwayland + +git apply /tmp/agnos/patch + +mkdir /tmp/build && cd /tmp/build +qmake /tmp/qtwayland + +export MAKEFLAGS="-j$(nproc)" +make + +checkinstall -yD --install=no --pkgversion="5.12.8" --pkgname=qtwayland5 --pkgarch=arm64 --replaces=qtwayland5,libqt5waylandclient5,libqt5waylandcompositor5 +mv qtwayland5*.deb /tmp/qtwayland5.deb diff --git a/userspace/qtwayland/libQt5WaylandClient.so.5.12.8 b/userspace/qtwayland/libQt5WaylandClient.so.5.12.8 deleted file mode 100755 index 579b95a0..00000000 --- a/userspace/qtwayland/libQt5WaylandClient.so.5.12.8 +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:450f3b0ab9edad9492d3b28c66472c45226db6f9634e45de439597812388baa4 -size 21755080