packaging: the aarch64 flatpak

crafter-build cross-compiles the executable for aarch64, which on an
x86_64 machine needs no emulation, and flatpak's build commands assemble
the flatpak; there is no flatpak-builder manifest.

make-flatpak-sysroot.sh makes the sysroot: the aarch64 Freedesktop Sdk
26.08 with LLVM's libc++ of the release crafter-build carries (23.1.2,
the tarball and hash of Crafter.Build's manifest), built for aarch64.
build-flatpak.sh builds the executable against it for generic armv8-a
and assembles it on the Platform 26.08 with that libc++, libc++abi and
LLVM's libunwind in /app/lib: the Platform has no libc++, and its
libunwind is libunwind 8. It fails when the executable or a bundled
library needs a library neither the Platform nor /app/lib has, and when
one of them links libunwind 8, which libc++'s -lunwind found first until
the sysroot dropped its link name. The executable it packages is the
build it just ran: the output directory's name ends in a hash of the
configuration, so an older variant (another sysroot, --debug, --local)
left in bin/ is removed first. make-flatpak-sysroot.sh tries each
download five times, 30 s apart: Flathub's CDN answers 502 now and then.
The sandbox gets Wayland, the GPU, net.catcrafts.IMS1 on the system bus
and org.freedesktop.Notifications on the session bus. The metainfo's
content rating declares the app's chat (OARS social-chat intense:
uncontrolled texting between users), as the baseline Chatty's does, for
the software centres and parental controls that read it, and recommends
a display of 360 logical pixels or more — the phone screen the window is
drawn for; a recommendation, not a requirement. The metainfo's one
release is 0.0.0, and the app's version, 0.1.0 in the skeleton, is set
to it: the version's comment in Model.cppm says a release moves the two
together. AGENTS.md's SPDX rule says what the metainfo carries instead
of the two SPDX lines: AppStream's single CC0-1.0 line.

The flatpak carries the licences of what it ships under
/app/share/licenses/net.catcrafts.ImsdMessages: the app's and the font's,
those of the Crafter libraries it links statically and of the code they
bring along (packaging/licenses/, with a NOTICE naming what each text
covers), and LLVM's for its runtime libraries, which
make-flatpak-sysroot.sh keeps beside libc++.
This commit is contained in:
Jorijn van der Graaf 2026-10-21 23:59:17 +02:00
commit 411ed55660
Signed by: jorijnvdgraaf
GPG key ID: 2937E59CDCC1BCFB
11 changed files with 955 additions and 6 deletions

View file

@ -0,0 +1,32 @@
SPDX-License-Identifier: MIT
Copyright © 2013 Red Hat, Inc.
Copyright © 2013 David Herrmann <dh.herrmann@gmail.com>
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to
deal in the Software without restriction, including without limitation the
rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
sell copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice (including the next
paragraph) shall be included in all copies or substantial portions of the
Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
IN THE SOFTWARE.
The following license is from a Linux kernel header file and there is no GPL
code this package links to.
Copyright (c) 1999-2002 Vojtech Pavlik
This program is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License version 2 as published by
the Free Software Foundation.