Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 11 additions & 7 deletions dev/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,18 @@ FROM ubuntu:${OS_CODENAME}
# Redeclare ARGs after FROM
ARG OS_CODENAME
ARG DEBIAN_FRONTEND=noninteractive
ARG QT_VERSION=5.15.2
ARG QT_MODULES=
ARG QT_VERSION=6.9.0
ARG QT_MODULES="-m qtmultimedia qtserialport"
ARG QT_HOST=linux
ARG QT_TARGET=desktop
ARG QT_ARCH=linux_gcc_64
ARG QT_INSTALL_DIR=/opt/qt
ARG GCC_ARM_VERSION=14.2.rel1
ARG NODE_VERSION=20.x

ENV LANG=C.UTF-8
ENV LC_ALL=C.UTF-8

# Setup package repositories and install all dependencies in a single layer
RUN apt-get update && \
apt-get install --yes --no-install-recommends software-properties-common gpg gpg-agent wget ca-certificates && \
Expand Down Expand Up @@ -49,8 +53,8 @@ RUN apt-get update && \
nodejs \
locales \
# Install dependencies required by Qt libs
libcups2 \
libssl-dev \
gstreamer1.0-plugins-base \
# linuxdeploy-plugin-qt requires libxcb1 and supporting libs
awesome && \
# Generate all required locales
Expand Down Expand Up @@ -91,18 +95,18 @@ ENV PATH=${QT_BASE_DIR}/bin:$PATH
ENV QT_PLUGIN_PATH=${QT_BASE_DIR}/plugins/
ENV QML_IMPORT_PATH=${QT_BASE_DIR}/qml/
ENV QML2_IMPORT_PATH=${QT_BASE_DIR}/qml/
ENV LD_LIBRARY_PATH=${QT_BASE_DIR}/lib:$LD_LIBRARY_PATH
ENV PKG_CONFIG_PATH=${QT_BASE_DIR}/lib/pkgconfig:$PKG_CONFIG_PATH
ENV LD_LIBRARY_PATH=${QT_BASE_DIR}/lib
ENV PKG_CONFIG_PATH=${QT_BASE_DIR}/lib/pkgconfig

RUN uvx --no-cache --from aqtinstall aqt install-qt --outputdir ${QT_INSTALL_DIR} ${QT_HOST} ${QT_TARGET} ${QT_VERSION} ${QT_ARCH} ${QT_MODULES} && \
strip --remove-section=.note.ABI-tag ${QT_BASE_DIR}/lib/libQt5Core.so.${QT_VERSION}
RUN uvx --no-cache --from aqtinstall aqt install-qt --outputdir ${QT_INSTALL_DIR} ${QT_HOST} ${QT_TARGET} ${QT_VERSION} ${QT_ARCH} ${QT_MODULES}

# Install ARM toolchain
RUN wget --quiet https://developer.arm.com/-/media/Files/downloads/gnu/${GCC_ARM_VERSION}/binrel/arm-gnu-toolchain-${GCC_ARM_VERSION}-x86_64-arm-none-eabi.tar.xz -O - \
| tar -xJ -C /opt

ENV PATH=/opt/arm-gnu-toolchain-${GCC_ARM_VERSION}-x86_64-arm-none-eabi/bin/:${PATH}
ENV ASAN_OPTIONS="detect_leaks=0"

# HINTS for cmake find_package
ENV LIBUSB1_ROOT_DIR=/usr/lib/x86_64-linux-gnu
ENV LIBSSL1_ROOT_DIR=/usr/lib/x86_64-linux-gnu
Expand Down