You've already forked linuxdeploy-plugin-qt
mirror of
https://github.com/encounter/linuxdeploy-plugin-qt.git
synced 2026-03-30 11:19:03 -07:00
Compare commits
44 Commits
restructuring
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
| 43c69b060a | |||
| 5ade129a31 | |||
| 271d4ccfc9 | |||
| c260677976 | |||
| 63271d9a74 | |||
| a0eaec1cf8 | |||
| 87bc4b91ce | |||
| 4a6e8becc0 | |||
| 2898217d2c | |||
| 222c61461d | |||
| 49dc10da1e | |||
| 869b4dc7c4 | |||
| 5f8bb819cc | |||
| 44c1801c72 | |||
| 7bc917177d | |||
| f4450743ae | |||
| f292cc79ab | |||
| 56f4194d23 | |||
| 8c9040e5de | |||
| 7bc81ef559 | |||
| 4b43bc5d13 | |||
| 230cdb37c3 | |||
| c370ffac77 | |||
| 808c206559 | |||
| bae08f8592 | |||
| d245b4dc0f | |||
| 7bc321ec8e | |||
| 84797c0e05 | |||
| 84fc3d792f | |||
| 04d96e1c4f | |||
| 95529160f7 | |||
| d0e65fbef9 | |||
| 8f37917e42 | |||
| fcf096aca8 | |||
| fd3287b325 | |||
| dd2e714b32 | |||
| 752c5f199e | |||
| 70ca710c11 | |||
| 3907c42080 | |||
| 4d26eb6d1d | |||
| 6377a6f453 | |||
| bed665d924 | |||
| 17beb503b0 | |||
| ed38c45be4 |
@@ -0,0 +1,99 @@
|
|||||||
|
name: CI
|
||||||
|
|
||||||
|
on: [push, pull_request, workflow_dispatch]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
appimage-x86_64:
|
||||||
|
name: Build x86_64 AppImage on CentOS 7
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
env:
|
||||||
|
ARCH: x86_64
|
||||||
|
BUILD_TYPE: centos7
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
|
submodules: recursive
|
||||||
|
- name: Build AppImage in CentOS 7
|
||||||
|
run: ci/build-centos7-docker.sh
|
||||||
|
- name: Archive artifacts
|
||||||
|
uses: actions/upload-artifact@v2
|
||||||
|
with:
|
||||||
|
name: AppImage x86_64
|
||||||
|
path: linuxdeploy-plugin-qt*.AppImage*
|
||||||
|
|
||||||
|
appimage-i386:
|
||||||
|
name: Build i386 AppImage on CentOS 7
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
env:
|
||||||
|
ARCH: i386
|
||||||
|
BUILD_TYPE: centos7
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
|
submodules: recursive
|
||||||
|
- name: Build AppImage in CentOS 7
|
||||||
|
run: ci/build-centos7-docker.sh
|
||||||
|
- name: Archive artifacts
|
||||||
|
uses: actions/upload-artifact@v2
|
||||||
|
with:
|
||||||
|
name: AppImage i386
|
||||||
|
path: linuxdeploy-plugin-qt*.AppImage*
|
||||||
|
|
||||||
|
# TODO: build and test on i386 as well!
|
||||||
|
build-text-xenial-x86_64:
|
||||||
|
name: Build and test on Ubuntu xenial x86_64 (no binaries uploaded)
|
||||||
|
runs-on: ubuntu-16.04
|
||||||
|
env:
|
||||||
|
ARCH: x86_64
|
||||||
|
BUILD_TYPE: test
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
|
submodules: recursive
|
||||||
|
- name: Install dependencies
|
||||||
|
run: bash ci/install-dependencies.sh
|
||||||
|
- name: Build and install patchelf
|
||||||
|
run: bash -ex ci/install-patchelf.sh
|
||||||
|
- name: Build and test AppImage
|
||||||
|
run: |
|
||||||
|
bash -ex ci/build.sh
|
||||||
|
bash -xe ci/test.sh linuxdeploy-plugin-qt-"$ARCH".AppImage
|
||||||
|
|
||||||
|
# TODO: build and test on i386 as well!
|
||||||
|
build-text-bionic-x86_64:
|
||||||
|
name: Build and test on Ubuntu bionic x86_64 (no binaries uploaded)
|
||||||
|
runs-on: ubuntu-18.04
|
||||||
|
env:
|
||||||
|
ARCH: x86_64
|
||||||
|
BUILD_TYPE: test
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
|
submodules: recursive
|
||||||
|
- name: Install dependencies
|
||||||
|
run: bash ci/install-dependencies.sh
|
||||||
|
- name: Build and install patchelf
|
||||||
|
run: bash -ex ci/install-patchelf.sh
|
||||||
|
- name: Build and test AppImage
|
||||||
|
run: |
|
||||||
|
bash -ex ci/build.sh
|
||||||
|
bash -xe ci/test.sh linuxdeploy-plugin-qt-"$ARCH".AppImage
|
||||||
|
|
||||||
|
upload:
|
||||||
|
name: Create release and upload artifacts
|
||||||
|
needs:
|
||||||
|
- appimage-x86_64
|
||||||
|
- appimage-i386
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Download artifacts
|
||||||
|
uses: actions/download-artifact@v2
|
||||||
|
- name: Inspect directory after downloading artifacts
|
||||||
|
run: ls -alFR
|
||||||
|
- name: Create release and upload artifacts
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
run: |
|
||||||
|
wget -q https://github.com/TheAssassin/pyuploadtool/releases/download/continuous/pyuploadtool-x86_64.AppImage
|
||||||
|
chmod +x pyuploadtool-x86_64.AppImage
|
||||||
|
./pyuploadtool-x86_64.AppImage **/linuxdeploy-plugin-qt*.AppImage*
|
||||||
@@ -1,2 +1,5 @@
|
|||||||
*build*/
|
*build*/
|
||||||
.idea/
|
.idea/
|
||||||
|
*.AppImage
|
||||||
|
*.zsync
|
||||||
|
*.swp
|
||||||
|
|||||||
-68
@@ -1,68 +0,0 @@
|
|||||||
language: cpp
|
|
||||||
sudo: required
|
|
||||||
dist: xenial
|
|
||||||
|
|
||||||
matrix:
|
|
||||||
include:
|
|
||||||
- env: ARCH=x86_64
|
|
||||||
addons:
|
|
||||||
apt:
|
|
||||||
update: true
|
|
||||||
sources:
|
|
||||||
- sourceline: 'ppa:beineri/opt-qt-5.12.3-xenial'
|
|
||||||
packages:
|
|
||||||
- libmagic-dev
|
|
||||||
- libjpeg-dev
|
|
||||||
- libpng-dev
|
|
||||||
- cimg-dev
|
|
||||||
- automake # required for patchelf
|
|
||||||
- gcc
|
|
||||||
- g++
|
|
||||||
# Packages below are only required by the test srcipt
|
|
||||||
- qt512-meta-minimal
|
|
||||||
- qt512declarative
|
|
||||||
- qt512webengine
|
|
||||||
- mesa-common-dev
|
|
||||||
- libgl1-mesa-dev # <-- that's for xenial to provide the x86_64-linux-gnu/libGL.so symlink
|
|
||||||
- # libglvnd-dev # <-- that's for bionic to provide aforementioned symlink
|
|
||||||
- env: ARCH=i386
|
|
||||||
addons:
|
|
||||||
apt:
|
|
||||||
update: true
|
|
||||||
packages:
|
|
||||||
- libmagic-dev:i386
|
|
||||||
- libjpeg-dev:i386
|
|
||||||
- libpng-dev:i386
|
|
||||||
- automake # required for patchelf
|
|
||||||
- libfuse2:i386
|
|
||||||
- libcairo2:i386
|
|
||||||
- gcc-multilib
|
|
||||||
- g++-multilib
|
|
||||||
|
|
||||||
install:
|
|
||||||
- git clone https://github.com/NixOS/patchelf.git -b 0.8
|
|
||||||
- cd patchelf
|
|
||||||
- ./bootstrap.sh
|
|
||||||
- if [ "$ARCH" == "i386" ]; then export EXTRA_CONFIGURE_ARGS=("--build=i686-pc-linux-gnu" "CFLAGS=-m32" "CXXFLAGS=-m32" "LDFLAGS=-m32"); fi
|
|
||||||
- ./configure --prefix=/usr "${EXTRA_CONFIGURE_ARGS[@]}"
|
|
||||||
- make -j$(nproc)
|
|
||||||
- sudo make install
|
|
||||||
- cd ..
|
|
||||||
- rm -rf patchelf
|
|
||||||
|
|
||||||
script:
|
|
||||||
- bash -xe travis/build.sh
|
|
||||||
# TODO: allow for cross-compiling the test projects and install i386 packages for build dependencies, then remove $ARCH check
|
|
||||||
- if [ "$ARCH" == "x86_64" ]; then bash -xe travis/test.sh linuxdeploy-plugin-qt-"$ARCH".AppImage; fi
|
|
||||||
|
|
||||||
after_success:
|
|
||||||
- ls -lh
|
|
||||||
# make sure only pushes to rewrite create a new release, otherwise pretend PR and upload to transfer.sh
|
|
||||||
- if [ "$TRAVIS_TAG" != "$TRAVIS_BRANCH" ] && [ "$TRAVIS_BRANCH" != "master" ]; then export TRAVIS_EVENT_TYPE=pull_request; fi
|
|
||||||
- wget -c https://github.com/probonopd/uploadtool/raw/master/upload.sh
|
|
||||||
- bash upload.sh linuxdeploy*.AppImage*
|
|
||||||
|
|
||||||
branches:
|
|
||||||
except:
|
|
||||||
- # Do not build tags that we create when we upload to GitHub Releases
|
|
||||||
- /^(?i:continuous)$/
|
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
# linuxdeploy-plugin-qt
|
# linuxdeploy-plugin-qt
|
||||||
|
|
||||||
Plugin for linuxdeploy to bundle Qt dependencies of applications and libraries.
|
Plugin for linuxdeploy to bundle Qt dependencies of applications and libraries. It supports the Qt versions 5 and 6.
|
||||||
|
|
||||||
|
|
||||||
## About
|
## About
|
||||||
@@ -59,5 +59,5 @@ Just like all linuxdeploy plugins, the Qt plugin's behavior can be configured so
|
|||||||
- `$EXTRA_QT_PLUGINS=pluginA;pluginB`: Plugins to deploy even if not found automatically by linuxdeploy-plugin-qt
|
- `$EXTRA_QT_PLUGINS=pluginA;pluginB`: Plugins to deploy even if not found automatically by linuxdeploy-plugin-qt
|
||||||
|
|
||||||
QML related:
|
QML related:
|
||||||
- `$QML_SOURCES_PATHS`: directory containing the application's QML files -- useful/needed if QML files are "baked" into the binaries
|
- `$QML_SOURCES_PATHS`: directory containing the application's QML files — useful/needed if QML files are "baked" into the binaries. `$QT_INSTALL_QML` is prepended to this list internally.
|
||||||
- `$QML_MODULES_PATHS`: extra directories containing imported QML files (normally doesn't need to be specified)
|
- `$QML_MODULES_PATHS`: extra directories containing imported QML files (normally doesn't need to be specified).
|
||||||
|
|||||||
@@ -0,0 +1,23 @@
|
|||||||
|
FROM centos:7
|
||||||
|
|
||||||
|
RUN yum install -y centos-release-scl && \
|
||||||
|
yum install -y devtoolset-8 wget curl patchelf vim-common fuse libfuse2 libtool autoconf automake zlib-devel libjpeg-devel libpng-devel nano git file gcc-c++ && \
|
||||||
|
wget https://artifacts.assassinate-you.net/prebuilt-cmake/cmake-v3.19.1-centos7-x86_64.tar.gz -O- | tar xz --strip-components=1 -C/usr/local
|
||||||
|
|
||||||
|
ENV ARCH=x86_64
|
||||||
|
COPY entrypoint.sh /
|
||||||
|
SHELL ["/entrypoint.sh", "bash", "-x", "-c"]
|
||||||
|
ENTRYPOINT ["/entrypoint.sh"]
|
||||||
|
|
||||||
|
RUN git clone https://github.com/NixOS/patchelf.git && \
|
||||||
|
pushd patchelf && \
|
||||||
|
# cannot use -b since it's not supported in really old versions of git
|
||||||
|
git checkout 0.8 && \
|
||||||
|
./bootstrap.sh && \
|
||||||
|
./configure --prefix=/usr/local && \
|
||||||
|
make -j $(nproc) && \
|
||||||
|
make install && \
|
||||||
|
popd && \
|
||||||
|
rm -r patchelf/
|
||||||
|
|
||||||
|
CMD ["bash"]
|
||||||
@@ -0,0 +1,35 @@
|
|||||||
|
FROM i386/centos:7
|
||||||
|
|
||||||
|
SHELL ["/bin/bash", "-x", "-c"]
|
||||||
|
|
||||||
|
# during Docker build, yum doesn't detect it's an i386 environment on x86_64 machines, and tries to install x86_64 packages, which can't work
|
||||||
|
# this little command fixes this
|
||||||
|
RUN sed -i 's/$basearch/i386/g' /etc/yum.repos.d/CentOS-Base.repo
|
||||||
|
|
||||||
|
# thanks CloudLinux, you're really helping us poor AppImage creators seeking for maximum compatibility by providing devtoolset i386 builds
|
||||||
|
RUN yum install -y yum-utils && \
|
||||||
|
rpm --import https://repo.cloudlinux.com/cloudlinux/security/RPM-GPG-KEY-CloudLinux && \
|
||||||
|
yum-config-manager --add-repo https://www.repo.cloudlinux.com/cloudlinux/7/sclo/devtoolset-8/i386/ && \
|
||||||
|
yum install -y devtoolset-8 wget curl patchelf vim-common fuse libfuse2 libtool autoconf automake zlib-evel libjpeg-devel libpng-devel nano git make file gcc-c++
|
||||||
|
|
||||||
|
# the shell wrapper takes care of enabling devtoolset and running a shell properly
|
||||||
|
# unfortunately this is the easiest and most solid workaround to the limitations of the scl command
|
||||||
|
COPY entrypoint.sh /
|
||||||
|
ENV ARCH=i386
|
||||||
|
ENTRYPOINT ["/entrypoint.sh"]
|
||||||
|
SHELL ["/entrypoint.sh", "bash", "-x", "-c"]
|
||||||
|
|
||||||
|
RUN wget https://artifacts.assassinate-you.net/prebuilt-cmake/cmake-v3.19.1-centos7-i386.tar.gz -O- | tar xz --strip-components=1 -C/usr/local
|
||||||
|
|
||||||
|
RUN git clone https://github.com/NixOS/patchelf.git && \
|
||||||
|
pushd patchelf && \
|
||||||
|
# cannot use -b since it's not supported in really old versions of git
|
||||||
|
git checkout 0.8 && \
|
||||||
|
./bootstrap.sh && \
|
||||||
|
./configure --prefix=/usr/local && \
|
||||||
|
make -j $(nproc) && \
|
||||||
|
make install && \
|
||||||
|
popd && \
|
||||||
|
rm -r patchelf/
|
||||||
|
|
||||||
|
CMD ["bash"]
|
||||||
Executable
+18
@@ -0,0 +1,18 @@
|
|||||||
|
#! /bin/bash
|
||||||
|
|
||||||
|
set -xe
|
||||||
|
|
||||||
|
old_cwd=$(readlink -f .)
|
||||||
|
here=$(readlink -f $(dirname "$0"))
|
||||||
|
|
||||||
|
DOCKERFILE="$here"/Dockerfile.centos7
|
||||||
|
IMAGE=linuxdeploy-build-centos7
|
||||||
|
|
||||||
|
if [ "$ARCH" == "i386" ]; then
|
||||||
|
DOCKERFILE="$DOCKERFILE"-i386
|
||||||
|
IMAGE="$IMAGE"-i386
|
||||||
|
fi
|
||||||
|
|
||||||
|
(cd "$here" && docker build -f "$DOCKERFILE" -t "$IMAGE" .)
|
||||||
|
|
||||||
|
docker run --rm -i -v "$here"/..:/ws:ro -v "$old_cwd":/out -e CI=1 -e OUTDIR_OWNER=$(id -u) "$IMAGE" /bin/bash -xe -c "cd /out && /ws/ci/build-centos7.sh"
|
||||||
Executable
+59
@@ -0,0 +1,59 @@
|
|||||||
|
#! /bin/bash
|
||||||
|
|
||||||
|
set -e
|
||||||
|
set -x
|
||||||
|
|
||||||
|
if [ "$ARCH" == "" ]; then
|
||||||
|
echo 'Error: $ARCH is not set'
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# use RAM disk if possible
|
||||||
|
if [ "$CI" == "" ] && [ -d /dev/shm ]; then
|
||||||
|
TEMP_BASE=/dev/shm
|
||||||
|
else
|
||||||
|
TEMP_BASE=/tmp
|
||||||
|
fi
|
||||||
|
|
||||||
|
BUILD_DIR=$(mktemp -d -p "$TEMP_BASE" linuxdeploy-plugin-qt-build-XXXXXX)
|
||||||
|
|
||||||
|
cleanup () {
|
||||||
|
if [ -d "$BUILD_DIR" ]; then
|
||||||
|
rm -rf "$BUILD_DIR"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
trap cleanup EXIT
|
||||||
|
|
||||||
|
# store repo root as variable
|
||||||
|
REPO_ROOT=$(readlink -f $(dirname $(dirname "$0")))
|
||||||
|
OLD_CWD=$(readlink -f .)
|
||||||
|
|
||||||
|
pushd "$BUILD_DIR"
|
||||||
|
|
||||||
|
cmake "$REPO_ROOT" -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=RelWithDebInfo "${EXTRA_CMAKE_ARGS[@]}" -DUSE_SYSTEM_CIMG=Off
|
||||||
|
|
||||||
|
make -j$(nproc)
|
||||||
|
|
||||||
|
ctest -V
|
||||||
|
|
||||||
|
make install DESTDIR=AppDir
|
||||||
|
|
||||||
|
strip_path=$(which strip)
|
||||||
|
|
||||||
|
export UPD_INFO="gh-releases-zsync|linuxdeploy|linuxdeploy-plugin-qt|continuous|linuxdeploy-plugin-qt-$ARCH.AppImage"
|
||||||
|
|
||||||
|
# we're in Docker...
|
||||||
|
export APPIMAGE_EXTRACT_AND_RUN=1
|
||||||
|
|
||||||
|
wget https://github.com/TheAssassin/linuxdeploy/releases/download/continuous/linuxdeploy-"$ARCH".AppImage
|
||||||
|
chmod +x linuxdeploy*.AppImage
|
||||||
|
sed -i 's|AI\x02|\x00\x00\x00|' *.AppImage
|
||||||
|
./linuxdeploy-"$ARCH".AppImage --appdir AppDir \
|
||||||
|
-d "$REPO_ROOT"/resources/linuxdeploy-plugin-qt.desktop \
|
||||||
|
-i "$REPO_ROOT"/resources/linuxdeploy-plugin-qt.svg \
|
||||||
|
-e $(which patchelf) \
|
||||||
|
-e "$strip_path" \
|
||||||
|
--output appimage
|
||||||
|
|
||||||
|
mv linuxdeploy-plugin-qt-"$ARCH".AppImage* "$OLD_CWD"/
|
||||||
@@ -26,7 +26,7 @@ cleanup () {
|
|||||||
trap cleanup EXIT
|
trap cleanup EXIT
|
||||||
|
|
||||||
# store repo root as variable
|
# store repo root as variable
|
||||||
REPO_ROOT=$(readlink -f $(dirname $(dirname $0)))
|
REPO_ROOT=$(readlink -f $(dirname $(dirname "$0")))
|
||||||
OLD_CWD=$(readlink -f .)
|
OLD_CWD=$(readlink -f .)
|
||||||
|
|
||||||
pushd "$BUILD_DIR"
|
pushd "$BUILD_DIR"
|
||||||
@@ -70,4 +70,4 @@ chmod +x linuxdeploy*.AppImage
|
|||||||
-e "$strip_path" \
|
-e "$strip_path" \
|
||||||
--output appimage
|
--output appimage
|
||||||
|
|
||||||
mv linuxdeploy-plugin-qt-"$ARCH".AppImage "$OLD_CWD"/
|
mv linuxdeploy-plugin-qt-"$ARCH".AppImage* "$OLD_CWD"/
|
||||||
Executable
+9
@@ -0,0 +1,9 @@
|
|||||||
|
#! /bin/bash
|
||||||
|
|
||||||
|
# get a compiler that allows for using modern-ish C++ (>= 11) on a distro that doesn't normally support it
|
||||||
|
# before you ask: yes, the binaries will work on CentOS 6 even without devtoolset (they somehow partially link C++
|
||||||
|
# things statically while using others from the system...)
|
||||||
|
# so, basically, it's magic!
|
||||||
|
source /opt/rh/devtoolset-*/enable
|
||||||
|
|
||||||
|
exec "$@"
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
#! /bin/bash
|
||||||
|
|
||||||
|
set -e
|
||||||
|
set -x
|
||||||
|
|
||||||
|
ubuntu_release="$(cat /etc/*release | grep -E '^DISTRIB_CODENAME=' | cut -d= -f2-)"
|
||||||
|
|
||||||
|
sudo add-apt-repository -y ppa:beineri/opt-qt-5.14.2-"$ubuntu_release"
|
||||||
|
sudo apt-get update
|
||||||
|
|
||||||
|
packages=(
|
||||||
|
libmagic-dev libjpeg-dev libpng-dev cimg-dev mesa-common-dev
|
||||||
|
|
||||||
|
# dependencies of patchelf
|
||||||
|
automake gcc g++
|
||||||
|
|
||||||
|
# up to date Qt with required plugins
|
||||||
|
qt514-meta-minimal qt514declarative qt514webengine
|
||||||
|
)
|
||||||
|
|
||||||
|
if [[ "$ubuntu_release" == "xenial" ]]; then
|
||||||
|
packages+=(libgl1-mesa-dev)
|
||||||
|
else
|
||||||
|
packages+=(libglvnd-dev)
|
||||||
|
fi
|
||||||
|
|
||||||
|
sudo apt-get install -y "${packages[@]}"
|
||||||
@@ -0,0 +1,36 @@
|
|||||||
|
#! /bin/bash
|
||||||
|
|
||||||
|
if [[ "$CI" == "" ]]; then
|
||||||
|
echo "Error: this script is supposed to be run in a (disposable) CI environment"
|
||||||
|
exit 2
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ "$ARCH" == "" ]]; then
|
||||||
|
echo "Usage: env ARCH=... bash $0"
|
||||||
|
exit 3
|
||||||
|
fi
|
||||||
|
|
||||||
|
build_dir="$(mktemp -d /tmp/patchelf-build-XXXXX)"
|
||||||
|
|
||||||
|
cleanup() {
|
||||||
|
rm -rf "$build_dir"
|
||||||
|
}
|
||||||
|
trap cleanup EXIT
|
||||||
|
|
||||||
|
pushd "$build_dir"
|
||||||
|
|
||||||
|
git clone https://github.com/NixOS/patchelf.git -b 0.8 .
|
||||||
|
|
||||||
|
./bootstrap.sh
|
||||||
|
|
||||||
|
EXTRA_CONFIGURE_ARGS=()
|
||||||
|
|
||||||
|
if [ "$ARCH" == "i386" ]; then
|
||||||
|
export EXTRA_CONFIGURE_ARGS=("--build=i686-pc-linux-gnu" "CFLAGS=-m32" "CXXFLAGS=-m32" "LDFLAGS=-m32")
|
||||||
|
fi
|
||||||
|
|
||||||
|
./configure --prefix=/usr "${EXTRA_CONFIGURE_ARGS[@]}"
|
||||||
|
|
||||||
|
make -j$(nproc)
|
||||||
|
|
||||||
|
sudo make install
|
||||||
+1
-1
Submodule lib/linuxdeploy updated: 6bc354bacb...c45cd46319
+2
-1
@@ -1,4 +1,5 @@
|
|||||||
add_library(linuxdeploy-plugin-qt_util OBJECT util.cpp util.h)
|
# TODO: CMake <= 3.7 (at least!) doesn't allow for using OBJECT libraries with target_link_libraries
|
||||||
|
add_library(linuxdeploy-plugin-qt_util STATIC util.cpp util.h)
|
||||||
target_include_directories(linuxdeploy-plugin-qt_util PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
|
target_include_directories(linuxdeploy-plugin-qt_util PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
|
||||||
target_link_libraries(linuxdeploy-plugin-qt_util linuxdeploy_core args)
|
target_link_libraries(linuxdeploy-plugin-qt_util linuxdeploy_core args)
|
||||||
|
|
||||||
|
|||||||
@@ -16,9 +16,12 @@ set(CLASSES
|
|||||||
QmlPluginsDeployer
|
QmlPluginsDeployer
|
||||||
Qt3DPluginsDeployer
|
Qt3DPluginsDeployer
|
||||||
GamepadPluginsDeployer
|
GamepadPluginsDeployer
|
||||||
|
PrintSupportPluginsDeployer
|
||||||
|
TextToSpeechPluginsDeployer
|
||||||
)
|
)
|
||||||
|
|
||||||
add_library(deployers OBJECT)
|
# TODO: CMake <= 3.7 (at least!) doesn't allow for using OBJECT libraries with target_link_libraries
|
||||||
|
add_library(deployers STATIC)
|
||||||
|
|
||||||
target_link_libraries(deployers PUBLIC linuxdeploy_core linuxdeploy-plugin-qt_util)
|
target_link_libraries(deployers PUBLIC linuxdeploy_core linuxdeploy-plugin-qt_util)
|
||||||
|
|
||||||
|
|||||||
@@ -57,25 +57,26 @@ bool PlatformPluginsDeployer::deploy() {
|
|||||||
// either loading succeeds, then the system Gtk shall be used anyway, otherwise loading fails and Qt will fall
|
// either loading succeeds, then the system Gtk shall be used anyway, otherwise loading fails and Qt will fall
|
||||||
// back to the default UI theme
|
// back to the default UI theme
|
||||||
// we don't care whether this works (it's an experimental feature), therefore we ignore the return values
|
// we don't care whether this works (it's an experimental feature), therefore we ignore the return values
|
||||||
const auto libqgtk2Filename = "libqgtk2.so";
|
const auto libqgtk2Path = platformThemesPath / "libqgtk2.so";
|
||||||
const auto libqgtk2styleFilename = "libqgtk2style.so";
|
const auto libqgtk3Path = platformThemesPath / "libqgtk3.so";
|
||||||
|
const auto libqxdgPath = platformThemesPath / "libqxdgdesktopportal.so";
|
||||||
const auto libqgtk2Path = platformThemesPath / libqgtk2Filename;
|
|
||||||
const auto libqgtk2stylePath = stylesPath / libqgtk2styleFilename;
|
|
||||||
|
|
||||||
|
for (const auto &file : {libqgtk2Path, libqgtk3Path, libqxdgPath}) {
|
||||||
// we need to check whether the files exist at least, otherwise the deferred deployment operation fails
|
// we need to check whether the files exist at least, otherwise the deferred deployment operation fails
|
||||||
if (bf::is_regular_file(libqgtk2Path)) {
|
if (bf::is_regular_file(file)) {
|
||||||
ldLog() << "Attempting to deploy" << libqgtk2Filename << "found at path" << libqgtk2Path << std::endl;
|
ldLog() << "Attempting to deploy" << file.filename() << "found at path" << file.parent_path() << std::endl;
|
||||||
appDir.deployFile(libqgtk2Path, platformThemesDestination);
|
appDir.deployFile(file, platformThemesDestination);
|
||||||
} else {
|
} else {
|
||||||
ldLog() << "Could not find" << libqgtk2Filename << "on system, skipping deployment" << std::endl;
|
ldLog() << "Could not find" << file.filename() << "on system, skipping deployment" << std::endl;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const auto libqgtk2stylePath = stylesPath / "libqgtk2style.so";
|
||||||
if (bf::is_regular_file(libqgtk2stylePath)) {
|
if (bf::is_regular_file(libqgtk2stylePath)) {
|
||||||
ldLog() << "Attempting to deploy" << libqgtk2styleFilename << "found at path" << libqgtk2stylePath << std::endl;
|
ldLog() << "Attempting to deploy" << libqgtk2stylePath.filename() << "found at path" << libqgtk2stylePath << std::endl;
|
||||||
appDir.deployFile(libqgtk2stylePath, stylesDestination);
|
appDir.deployFile(libqgtk2stylePath, stylesDestination);
|
||||||
} else {
|
} else {
|
||||||
ldLog() << "Could not find" << libqgtk2styleFilename << "on system, skipping deployment" << std::endl;
|
ldLog() << "Could not find" << libqgtk2stylePath.filename() << "on system, skipping deployment" << std::endl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -5,12 +5,15 @@
|
|||||||
#include "BearerPluginsDeployer.h"
|
#include "BearerPluginsDeployer.h"
|
||||||
#include "GamepadPluginsDeployer.h"
|
#include "GamepadPluginsDeployer.h"
|
||||||
#include "MultimediaPluginsDeployer.h"
|
#include "MultimediaPluginsDeployer.h"
|
||||||
|
#include "PrintSupportPluginsDeployer.h"
|
||||||
#include "PositioningPluginsDeployer.h"
|
#include "PositioningPluginsDeployer.h"
|
||||||
#include "QmlPluginsDeployer.h"
|
#include "QmlPluginsDeployer.h"
|
||||||
#include "Qt3DPluginsDeployer.h"
|
#include "Qt3DPluginsDeployer.h"
|
||||||
#include "SqlPluginsDeployer.h"
|
#include "SqlPluginsDeployer.h"
|
||||||
#include "SvgPluginsDeployer.h"
|
#include "SvgPluginsDeployer.h"
|
||||||
|
#include "TextToSpeechPluginsDeployer.h"
|
||||||
#include "WebEnginePluginsDeployer.h"
|
#include "WebEnginePluginsDeployer.h"
|
||||||
|
#include "XcbglIntegrationPluginsDeployer.h"
|
||||||
|
|
||||||
using namespace linuxdeploy::plugin::qt;
|
using namespace linuxdeploy::plugin::qt;
|
||||||
using namespace linuxdeploy::core::appdir;
|
using namespace linuxdeploy::core::appdir;
|
||||||
@@ -21,58 +24,68 @@ PluginsDeployerFactory::PluginsDeployerFactory(AppDir& appDir,
|
|||||||
bf::path qtLibexecsPath,
|
bf::path qtLibexecsPath,
|
||||||
bf::path qtInstallQmlPath,
|
bf::path qtInstallQmlPath,
|
||||||
bf::path qtTranslationsPath,
|
bf::path qtTranslationsPath,
|
||||||
bf::path qtDataPath) : appDir(appDir),
|
bf::path qtDataPath,
|
||||||
|
int qtMajorVersion) : appDir(appDir),
|
||||||
qtPluginsPath(std::move(qtPluginsPath)),
|
qtPluginsPath(std::move(qtPluginsPath)),
|
||||||
qtLibexecsPath(std::move(qtLibexecsPath)),
|
qtLibexecsPath(std::move(qtLibexecsPath)),
|
||||||
qtInstallQmlPath(std::move(qtInstallQmlPath)),
|
qtInstallQmlPath(std::move(qtInstallQmlPath)),
|
||||||
qtTranslationsPath(std::move(qtTranslationsPath)),
|
qtTranslationsPath(std::move(qtTranslationsPath)),
|
||||||
qtDataPath(std::move(qtDataPath)) {}
|
qtDataPath(std::move(qtDataPath)),
|
||||||
|
qtMajorVersion(qtMajorVersion) {}
|
||||||
|
|
||||||
std::shared_ptr<PluginsDeployer> PluginsDeployerFactory::getInstance(const std::string& moduleName) {
|
std::vector<std::shared_ptr<PluginsDeployer>> PluginsDeployerFactory::getDeployers(const std::string& moduleName) {
|
||||||
if (moduleName == "gui") {
|
if (moduleName == "gui") {
|
||||||
return getInstance<PlatformPluginsDeployer>(moduleName);
|
return {getInstance<PlatformPluginsDeployer>(moduleName), getInstance<XcbglIntegrationPluginsDeployer>(moduleName)};
|
||||||
}
|
}
|
||||||
|
|
||||||
if (moduleName == "opengl" || moduleName == "gui" || moduleName == "xcbqpa") {
|
if (moduleName == "opengl" || moduleName == "xcbqpa") {
|
||||||
return getInstance<PlatformPluginsDeployer>(moduleName);
|
return {getInstance<XcbglIntegrationPluginsDeployer>(moduleName)};
|
||||||
}
|
}
|
||||||
|
|
||||||
if (moduleName == "network") {
|
if (moduleName == "network" && qtMajorVersion < 6) {
|
||||||
return getInstance<BearerPluginsDeployer>(moduleName);
|
return {getInstance<BearerPluginsDeployer>(moduleName)};
|
||||||
}
|
}
|
||||||
|
|
||||||
if (moduleName == "svg") {
|
if (moduleName == "svg") {
|
||||||
return getInstance<SvgPluginsDeployer>(moduleName);
|
return {getInstance<SvgPluginsDeployer>(moduleName)};
|
||||||
}
|
}
|
||||||
|
|
||||||
if (moduleName == "sql") {
|
if (moduleName == "sql") {
|
||||||
return getInstance<SqlPluginsDeployer>(moduleName);
|
return {getInstance<SqlPluginsDeployer>(moduleName)};
|
||||||
}
|
}
|
||||||
|
|
||||||
if (moduleName == "positioning") {
|
if (moduleName == "positioning") {
|
||||||
return getInstance<PositioningPluginsDeployer>(moduleName);
|
return {getInstance<PositioningPluginsDeployer>(moduleName)};
|
||||||
}
|
}
|
||||||
|
|
||||||
if (moduleName == "multimedia") {
|
if (moduleName == "multimedia") {
|
||||||
return getInstance<MultimediaPluginsDeployer>(moduleName);
|
return {getInstance<MultimediaPluginsDeployer>(moduleName)};
|
||||||
}
|
}
|
||||||
|
|
||||||
if (moduleName == "webenginecore") {
|
if (moduleName == "webenginecore") {
|
||||||
return getInstance<WebEnginePluginsDeployer>(moduleName);
|
return {getInstance<WebEnginePluginsDeployer>(moduleName)};
|
||||||
}
|
}
|
||||||
|
|
||||||
if (moduleName == "qml") {
|
if (moduleName == "qml") {
|
||||||
return getInstance<QmlPluginsDeployer>(moduleName);
|
return {getInstance<QmlPluginsDeployer>(moduleName)};
|
||||||
}
|
}
|
||||||
|
|
||||||
if (moduleName == "3dquickrender") {
|
if (moduleName == "3dquickrender" || moduleName == "3drender") {
|
||||||
return getInstance<Qt3DPluginsDeployer>(moduleName);
|
return {getInstance<Qt3DPluginsDeployer>(moduleName)};
|
||||||
}
|
}
|
||||||
|
|
||||||
if (moduleName == "gamepad") {
|
if (moduleName == "gamepad") {
|
||||||
return getInstance<GamepadPluginsDeployer>(moduleName);
|
return {getInstance<GamepadPluginsDeployer>(moduleName)};
|
||||||
|
}
|
||||||
|
|
||||||
|
if (moduleName == "printsupport") {
|
||||||
|
return {getInstance<PrintSupportPluginsDeployer>(moduleName)};
|
||||||
|
}
|
||||||
|
|
||||||
|
if (moduleName == "texttospeech") {
|
||||||
|
return {getInstance<TextToSpeechPluginsDeployer>(moduleName)};
|
||||||
}
|
}
|
||||||
|
|
||||||
// fallback
|
// fallback
|
||||||
return getInstance<BasicPluginsDeployer>(moduleName);
|
return {getInstance<BasicPluginsDeployer>(moduleName)};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -23,6 +23,7 @@ namespace linuxdeploy {
|
|||||||
const boost::filesystem::path qtInstallQmlPath;
|
const boost::filesystem::path qtInstallQmlPath;
|
||||||
const boost::filesystem::path qtTranslationsPath;
|
const boost::filesystem::path qtTranslationsPath;
|
||||||
const boost::filesystem::path qtDataPath;
|
const boost::filesystem::path qtDataPath;
|
||||||
|
const int qtMajorVersion;
|
||||||
|
|
||||||
template<typename T>
|
template<typename T>
|
||||||
std::shared_ptr<PluginsDeployer> getInstance(const std::string& moduleName) {
|
std::shared_ptr<PluginsDeployer> getInstance(const std::string& moduleName) {
|
||||||
@@ -45,9 +46,10 @@ namespace linuxdeploy {
|
|||||||
boost::filesystem::path qtLibexecsPath,
|
boost::filesystem::path qtLibexecsPath,
|
||||||
boost::filesystem::path qtInstallQmlPath,
|
boost::filesystem::path qtInstallQmlPath,
|
||||||
boost::filesystem::path qtTranslationsPath,
|
boost::filesystem::path qtTranslationsPath,
|
||||||
boost::filesystem::path qtDataPath);
|
boost::filesystem::path qtDataPath,
|
||||||
|
int qtMajorVersion);
|
||||||
|
|
||||||
std::shared_ptr<PluginsDeployer> getInstance(const std::string& moduleName);
|
std::vector<std::shared_ptr<PluginsDeployer>> getDeployers(const std::string& moduleName);
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,26 @@
|
|||||||
|
// library headers
|
||||||
|
#include <linuxdeploy/core/log.h>
|
||||||
|
#include <boost/filesystem.hpp>
|
||||||
|
|
||||||
|
// local headers
|
||||||
|
#include "PrintSupportPluginsDeployer.h"
|
||||||
|
|
||||||
|
using namespace linuxdeploy::plugin::qt;
|
||||||
|
using namespace linuxdeploy::core::log;
|
||||||
|
|
||||||
|
namespace bf = boost::filesystem;
|
||||||
|
|
||||||
|
bool PrintSupportPluginsDeployer::deploy() {
|
||||||
|
// calling the default code is optional, but it won't hurt for now
|
||||||
|
if (!BasicPluginsDeployer::deploy())
|
||||||
|
return false;
|
||||||
|
|
||||||
|
ldLog() << "Deploying printsupport plugins" << std::endl;
|
||||||
|
|
||||||
|
for (bf::directory_iterator i(qtPluginsPath / "printsupport"); i != bf::directory_iterator(); ++i) {
|
||||||
|
if (!appDir.deployLibrary(*i, appDir.path() / "usr/plugins/printsupport/"))
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user