Skip to content

Commit 90955c1

Browse files
committed
import dockerfiles
0 parents  commit 90955c1

File tree

3 files changed

+290
-0
lines changed

3 files changed

+290
-0
lines changed

aarch64/Dockerfile

Lines changed: 103 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,103 @@
1+
# RHEL devtoolset, which provides new version of GCC targetting old libgcc_s and libstdc++, is the key to compatibility.
2+
# EL 7 is modern enough for apps and libs.
3+
# CentOS 7 aarch64 container image is a mess. Use Oracle instead.
4+
FROM docker.io/arm64v8/oraclelinux:7
5+
6+
# System
7+
RUN yum-config-manager --enable ol7_optional_latest && \
8+
yum install -y oracle-softwarecollection-release-el7 oracle-epel-release-el7 && \
9+
yum upgrade -y && \
10+
yum install -y \
11+
# general devtools
12+
devtoolset-7-gcc devtoolset-7-gcc-c++ make \
13+
# squashfs-tools libs
14+
libzstd-devel \
15+
# Qt build tools
16+
file which \
17+
# Qt libs
18+
at-spi2-core-devel dbus-devel fontconfig-devel freetype-devel glib2-devel libXrender-devel libxcb-devel libxkbcommon-devel libxkbcommon-x11-devel mesa-libGL-devel wayland-devel xcb-util-devel && \
19+
yum clean all
20+
21+
ARG DEVTOOLSET_ROOTPATH=/opt/rh/devtoolset-7/root
22+
ENV PATH=${DEVTOOLSET_ROOTPATH}/usr/bin:${PATH}
23+
ENV LD_LIBRARY_PATH=${DEVTOOLSET_ROOTPATH}/usr/lib64
24+
25+
ARG SQUASHFS_TOOLS_VERSION=4.4
26+
ARG QT_MAJOR_MINOR=5.12
27+
ARG QT_PATCH=12
28+
ARG QT_VERSION=${QT_MAJOR_MINOR}.${QT_PATCH}
29+
ARG FCITX5_QT_VERSION=5.0.17
30+
ARG ALACRITTY_VERSION=0.12.2
31+
32+
# AppImage runtime
33+
RUN curl -L -o /opt/appimage-runtime 'https://github.com/AppImage/type2-runtime/releases/download/continuous/runtime-aarch64'
34+
35+
# squashfs-tools
36+
RUN mkdir -p /build/squashfs-tools && \
37+
cd /build/squashfs-tools && \
38+
curl -L -o squashfs-tools-${SQUASHFS_TOOLS_VERSION}.tar.gz "https://github.com/plougher/squashfs-tools/archive/refs/tags/${SQUASHFS_TOOLS_VERSION}.tar.gz" && \
39+
tar xf squashfs-tools-${SQUASHFS_TOOLS_VERSION}.tar.gz && \
40+
cd squashfs-tools-${SQUASHFS_TOOLS_VERSION}/squashfs-tools && \
41+
make ZSTD_SUPPORT=1 -j$(nproc) && \
42+
make install && \
43+
# cleanup
44+
cd / && \
45+
rm -r /build/squashfs-tools
46+
47+
# Qt 5
48+
RUN mkdir -p /build/qt5 && \
49+
cd /build/qt5 && \
50+
curl -O "https://download.qt.io/archive/qt/${QT_MAJOR_MINOR}/${QT_VERSION}/submodules/qt{base,svg,tools,wayland}-everywhere-src-${QT_VERSION}.tar.xz" && \
51+
tar xf qtbase-everywhere-src-${QT_VERSION}.tar.xz && \
52+
cd qtbase-everywhere-src-${QT_VERSION} && \
53+
./configure \
54+
-prefix /usr/local \
55+
-opensource -confirm-license \
56+
-optimize-size -no-shared -static -platform linux-g++ -no-use-gold-linker \
57+
-qt-zlib -qt-doubleconversion -iconv -no-icu -qt-pcre -no-openssl -system-freetype -fontconfig -qt-harfbuzz -qt-libjpeg -qt-libpng -qt-xcb -qt-sqlite \
58+
-nomake examples -nomake tests -nomake tools && \
59+
make -j$(nproc) && \
60+
make install && \
61+
# svg package
62+
cd /build/qt5 && \
63+
tar xf qtsvg-everywhere-src-${QT_VERSION}.tar.xz && \
64+
cd qtsvg-everywhere-src-${QT_VERSION} && \
65+
qmake . && \
66+
make -j$(nproc) && \
67+
make install && \
68+
# tools package
69+
cd /build/qt5 && \
70+
tar xf qttools-everywhere-src-${QT_VERSION}.tar.xz && \
71+
cd qttools-everywhere-src-${QT_VERSION} && \
72+
qmake . && \
73+
make -j$(nproc) && \
74+
make install && \
75+
# wayland package
76+
cd /build/qt5 && \
77+
tar xf qtwayland-everywhere-src-${QT_VERSION}.tar.xz && \
78+
cd qtwayland-everywhere-src-${QT_VERSION} && \
79+
qmake . && \
80+
make -j$(nproc) && \
81+
make install && \
82+
# cleanup
83+
cd / && \
84+
rm -r /build/qt5
85+
86+
# fcitx5-qt
87+
RUN yum install -y \
88+
cmake3 extra-cmake-modules && \
89+
mkdir -p /build/qt5 && \
90+
cd /build/qt5 && \
91+
curl -L -o fcitx5-qt-${FCITX5_QT_VERSION}.tar.gz "https://github.com/fcitx/fcitx5-qt/archive/refs/tags/${FCITX5_QT_VERSION}.tar.gz" && \
92+
tar xf fcitx5-qt-${FCITX5_QT_VERSION}.tar.gz && \
93+
cd fcitx5-qt-${FCITX5_QT_VERSION} && \
94+
cmake3 . -Bbuild -DCMAKE_MODULE_PATH=/usr/local/lib/cmake -DCMAKE_PREFIX_PATH=/usr/local -DCMAKE_BUILD_TYPE=Release -DENABLE_QT4=Off -DENABLE_QT5=On -DENABLE_QT6=Off -DBUILD_ONLY_PLUGIN=On -DBUILD_STATIC_PLUGIN=On && \
95+
cmake3 --build build --parallel && \
96+
# cmake 3.14 is too old to `--install`
97+
cmake3 --build build -- install && \
98+
# cleanup
99+
yum autoremove -y \
100+
cmake3 extra-cmake-modules && \
101+
yum clean all && \
102+
cd / && \
103+
rm -r /build/qt5

