Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,10 @@ per-version sum is the trust anchor the runtime factory verifies against.
build/copy plan uses — an `_msys` patch never smokes linux-gnu).
- `tools/lint <version>` — fetch + verify + extract + tree sanity
(`configure`, `Makefile.pre.in`, `Modules/getpath.py` — the file the
relocatability contract rests on), plus `git apply --check` of every
patch the version's line manifest selects.
relocatability contract rests on), plus applying every patch the
version's line manifest selects, in manifest order, on a pristine tree
(the series is cumulative — a patch's context may assume its
predecessors).
- `tools/monitor --detect | --onboard <version>` — the release monitor.
`Tfs::PythonReleases` parses the official python.org FTP index
(exact `X.Y.Z` directories only — pre-release suffixes and the two-part
Expand Down Expand Up @@ -139,8 +141,8 @@ All matrices and every version/sha flow from versions.yml through the
tools — the workflows carry no version literals.

- `lint.yml` (push to main + PRs) — validates manifests, then one leg per
version running `tools/lint` (tarball + tree sanity + every selected
patch `git apply --check`), plus the **compile-smoke legs**
version running `tools/lint` (tarball + tree sanity + the selected
patch series applied in manifest order), plus the **compile-smoke legs**
(`tools/versions --smoke` → `_compile-smoke.yml`, one leg per
patch-carrying scenario on its native runner — the PR-time oracle for
the windows-msys port, since a local macOS/Linux host cannot run the
Expand Down
27 changes: 27 additions & 0 deletions patches/3.14/bootstrap_python_link_flags_msys.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# bootstrap_python_link_flags_msys.patch
#
# Target: Makefile.pre.in (windows-msys scenario)
# Source: MSYS2 MINGW-packages mingw-w64-python 0056
# "build: Add extra flags for _bootstrap_python" (ported
# verbatim)
#
# Wall item (anticipated link wall, same leg class as run 34725669811):
# Programs/_bootstrap_python.c defines wmain (not main) under MS_WINDOWS,
# and mingw's CRT startup only calls wmain when linked -municode —
# otherwise the _bootstrap_python link (which runs during every make: it
# freezes the stdlib modules) dies on the missing entry point. -mwindows
# rides along from the proven patch (GUI subsystem: no console window for
# the build-time tool).
diff --git a/Makefile.pre.in b/Makefile.pre.in
index a4c738b..f1b346d 100644
--- a/Makefile.pre.in
+++ b/Makefile.pre.in
@@ -1681,7 +1681,7 @@ BOOTSTRAP_HEADERS = \
Programs/_bootstrap_python.o: Programs/_bootstrap_python.c $(BOOTSTRAP_HEADERS) $(PYTHON_HEADERS)

_bootstrap_python: $(LIBRARY_OBJS_OMIT_FROZEN) Programs/_bootstrap_python.o Modules/getpath.o Modules/Setup.local
- $(LINKCC) $(PY_LDFLAGS_NOLTO) -o $@ $(LIBRARY_OBJS_OMIT_FROZEN) \
+ $(LINKCC) $(PY_LDFLAGS_NOLTO) -o $@ -municode -mwindows $(LIBRARY_OBJS_OMIT_FROZEN) \
Programs/_bootstrap_python.o Modules/getpath.o $(LIBS) $(MODLIBS) $(SYSLIBS)
# Dummy pybuilddir.txt is needed for _bootstrap_python to be runnable
@echo "none" > ./pybuilddir.txt
54 changes: 28 additions & 26 deletions patches/3.14/configure_c_locale_coercion_msys.patch
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,10 @@
# Source: MSYS2 MINGW-packages mingw-w64-python 0052
# "configure: Default to --without-c-locale-coercion on Windows"
# (configure.ac hunks ported verbatim; the generated-configure
# hunks are the hand-synced equivalents — this factory ships a
# configure-ready tarball, no autoreconf downstream)
# hunks are REGENERATED with the upstream-pinned autoconf 2.72 —
# byte-identical regen against the pristine 3.14.7 configure
# proven, so no hand-sync drift is possible; this factory ships
# a configure-ready tarball, no autoreconf downstream)
#
# Wall item (tebako-runtime-python PR #2, round 5): pylifecycle.c:258's
# setenv is the first hard stop. --with-c-locale-coercion defaults to yes
Expand All @@ -18,32 +20,11 @@
# compiles out. An explicit --with-c-locale-coercion still forces it on
# (named opt-in, not a silent removal).

diff --git a/configure.ac b/configure.ac
index 967d34d..76a7fbb 100644
--- a/configure.ac
+++ b/configure.ac
@@ -5140,11 +5140,14 @@ AC_MSG_RESULT([$with_pymalloc])
AC_MSG_CHECKING([for --with-c-locale-coercion])
AC_ARG_WITH(
[c-locale-coercion],
- [AS_HELP_STRING([--with-c-locale-coercion], [enable C locale coercion to a UTF-8 based locale (default is yes)])])
+ [AS_HELP_STRING([--with-c-locale-coercion], [enable C locale coercion to a UTF-8 based locale (default is yes on Unix, no on Windows)])])

if test -z "$with_c_locale_coercion"
then
- with_c_locale_coercion="yes"
+ case $host in
+ *-*-mingw*) with_c_locale_coercion="no";;
+ *) with_c_locale_coercion="yes";;
+ esac
fi
if test "$with_c_locale_coercion" != "no"
then
diff --git a/configure b/configure
index 2cb22a7..9f5920b 100755
index 730c719..26e35e9 100755
--- a/configure
+++ b/configure
@@ -1927,7 +1927,7 @@ Optional Packages:
@@ -1934,7 +1934,7 @@ Optional Packages:
--with-pymalloc enable specialized mallocs (default is yes)
--with-c-locale-coercion
enable C locale coercion to a UTF-8 based locale
Expand All @@ -52,7 +33,28 @@ index 2cb22a7..9f5920b 100755
--with-valgrind enable Valgrind support (default is no)
--with-dtrace enable DTrace support (default is no)
--with-libm=STRING override libm math library to STRING (default is
@@ -19096,7 +19096,10 @@ fi
@@ -19527,7 +19527,10 @@ fi

if test -z "$with_c_locale_coercion"
then
- with_c_locale_coercion="yes"
+ case $host in
+ *-*-mingw*) with_c_locale_coercion="no";;
+ *) with_c_locale_coercion="yes";;
+ esac
fi
if test "$with_c_locale_coercion" != "no"
then
diff --git a/configure.ac b/configure.ac
index e1ae5b8..dd093fa 100644
--- a/configure.ac
+++ b/configure.ac
@@ -5258,11 +5258,14 @@ AC_MSG_RESULT([$with_pymalloc])
AC_MSG_CHECKING([for --with-c-locale-coercion])
AC_ARG_WITH(
[c-locale-coercion],
- [AS_HELP_STRING([--with-c-locale-coercion], [enable C locale coercion to a UTF-8 based locale (default is yes)])])
+ [AS_HELP_STRING([--with-c-locale-coercion], [enable C locale coercion to a UTF-8 based locale (default is yes on Unix, no on Windows)])])

