Skip to content

Commit 0a3a53c

Browse files
committed
Allow --with-build-python for all builds again
1 parent 13e5d43 commit 0a3a53c

File tree

2 files changed

+5
-8
lines changed

2 files changed

+5
-8
lines changed

configure

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1736,7 +1736,7 @@ Optional Packages:
17361736
path to _freeze_module binary for cross compiling
17371737
--with-build-python=python3.11
17381738
path to build python binary for cross compiling
1739-
(default: python3.11)
1739+
(default: _bootstrap_python or python3.11)
17401740
--with-pkg-config=[yes|no|check]
17411741
use pkg-config to detect build options (default is
17421742
check)
@@ -3243,14 +3243,11 @@ if test "${with_build_python+set}" = set; then :
32433243
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-build-python" >&5
32443244
$as_echo_n "checking for --with-build-python... " >&6; }
32453245

3246-
if test "x$cross_compiling" = xno; then :
3247-
as_fn_error $? "--with-build-python only applies to cross compiling" "$LINENO" 5
3248-
fi
32493246
if test "x$with_build_python" = xyes; then :
32503247
with_build_python=python$PACKAGE_VERSION
32513248
fi
32523249
if test "x$with_build_python" = xno; then :
3253-
as_fn_error $? "invalid --with-build-python option: expected path, not \"no\"" "$LINENO" 5
3250+
as_fn_error $? "invalid --with-build-python option: expected path or \"yes\", not \"no\"" "$LINENO" 5
32543251
fi
32553252

32563253
if ! $(command -v "$with_build_python" >/dev/null 2>&1); then

configure.ac

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -125,16 +125,16 @@ AC_ARG_WITH(
125125
)
126126
AC_SUBST([FREEZE_MODULE])
127127

128+
dnl build-python is used for cross compiling and macOS framework builds.
128129
AC_ARG_WITH(
129130
[build-python],
130131
[AS_HELP_STRING([--with-build-python=python]PYTHON_VERSION,
131-
[path to build python binary for cross compiling (default: python]PYTHON_VERSION[)])],
132+
[path to build python binary for cross compiling (default: _bootstrap_python or python]PYTHON_VERSION[)])],
132133
[
133134
AC_MSG_CHECKING([for --with-build-python])
134135
135-
AS_VAR_IF([cross_compiling], [no], AC_MSG_ERROR([--with-build-python only applies to cross compiling]))
136136
AS_VAR_IF([with_build_python], [yes], [with_build_python=python$PACKAGE_VERSION])
137-
AS_VAR_IF([with_build_python], [no], [AC_MSG_ERROR([invalid --with-build-python option: expected path, not "no"])])
137+
AS_VAR_IF([with_build_python], [no], [AC_MSG_ERROR([invalid --with-build-python option: expected path or "yes", not "no"])])
138138
139139
if ! $(command -v "$with_build_python" >/dev/null 2>&1); then
140140
AC_MSG_ERROR([invalid or missing build python binary "$with_build_python"])

0 commit comments

Comments
 (0)