riscv64/Dockerfile

Lines changed: 87 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,87 @@
1+
FROM docker.io/riscv64/ubuntu:20.04
2+
3+
# System
4+
RUN export DEBIAN_FRONTEND=noninteractive && \
5+
apt update && \
6+
apt upgrade -y && \
7+
apt install --no-install-recommends -y \
8+
# general utils
9+
ca-certificates curl xz-utils \
10+
# general devtools
11+
gcc g++ make \
12+
# Qt build tools
13+
file \
14+
# Qt libs
15+
libatspi2.0-dev libdbus-1-dev libfontconfig1-dev libfreetype6-dev libgl1-mesa-dev libwayland-dev libxkbcommon-x11-dev \
16+
# appimage tools
17+
squashfs-tools && \
18+
apt clean && \
19+
rm -rf /var/lib/apt/lists/*
20+
21+
ARG QT_MAJOR_MINOR=5.12
22+
ARG QT_PATCH=12
23+
ARG QT_VERSION=${QT_MAJOR_MINOR}.${QT_PATCH}
24+
ARG FCITX5_QT_VERSION=5.0.17
25+
ARG ALACRITTY_VERSION=0.12.2
26+
27+
# AppImage runtime
28+
RUN curl -L -o /opt/appimage-runtime 'https://github.com/cyano-linux/appimage-riscv64/releases/download/20230808.0/runtime-riscv64'
29+
30+
# Qt 5
31+
RUN mkdir -p /build/qt5 && \
32+
cd /build/qt5 && \
33+
curl -O "https://download.qt.io/archive/qt/${QT_MAJOR_MINOR}/${QT_VERSION}/submodules/qt{base,svg,tools,wayland}-everywhere-src-${QT_VERSION}.tar.xz" && \
34+
tar xf qtbase-everywhere-src-${QT_VERSION}.tar.xz && \
35+
cd qtbase-everywhere-src-${QT_VERSION} && \
36+
./configure \
37+
-prefix /usr/local \
38+
-opensource -confirm-license \
39+
-optimize-size -no-shared -static -platform linux-g++ -no-use-gold-linker \
40+
-qt-zlib -qt-doubleconversion -iconv -no-icu -qt-pcre -no-openssl -system-freetype -fontconfig -qt-harfbuzz -qt-libjpeg -qt-libpng -qt-xcb -qt-sqlite \
41+
-nomake examples -nomake tests -nomake tools && \
42+
make -j$(nproc) && \
43+
make install && \
44+
# svg package
45+
cd /build/qt5 && \
46+
tar xf qtsvg-everywhere-src-${QT_VERSION}.tar.xz && \
47+
cd qtsvg-everywhere-src-${QT_VERSION} && \
48+
qmake . && \
49+
make -j$(nproc) && \
50+
make install && \
51+
# tools package
52+
cd /build/qt5 && \
53+
tar xf qttools-everywhere-src-${QT_VERSION}.tar.xz && \
54+
cd qttools-everywhere-src-${QT_VERSION} && \
55+
qmake . && \
56+
make -j$(nproc) && \
57+
make install && \
58+
# wayland package
59+
cd /build/qt5 && \
60+
tar xf qtwayland-everywhere-src-${QT_VERSION}.tar.xz && \
61+
cd qtwayland-everywhere-src-${QT_VERSION} && \
62+
qmake . && \
63+
make -j$(nproc) && \
64+
make install && \
65+
# cleanup
66+
cd / && \
67+
rm -r /build/qt5
68+
69+
# fcitx5-qt
70+
RUN export DEBIAN_FRONTEND=noninteractive && \
71+
apt update && \
72+
apt install --no-install-recommends -y \
73+
cmake extra-cmake-modules && \
74+
mkdir -p /build/qt5 && \
75+
cd /build/qt5 && \
76+
curl -L -o fcitx5-qt-${FCITX5_QT_VERSION}.tar.gz "https://github.com/fcitx/fcitx5-qt/archive/refs/tags/${FCITX5_QT_VERSION}.tar.gz" && \
77+
tar xf fcitx5-qt-${FCITX5_QT_VERSION}.tar.gz && \
78+
cd fcitx5-qt-${FCITX5_QT_VERSION} && \
79+
cmake . -Bbuild -DCMAKE_MODULE_PATH=/usr/local/lib/cmake -DCMAKE_PREFIX_PATH=/usr/local -DCMAKE_BUILD_TYPE=Release -DENABLE_QT4=Off -DENABLE_QT5=On -DENABLE_QT6=Off -DBUILD_ONLY_PLUGIN=On -DBUILD_STATIC_PLUGIN=On && \
80+
cmake --build build --parallel && \
81+
cmake --install build && \
82+
# cleanup
83+
apt autoremove --purge -y \
84+
cmake extra-cmake-modules && \
85+
rm -rf /var/lib/apt/lists/* && \
86+
cd / && \
87+
rm -r /build/qt5

x86_64/Dockerfile

Lines changed: 100 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,100 @@
1+
# RHEL devtoolset, which provides new version of GCC targetting old libgcc_s and libstdc++, is the key to compatibility.
2+
# EL 7 is modern enough for apps and libs.
3+
FROM docker.io/amd64/centos:7
4+
5+
# System
6+
RUN yum install -y centos-release-scl-rh epel-release && \
7+
yum upgrade -y && \
8+
yum install -y \
9+
# general devtools
10+
devtoolset-7-gcc devtoolset-7-gcc-c++ make \
11+
# squashfs-tools libs
12+
libzstd-devel \
13+
# Qt build tools
14+
file which \
15+
# Qt libs
16+
at-spi2-core-devel dbus-devel fontconfig-devel freetype-devel glib2-devel libXrender-devel libxcb-devel libxkbcommon-devel libxkbcommon-x11-devel mesa-libGL-devel wayland-devel xcb-util-devel && \
17+
yum clean all
18+
19+
ARG DEVTOOLSET_ROOTPATH=/opt/rh/devtoolset-7/root
20+
ENV PATH=${DEVTOOLSET_ROOTPATH}/usr/bin:${PATH}
21+
ENV LD_LIBRARY_PATH=${DEVTOOLSET_ROOTPATH}/usr/lib64
22+
23+
ARG SQUASHFS_TOOLS_VERSION=4.4
24+
ARG QT_MAJOR_MINOR=5.12
25+
ARG QT_PATCH=12
26+
ARG QT_VERSION=${QT_MAJOR_MINOR}.${QT_PATCH}
27+
ARG FCITX5_QT_VERSION=5.0.17
28+
ARG ALACRITTY_VERSION=0.12.2
29+
30+
# AppImage runtime
31+
RUN curl -L -o /opt/appimage-runtime 'https://github.com/AppImage/type2-runtime/releases/download/continuous/runtime-x86_64'
32+
33+
# squashfs-tools
34+
RUN mkdir -p /build/squashfs-tools && \
35+
cd /build/squashfs-tools && \
36+
curl -L -o squashfs-tools-${SQUASHFS_TOOLS_VERSION}.tar.gz "https://github.com/plougher/squashfs-tools/archive/refs/tags/${SQUASHFS_TOOLS_VERSION}.tar.gz" && \
37+
tar xf squashfs-tools-${SQUASHFS_TOOLS_VERSION}.tar.gz && \
38+
cd squashfs-tools-${SQUASHFS_TOOLS_VERSION}/squashfs-tools && \
39+
make ZSTD_SUPPORT=1 -j$(nproc) && \
40+
make install && \
41+
# cleanup
42+
cd / && \
43+
rm -r /build/squashfs-tools
44+
45+
# Qt 5
46+
RUN mkdir -p /build/qt5 && \
47+
cd /build/qt5 && \
48+
curl -O "https://download.qt.io/archive/qt/${QT_MAJOR_MINOR}/${QT_VERSION}/submodules/qt{base,svg,tools,wayland}-everywhere-src-${QT_VERSION}.tar.xz" && \
49+
tar xf qtbase-everywhere-src-${QT_VERSION}.tar.xz && \
50+
cd qtbase-everywhere-src-${QT_VERSION} && \
51+
./configure \
52+
-prefix /usr/local \
53+
-opensource -confirm-license \
54+
-optimize-size -no-shared -static -platform linux-g++ -no-use-gold-linker \
55+
-qt-zlib -qt-doubleconversion -iconv -no-icu -qt-pcre -no-openssl -system-freetype -fontconfig -qt-harfbuzz -qt-libjpeg -qt-libpng -qt-xcb -qt-sqlite \
56+
-nomake examples -nomake tests -nomake tools && \
57+
make -j$(nproc) && \
58+
make install && \
59+
# svg package
60+
cd /build/qt5 && \
61+
tar xf qtsvg-everywhere-src-${QT_VERSION}.tar.xz && \
62+
cd qtsvg-everywhere-src-${QT_VERSION} && \
63+
qmake . && \
64+
make -j$(nproc) && \
65+
make install && \
66+
# tools package
67+
cd /build/qt5 && \
68+
tar xf qttools-everywhere-src-${QT_VERSION}.tar.xz && \
69+
cd qttools-everywhere-src-${QT_VERSION} && \
70+
qmake . && \
71+
make -j$(nproc) && \
72+
make install && \
73+
# wayland package
74+
cd /build/qt5 && \
75+
tar xf qtwayland-everywhere-src-${QT_VERSION}.tar.xz && \
76+
cd qtwayland-everywhere-src-${QT_VERSION} && \
77+
qmake . && \
78+
make -j$(nproc) && \
79+
make install && \
80+
# cleanup
81+
cd / && \
82+
rm -r /build/qt5
83+
84+
# fcitx5-qt
85+
RUN yum install -y \
86+
cmake3 extra-cmake-modules && \
87+
mkdir -p /build/qt5 && \
88+
cd /build/qt5 && \
89+
curl -L -o fcitx5-qt-${FCITX5_QT_VERSION}.tar.gz "https://github.com/fcitx/fcitx5-qt/archive/refs/tags/${FCITX5_QT_VERSION}.tar.gz" && \
90+
tar xf fcitx5-qt-${FCITX5_QT_VERSION}.tar.gz && \
91+
cd fcitx5-qt-${FCITX5_QT_VERSION} && \
92+
cmake3 . -Bbuild -DCMAKE_MODULE_PATH=/usr/local/lib/cmake -DCMAKE_PREFIX_PATH=/usr/local -DCMAKE_BUILD_TYPE=Release -DENABLE_QT4=Off -DENABLE_QT5=On -DENABLE_QT6=Off -DBUILD_ONLY_PLUGIN=On -DBUILD_STATIC_PLUGIN=On && \
93+
cmake3 --build build --parallel && \
94+
cmake3 --install build && \
95+
# cleanup
96+
yum autoremove -y \
97+
cmake3 extra-cmake-modules && \
98+
yum clean all && \
99+
cd / && \
100+
rm -r /build/qt5

0 commit comments

Comments
 (0)