if test -z "$with_c_locale_coercion"
then
Expand Down
69 changes: 69 additions & 0 deletions patches/3.14/configure_disable_posix_modules_msys.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
# configure_disable_posix_modules_msys.patch
#
# Target: configure.ac + the generated configure (windows-msys scenario)
# Source: MSYS2 MINGW-packages mingw-w64-python 0075
# "configure: disable various modules on MINGW" (ported
# verbatim; configure regenerated with the pinned autoconf 2.72)
#
# Wall class killer: readline/_posixshmem/_posixsubprocess/fcntl/grp/pwd/
# resource/syslog/termios/_scproxy are POSIX-only modules whose upstream
# gates key on headers/functions that mingw-w64 partially stubs (pwd.h
# and grp.h exist but lack the fields the modules need) — each is a
# latent compile wall the CI would otherwise meet one at a time. The NA
# set subsumes MSYS2 0058's _posixsubprocess gate (not ported separately:
# the NA arm already removes it on win32). The factory's own
# Setup.local *disabled* list overlaps deliberately (readline &co.);
# this patch covers the ones it does not name.
diff --git a/configure b/configure
index efadbf5..6dac703 100755
--- a/configure
+++ b/configure
@@ -32340,6 +32340,23 @@ case $ac_sys_system in #(

