feat(userland): ported the CPython 3.12 interpreter#125
Merged
Conversation
…t of upcoming python port)
122a36f to
43ed7eb
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit fb67227. Configure here.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Note
Medium Risk
Touches kernel syscalls, handle flags, VMA stack size, and PTY ioctls alongside a large new cross-build path; regressions could affect all userland static links and TTY/shell apps, not only Python.
Overview
Adds a static CPython 3.12.8 userland app that cross-builds against the musl sysroot, applies Stellux-specific configure/patches, trims the stdlib, and stages
/usr+bin/python3into a per-arch rootfs overlay copied into initrd (withinitrd/usr/gitignored).Build/CI now builds and caches compiler-rt builtins per arch (
make compiler-rt,libclang_rt.builtins-*) so static links (especially Python on aarch64) do not depend on host cross builtins; toolchain-check, help, and userland/mk/toolchain.mk prefer sysroot builtins.Kernel/userland fixes to support Python and richer TTY behavior:
O_CLOEXECon open withfcntlF_GETFD/F_SETFD(CLOEXEC stored in handle flags, masked fromF_GETFL/F_SETFL); user stack grown to 512 KiB; PTY slave Linuxtermios/winsizeioctls (TCGETS/TCSETS,TIOCGWINSZ) plus Stellux raw/cooked ioctl IDs moved to0x7301/0x7302(user apps updated). CI kernel-unit-tests workflow caches/builds compiler-rt like libc++.Reviewed by Cursor Bugbot for commit f6de95b. Bugbot is set up for automated code reviews on this repo. Configure here.