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,47 @@
stb_truetype.h v1.26, Sean Barrett (lib/stb_truetype.h of Crafter.Graphics):
------------------------------------------------------------------------------
This software is available under 2 licenses -- choose whichever you prefer.
------------------------------------------------------------------------------
ALTERNATIVE A - MIT License
Copyright (c) 2017 Sean Barrett
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 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.
------------------------------------------------------------------------------
ALTERNATIVE B - Public Domain (www.unlicense.org)
This is free and unencumbered software released into the public domain.
Anyone is free to copy, modify, publish, use, compile, sell, or distribute this
software, either in source code form or as a compiled binary, for any purpose,
commercial or non-commercial, and by any means.
In jurisdictions that recognize copyright laws, the author or authors of this
software dedicate any and all copyright interest in the software to the public
domain. We make this dedication for the benefit of the public at large and to
the detriment of our heirs and successors. We intend this dedication to be an
overt act of relinquishment in perpetuity of all present and future rights to
this software under copyright law.
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 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.
------------------------------------------------------------------------------
stb_image_write.h v1.02, Sean Barrett (lib/stb_image_write.h of Crafter.Graphics):
This software is dual-licensed to the public domain and under the following
license: you are granted a perpetual, irrevocable license to copy, modify,
publish, and distribute this file as you see fit.