Commit 91976c32 authored by ab0027's avatar ab0027 💬
Browse files

Update

parent 12fb6464
......@@ -9,4 +9,4 @@ It let you quickly create a Maui application and access utilities and widgets sh
# MauiKit sources
[https://invent.kde.org/kde/mauikit]()
\ No newline at end of file
[https://invent.kde.org/maui/mauikit]()
\ No newline at end of file
......@@ -102,7 +102,7 @@ ENV DEB_BUILD_ARCH=amd64 \
ADD arm64-toolchain.cmake /
# Build mauikit
RUN git clone https://invent.kde.org/kde/mauikit.git /tmp/mauikit --depth=1 --branch master
RUN git clone https://invent.kde.org/maui/mauikit.git /tmp/mauikit --depth=1 --branch master
WORKDIR /tmp/mauikit
RUN cmake . -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE='/arm64-toolchain.cmake' ;\
......
FROM ubuntu:focal
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && \
apt-get install curl python3 python3-setuptools python3-pip wget \
patchelf fakeroot gnupg2 libglib2.0-bin file \
desktop-file-utils libgdk-pixbuf2.0-dev zsync -y && \
apt-get autoclean && \
rm -rf /var/lib/apt/
# add foreign architecture for cross-compiling
RUN dpkg --add-architecture arm64
RUN wget https://github.com/AppImage/AppImageKit/releases/download/continuous/appimagetool-x86_64.AppImage -O /tmp/appimagetool && \
chmod +x /tmp/appimagetool && \
/tmp/appimagetool --appimage-extract && \
mv squashfs-root /opt/appimagetool.AppDir && \
ln -s /opt/appimagetool.AppDir/AppRun /usr/bin/appimagetool && \
rm /tmp/appimagetool
RUN pip3 install appimage-builder==0.7.0
# setup kde neon repositories
RUN curl https://origin.archive.neon.kde.org/public.key -sS | apt-key add -
RUN echo "deb [arch=amd64] http://origin.archive.neon.kde.org/user focal main" > /etc/apt/sources.list.d/neon.list && \
echo "deb [arch=amd64] http://archive.ubuntu.com/ubuntu focal main restricted multiverse universe" > /etc/apt/sources.list && \
echo "deb [arch=amd64] http://archive.ubuntu.com/ubuntu focal-updates main restricted multiverse universe" >> /etc/apt/sources.list && \
echo "deb [arch=amd64] http://archive.ubuntu.com/ubuntu focal-security main restricted multiverse universe" >> /etc/apt/sources.list
# install toolchain
RUN apt-get update && \
apt-get dist-upgrade -y && \
apt-get -y -f --no-install-recommends install crossbuild-essential-arm64 cmake git gettext checkinstall \
pkg-config-aarch64-linux-gnu qemu-user-static qt5-qmake qtbase5-dev-tools && \
apt-get autoclean && \
rm -rf /var/lib/apt/
ARG BUILD_ROOT=/tmp/buildroot
WORKDIR $BUILD_ROOT
ADD apt.conf etc/apt/
ADD sources.list etc/apt/
RUN mkdir -p \
etc/apt/trusted.gpg.d etc/apt/trusted.gpg.d \
var/lib/apt/lists/partial var/lib/dpkg \
var/cache/apt/archives/partial var/log/apt; \
\
touch var/lib/dpkg/status etc/apt/trusted.gpg.d/neon.gpg; \
cp -r /etc/apt/trusted.gpg.d etc/apt; \
\
# add kde neon repo key
curl https://origin.archive.neon.kde.org/public.key -sS | apt-key --keyring $BUILD_ROOT/etc/apt/trusted.gpg.d/neon.gpg add -; \
apt-get -c etc/apt/apt.conf update; \
\
# install mauikit dependencies
apt-get -c etc/apt/apt.conf -y --no-install-recommends --allow-remove-essential --download-only install \
libc-dev:arm64 libicu-dev:arm64 \
checkinstall:arm64 cmake:arm64 curl:arm64 devscripts:arm64 equivs:arm64 extra-cmake-modules:arm64 \
gettext:arm64 git:arm64 kirigami2-dev:arm64 libc-dev:arm64 libexiv2-dev:arm64 libfam0:arm64 \
libgdk-pixbuf2.0-dev:arm64 libicu-dev:arm64 libkdecorations2-dev:arm64 libkf5archive-dev:arm64 \
libkf5auth-dev:arm64 libkf5bookmarks-dev:arm64 libkf5codecs-dev:arm64 libkf5completion-dev:arm64 \
libkf5config-dev:arm64 libkf5configwidgets-dev:arm64 libkf5contacts-dev:arm64 libkf5coreaddons-dev:arm64 \
libkf5declarative-dev:arm64 libkf5i18n-dev:arm64 libkf5itemviews-dev:arm64 libkf5kio-dev:arm64 \
libkf5notifications-dev:arm64 libkf5people-dev:arm64 libkf5plasma-dev:arm64 libkf5service-dev:arm64 \
libkf5syntaxhighlighting-dev:arm64 libkf5widgetsaddons-dev:arm64 libqt5multimedia5-plugins:arm64 \
libqt5sql5-sqlite:arm64 libqt5svg5-dev:arm64 libqt5virtualkeyboard5-dev:arm64 libqt5webchannel5-dev:arm64 \
libqt5webkit5-dev:arm64 libqt5websockets5-dev:arm64 libqt5webview5-dev:arm64 libqt5x11extras5-dev:arm64 \
libtag1-dev:arm64 qml-module-qtgraphicaleffects:arm64 qtbase5-dev:arm64 qtdeclarative5-dev:arm64 \
qtmultimedia5-dev:arm64 qtquickcontrols2-5-dev:arm64 qtwebengine5-dev:arm64; \
\
# extract downloaded files
for DEB_FILE in var/cache/apt/archives/*.deb; do \
echo "Extracting: $DEB_FILE"; \
dpkg-deb -x $DEB_FILE $BUILD_ROOT; \
done ;\
\
# Copy libs and headers to the file system root
cp -rn lib/* /lib ;\
cp -rn usr/lib/* /usr/lib ;\
cp -rn usr/include/* /usr/include/ ;\
cp -rn usr/share/ECM /usr/share ;\
cp -rn usr/bin/* /usr/bin ;\
\
# cleanup
rm -rf $BUILD_ROOT
# Generated from `dpkg-architecture -a arm64`
ENV DEB_BUILD_ARCH=amd64 \
DEB_BUILD_ARCH_BITS=64 \
DEB_BUILD_ARCH_CPU=amd64 \
DEB_BUILD_ARCH_ENDIAN=little \
DEB_BUILD_ARCH_OS=linux \
DEB_BUILD_GNU_CPU=x86_64 \
DEB_BUILD_GNU_SYSTEM=linux-gnu \
DEB_BUILD_GNU_TYPE=x86_64-linux-gnu \
DEB_BUILD_MULTIARCH=x86_64-linux-gnu \
DEB_HOST_ARCH=arm64 \
DEB_HOST_ARCH_BITS=64 \
DEB_HOST_ARCH_CPU=arm64 \
DEB_HOST_ARCH_ENDIAN=little \
DEB_HOST_ARCH_OS=linux \
DEB_HOST_GNU_CPU=aarch64 \
DEB_HOST_GNU_SYSTEM=linux-gnu \
DEB_HOST_GNU_TYPE=aarch64-linux-gnu \
DEB_HOST_MULTIARCH=aarch64-linux-gnu \
DEB_TARGET_ARCH=arm64 \
DEB_TARGET_ARCH_BITS=64 \
DEB_TARGET_ARCH_CPU=arm64 \
DEB_TARGET_ARCH_ENDIAN=little \
DEB_TARGET_ARCH_OS=linux \
DEB_TARGET_GNU_CPU=aarch64 \
DEB_TARGET_GNU_SYSTEM=linux-gnu \
DEB_TARGET_GNU_TYPE=aarch64-linux-gnu \
DEB_TARGET_MULTIARCH=aarch64-linux-gnu \
PKG_CONFIG_LIBDIR=$BUILD_ROOT/usr/lib/aarch64-linux-gnu/pkgconfig:/usr/lib/pkgconfig:/usr/share/pkgconfig \
CC=aarch64-linux-gnu-gcc \
CXX=aarch64-linux-gnu-g++
ADD arm64-toolchain.cmake /
\ No newline at end of file
apt::Architecture "arm64";
APT::Get::Host-Architecture "arm64";
Dir "/tmp/buildroot";
apt::Install-Recommends "false";
APT::Default-Release "*";
# this one is important
SET(CMAKE_SYSTEM_NAME Linux)
#this one not so much
SET(CMAKE_SYSTEM_VERSION 1)
# specify the cross compiler
SET(CMAKE_C_COMPILER /usr/bin/aarch64-linux-gnu-gcc)
SET(CMAKE_CXX_COMPILER /usr/bin/aarch64-linux-gnu-g++)
# where is the target environment
SET(CMAKE_FIND_ROOT_PATH /usr/lib/aarch64-linux-gnu /usr/lib/aarch64-linux-gnu/cmake/)
# search for programs in the build host directories
SET(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
# for libraries and headers in the target directories
SET(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
deb [arch=arm64] http://archive.neon.kde.org/dev/unstable focal main
deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal main multiverse universe
deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal-updates main multiverse universe
deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal-security main multiverse universe
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment