Skip to content

feat(python): drop configure-project-installer, inline autotools build (cluster B 8/8 — sweep complete)#69

Merged
Sunrisepeak merged 1 commit intomainfrom
feat/cluster-b-python-sandbox
May 1, 2026
Merged

feat(python): drop configure-project-installer, inline autotools build (cluster B 8/8 — sweep complete)#69
Sunrisepeak merged 1 commit intomainfrom
feat/cluster-b-python-sandbox

Conversation

@Sunrisepeak
Copy link
Copy Markdown
Member

Summary

  • Switch fromsource:python (cpython) from xim:configure-project-installer shim to its own inline autotools build
  • Apply the cluster-A sandbox-fix template
  • Last cluster B leaf — exercises every other cluster-B fix end-to-end (zlib, openssl, ncurses, readline, libffi, bzip2, xz-utils, util-linux/libuuid all imported)
  • License: humanized → SPDX PSF-2.0
  • Pin upstream urls (already present in lua)

Configure flags

--enable-shared --with-computed-gotos --enable-ipv6
--enable-loadable-sqlite-extensions --with-system-ffi
CPPFLAGS=-I<sysroot>/usr/include
        -I<sysroot>/usr/include/ncurses
        -I<sysroot>/usr/include/openssl
LDFLAGS=-L<sysroot>/lib
        -Wl,-rpath,/home/xlings/.xlings_data/subos/linux/lib
TZDIR=/usr/share/zoneinfo

Verification (local isolated xlings 0.4.9, with cluster B #62..#68 all merged)

  • ✅ clean install (~1m20s end-to-end, deps cached)
  • ✅ produced bin/{python3, pip3, idle3, python3-config} + lib/libpython3.13.so.1.0
  • python3 --versionPython 3.13.1
  • ✅ stdlib import sanity:
    • zlib (1.3.1)
    • ssl (OpenSSL 3.1.5)
    • hashlib (sha256 ok)
    • lzma (via xz-utils)
    • bz2 (via bzip2)
    • uuid (via util-linux libuuid)
    • readline (8.2 patched series)
    • ctypes (via libffi)
  • _sqlite3 intentionally skipped (no fromsource:sqlite3 yet — tracked under existing -- TODO: gdbm, sqlite3, tk/tkinter in deps)

Net effect across cluster B

After this lands, grep -lR configure-project-installer pkgs/ matches zero packages — the sandbox-fix template now covers 100% of fromsource source-builds (cluster A 34 pkgs + cluster B 8 pkgs = 42 + bzip2 baseline).

Test plan

  • Local iso e2e
  • CI (linux-test, static-and-isolation, index-registration)

Switch fromsource:python (cpython) to its own inline autotools build,
applying the cluster-A sandbox-fix template. This is the last cluster B
leaf and exercises every other cluster-B fix end-to-end (zlib, openssl,
ncurses, readline, libffi, bzip2, xz-utils, util-linux/libuuid).

* paths derived from pkginfo.install_file() (path.absolute is nil)
* configure + make + install chained in single sh -c (os.cd doesn't
  propagate to system.exec children)
* fixed -j8
* deps: explicit xim:gcc + xim:make + xim:xpkg-helper (previously
  pulled in transitively via xim:configure-project-installer)
* license: humanized string -> SPDX PSF-2.0
* env exports kept inline in sh -c (TZDIR, CPPFLAGS, LDFLAGS) so they
  reach the configure subprocess; os.setenv at lua scope didn't reach
  configure's grandchildren via xpkg-helper indirection in the legacy
  flow.

CPPFLAGS / LDFLAGS extensions:
  -I<sysroot>/usr/include             core stdlib deps
  -I<sysroot>/usr/include/ncurses     for `<termcap.h>` / `<curses.h>`
                                      flat lookup (ncurses installs
                                      these under the ncurses/ subdir)
  -I<sysroot>/usr/include/openssl     for openssl 3 headers (some are
                                      under the openssl/ subdir)
  -L<sysroot>/lib                     find xvm-shimmed shared libs
  -Wl,-rpath,/home/xlings/.xlings_data/subos/linux/lib
                                      bake canonical xlings runtime
                                      lib path so the produced python
                                      binary loads its dependent
                                      shared libs from a user-machine
                                      install, not the build host

Configure flags:
  --enable-shared                     ship libpython3.13.so for embedders
  --with-computed-gotos               faster main loop dispatch
  --enable-ipv6                       IPv6 sockets
  --enable-loadable-sqlite-extensions ready for future fromsource:sqlite3
  --with-system-ffi                   link against fromsource:libffi

Verified end-to-end in xlings 0.4.9 iso (with cluster B 1..7 all
MERGED upstream as #62..#68):
  ✓ configure -> make -j8 -> make install (~1m20s with deps cached)
  ✓ produced bin/python3, bin/pip3, bin/idle3, bin/python3-config
  ✓ produced lib/libpython3.13.so.1.0
  ✓ python3 --version -> 3.13.1
  ✓ stdlib import sanity:
    - zlib    (zlib 1.3.1)
    - ssl     (OpenSSL 3.1.5 30 Jan 2024)
    - hashlib (sha256 round-trip)
    - lzma    (xz-utils via _lzma)
    - bz2     (bzip2)
    - uuid    (util-linux libuuid)
    - readline (8.2 patched series)
    - ctypes  (libffi)

_sqlite3 is intentionally skipped (no fromsource:sqlite3 yet — tracked
under the existing "TODO: gdbm, sqlite3, tk/tkinter" line in deps).

Cluster B leaf 8/8 — sweep complete. Net effect across cluster B:
`grep -lR configure-project-installer pkgs/` should now match zero.
@Sunrisepeak Sunrisepeak merged commit 5b96d1c into main May 1, 2026
5 checks passed
@Sunrisepeak Sunrisepeak deleted the feat/cluster-b-python-sandbox branch May 1, 2026 18:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant