5.3 KiB
5.3 KiB
Architecture
Geminux combines a custom-patched Linux 7.3.5 kernel, pure-Linux MTK flasher, XLibre graphics server, patched suckless X11 stack, and custom C11 applications and daemons, packaged cleanly into signed Alpine APK packages so standard userspace updates continue working indefinitely.
Kernel and MediaTek MT6797X support
- Kernel tree: Vanilla Linux
7.3.5patched via patches/kernel/ (0001-ixoo-gemini-pda-mainline-7.3.5.patch,0002-mt6797-ccci-cldma-and-md1-domain.patch,0003-arm64-dts-mediatek-geminux-gemini-pda.patch). - Graphics & display: MediaTek DRM (
mediatek-drm), Novatek DSI panel (panel-novatek-nt36672e), Mali-T880panfrostGPU driver, andsii902xSlimport/HDMI bridge. - Modem / Telephony: Staged
mt6797-ccci-cldmadriver exposing/dev/ccci_md_ctl,/dev/ccci_fs,/dev/ccci_rpc,/dev/ttyC0..3, andccmni*network interfaces with the 16-bytestruct mt6797_ccci_headerUAPI (mt6797_ccci.h). - Boot & recovery: Packed LK-compatible Android boot images (
images/boot-geminux.img,images/recovery-geminux.img) built withmkbootimg-osm0sis(16 MiBboot slot ceiling,512 KiBDTB ceiling). On first boot, src/initramfs/init checks ext4 viae2fsck -pand grows the root filesystem viaresize2fs.
Graphics, window management, and theming
- XLibre (
25.x): Cross-compiled against pure Alpine Edgeaarch64sysroots with Panfrost Glamor EGL (libglamoregl.so),modesetting_drv.so,fbdev_drv.so, andlibinput_drv.so(scripts/build-xlibre.sh). Zero Wayland compositors (sway,weston,phosh,xwayland, etc.) are installed. - Patched suckless desktop:
stwith HarfBuzz font shaping (hb.c) supporting Fira Code programming ligatures, Nerd Font fallback, andSIGUSR1live.Xresourcesreload.dwmwith Pango/HarfBuzz multi-font bar (drw.c), EWMH/XEmbed system tray, touch-friendly>= 44pxstatus bar,Mod4 = Fn+Alt+ one-shotSuper_Ltap-latch, andSIGUSR1.Xresourcesreload.dmenuwith Pango/HarfBuzz,48pxtouch rows, and mouse/touch click selection.
- Zero-Rust notifications:
dunst v1.12.2compiled withWAYLAND=0 DUNSTIFY=0and custom pure-C PNG (libpng+ Cairo) / JPEG (libjpeg-turbo) icon loader replacinggdk-pixbuf(src/dunst-notify/), paired with a lightweight GDBusnotify-send/dunstify.
Custom UI toolkit and zero-poll C11 daemons
libgemui.so(src/libgemui/): Double-buffered Cairo + Pango/HarfBuzz Xlib toolkit polling X11 events,SIGUSR1self-pipe for instant.Xresourcesreloads, dynamic timers, and non-blocking extra FDs (such as V4L2 orinotify).- Zero-poll C11 daemons (src/geminux-daemons/):
geminux-powerd—epollover/dev/input/event*(SW_LID,KEY_POWER),KOBJECT_UEVENT,/run/geminux/powerd.sock, and on-demandtimerfd.geminux-statusd—epolloversignalfd(SIGUSR1),RTMGRP_LINK/RTMGRP_IPV4_IFADDR,KOBJECT_UEVENT,inotify, and minute-alignedtimerfd; updates rootWM_NAMEwith zero child shell forks.geminux-ccci-daemon—epollover/dev/ccci_*, uevents, and/run/geminux/ccci.sock; idles cleanly if MD firmware is absent.geminux-modem-ctl,geminux-bt-obex(GLibGMainLoop/GDBus),geminux-leds,geminux-power-audit, andgeminux-checkpw.
APK package pinning and zero-Rust enforcement
To keep Alpine Edge aarch64 userspace freely updatable while locking all hardware-tuned components:
- Build-time host Docker containers use
postmarketos/v26.06solely forgcc-aarch64,binutils-aarch64, andmkbootimg-osm0sis. All$SYSROOTtrees and the target$ROOTFSuse only pure Alpine Edge (main,community,testing) plus the RSA-4096 signed local@geminuxrepository (/var/lib/geminux/apk-repo). - scripts/package-local-apks.sh builds six
.apkpackages viaapk mkpkgand indexes them intoAPKINDEX.tar.gzviaapk mkndx:geminux-kernel-modulesgeminux-xlibregeminux-sucklessgeminux-dunstgeminux-uigeminux-config
/etc/apk/worldpins all six withname@geminux=versionand locks out Rust/Wayland/upstream overrides via!constraints from scripts/rootfs-prune-packages.txt./etc/apk/protected_paths.d/geminux.listshields Geminux configuration directories across upgrades.
Pure-Linux flasher and eMMC layout
flash-mtk.py uses vendored GPLv3 mtkclient + single-chip MTK_DA_V5_MT6797.bin to communicate directly over USB BROM/DA without MediaTek's proprietary GUI. Protected partitions in LBA 0..0x6FFFF (preloader, nvram, proinfo, lk, tee1, md1img, etc.) are backed up and write-blocked by default (0x0E000000 protected boundary verified in scripts/test-flash-mtk-gpt.py).