No description
CHOST was the Debian-style triplet. gcc -dumpmachine reports s390x-linux-gnu on this host, but config.sub canonicalises that to s390x-ibm-linux-gnu and GCC builds its tree under the canonical name. Arch PKGBUILDs assume the canonical form -- theirs is x86_64-pc-linux-gnu, vendor field present -- so gcc's own PKGBUILD looked for $CHOST/libstdc++-v3/doc and found nothing: make: *** s390x-linux-gnu/libstdc++-v3/doc: No such file or directory while the build had created s390x-ibm-linux-gnu/libstdc++-v3/doc. This is a port-wide setting, not a gcc quirk: every PKGBUILD that derives a path from CHOST was pointing one directory sideways. libassuan fetches from dev.gnupg.org, which is unreachable from this build host -- measured HTTP 000, while github.com/gpg/libassuan.git and gnupg.org/ftp both answer. That is a network fact, not a port problem, so only the transport changes: the pinned tag is untouched and what gets built is what Arch specifies. Host dependencies again: doxygen for xz, libunistring for libpsl, systemd-dev for util-linux. Every one of them was invisible until a build stopped on it, because --nodeps means pacman never checks makedepends. --- FR --- CHOST portait le triplet de style Debian. Sur cet hote, gcc -dumpmachine rend s390x-linux-gnu, mais config.sub le canonise en s390x-ibm-linux-gnu, et GCC batit son arbre sous le nom canonique. Les PKGBUILD d Arch supposent la forme canonique -- la leur est x86_64-pc-linux-gnu, champ constructeur present -- si bien que le PKGBUILD de gcc cherchait $CHOST/libstdc++-v3/doc sans rien trouver : make: *** s390x-linux-gnu/libstdc++-v3/doc: No such file or directory alors que la compilation avait cree s390x-ibm-linux-gnu/libstdc++-v3/doc. C est un reglage de portage, pas une bizarrerie de gcc : tout PKGBUILD derivant un chemin de CHOST visait un repertoire a cote. libassuan se telecharge depuis dev.gnupg.org, injoignable depuis cet hote -- mesure : HTTP 000, quand github.com/gpg/libassuan.git et gnupg.org/ftp repondent tous deux. C est un fait de reseau, pas un probleme de portage : seul le transport change, l etiquette epinglee reste intacte et ce qui se batit est ce qu Arch specifie. Dependances d hote, encore : doxygen pour xz, libunistring pour libpsl, systemd-dev pour util-linux. Chacune est restee invisible jusqu a ce qu une compilation s y arrete, parce que --nodeps interdit a pacman de verifier les makedepends. Assisted-by: Claude Opus 5 |
||
|---|---|---|
| .github/workflows | ||
| arch-kernel | ||
| boot | ||
| patches | ||
| scripts | ||
| .env.example | ||
| .gitignore | ||
| CODEOWNERS | ||
| Containerfile | ||
| LICENSE | ||
| Makefile | ||
| README.md | ||
Arch Linux s390x
A port of Arch Linux to IBM s390x mainframe architecture with systemd support.
Boots a full Arch Linux system on IBM mainframes (or QEMU s390x emulation) using a hybrid build: cross-compilation for the kernel, native s390x compilation on z/VM for userspace.
Quick Start
make container # build dev container (first time)
cp .env.example .env # configure z/VM access
make all # build kernel + initramfs + systemd
make test-systemd # boot it
What Works
- Arch Linux kernel 6.18.6-arch1 with Arch patches, cross-compiled
- Initramfs via modified mkinitcpio
- Static busybox built natively on z/VM, 2.3MB
- Root filesystem with ext4, switch_root to real rootfs
- Systemd as PID 1
Pacman, bash, and GNU coreutils are not yet ported.
Build System
The build uses two tiers:
Cross-compilation (x86_64 host): Kernel is built in a Fedora 43 container with s390x-linux-gnu-gcc. Initramfs is generated with a patched mkinitcpio that handles cross-architecture binary injection.
Native compilation (s390x z/VM): Busybox and systemd must be built on real s390x hardware. The z/VM system runs RHEL 9.6 with GCC 11.5.0. Scripts handle SSH deployment and retrieval automatically via .env configuration.