py_cv_module__scproxy=n/a
;; #(
+ MINGW*) :
+
+
+
+ py_cv_module_readline=n/a
+ py_cv_module__posixshmem=n/a
+ py_cv_module__posixsubprocess=n/a
+ py_cv_module_fcntl=n/a
+ py_cv_module_grp=n/a
+ py_cv_module_pwd=n/a
+ py_cv_module_resource=n/a
+ py_cv_module_syslog=n/a
+ py_cv_module_termios=n/a
+ py_cv_module__scproxy=n/a
+ py_cv_module_=n/a
+
+ ;; #(
QNX*) :


diff --git a/configure.ac b/configure.ac
index 43c1417..d47bcda 100644
--- a/configure.ac
+++ b/configure.ac
@@ -8112,6 +8112,20 @@ AS_CASE([$ac_sys_system],
)
],
[CYGWIN*], [PY_STDLIB_MOD_SET_NA([_scproxy])],
+ [MINGW*], [
+ PY_STDLIB_MOD_SET_NA(
+ [readline],
+ [_posixshmem],
+ [_posixsubprocess],
+ [fcntl],
+ [grp],
+ [pwd],
+ [resource],
+ [syslog],
+ [termios],
+ [_scproxy],
+ )
+ ],
[QNX*], [PY_STDLIB_MOD_SET_NA([_scproxy])],
[FreeBSD*], [PY_STDLIB_MOD_SET_NA([_scproxy])],
[Emscripten], [
65 changes: 65 additions & 0 deletions patches/3.14/configure_exeext_msys.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
# configure_exeext_msys.patch
#
# Target: configure.ac + the generated configure (windows-msys scenario)
# Source: MSYS2 MINGW-packages mingw-w64-python 0063
# "configure: set BUILDEXEEXT and EXEEXT" (ported verbatim;
# configure regenerated with the pinned autoconf 2.72)
#
# Determinism, not a compile wall: upstream leaves EXEEXT empty for
# non-wasm autotools hosts and derives BUILDEXEEXT from a
# case-insensitive-build-directory PROBE — the exe spelling then depends
# on the runner filesystem's case sensitivity (a case-sensitive windows
# mount flips it). The runtime factory reads BUILDEXE off the generated
# Makefile (PythonBuild#exe_path); the patch pins EXEEXT=.exe and
# BUILDEXEEXT=.exe for MINGW so the artifact name is probe-independent.
diff --git a/configure b/configure
index a621d6a..efadbf5 100755
--- a/configure
+++ b/configure
@@ -7510,6 +7510,8 @@ else case e in #(
EXEEXT=.mjs ;; #(
WASI) :
EXEEXT=.wasm ;; #(
+ MINGW*) :
+ EXEEXT=.exe ;; #(
*) :
EXEEXT=
;;
@@ -7545,6 +7547,14 @@ printf "%s\n" "no" >&6; }
fi
rmdir CaseSensitiveTestDir

+case $ac_sys_system in #(
+ MINGW) :
+ BUILDEXEEXT=".exe"
+ ;; #(
+ *) :
+ ;;
+esac
+
case $ac_sys_system in
hp*|HP*)
case $ac_cv_cc_name in
diff --git a/configure.ac b/configure.ac
index 19907c4..43c1417 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1391,6 +1391,7 @@ AC_ARG_WITH([suffix],
AS_CASE([$ac_sys_system],
[Emscripten], [EXEEXT=.mjs],
[WASI], [EXEEXT=.wasm],
+ [MINGW*], [EXEEXT=.exe],
[EXEEXT=]
)
])
@@ -1417,6 +1418,10 @@ else
fi
rmdir CaseSensitiveTestDir

+AS_CASE([$ac_sys_system],
+ [MINGW], [BUILDEXEEXT=".exe"]
+)
+
case $ac_sys_system in
hp*|HP*)
case $ac_cv_cc_name in
Loading