Skip to content
This repository was archived by the owner on Jan 30, 2023. It is now read-only.

Commit 95fe89a

Browse files
author
Matthias Koeppe
committedDec 20, 2022
build/pkgs/tox/spkg-configure.m4: Check for good tox 3, tox 4 versions separately
1 parent 4a27a3d commit 95fe89a

File tree

1 file changed

+16
-5
lines changed

1 file changed

+16
-5
lines changed
 

‎build/pkgs/tox/spkg-configure.m4

+16-5
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,28 @@
11
SAGE_SPKG_CONFIGURE([tox], [
22
dnl Use non-ancient tox with full support for PEP 517.
3-
m4_pushdef([TOX_MIN_VERSION], [3.21.4])
4-
AC_CACHE_CHECK([for tox >= ]TOX_MIN_VERSION, [ac_cv_path_TOX], [
3+
m4_pushdef([TOX3_MIN_VERSION], [3.21.4])
4+
dnl Early 4.0.x versions have bugs regarding complex factor conditions
5+
m4_pushdef([TOX4_MIN_VERSION], [4.0.15])
6+
AC_CACHE_CHECK([for tox 3 >= ]TOX3_MIN_VERSION[ or tox 4 >= ]TOX4_MIN_VERSION, [ac_cv_path_TOX], [
57
AC_PATH_PROGS_FEATURE_CHECK([TOX], [tox], [
68
tox_version=$($ac_path_TOX --version 2> /dev/null | tail -1)
79
AS_IF([test -n "$tox_version"], [
8-
AX_COMPARE_VERSION([$tox_version], [ge], TOX_MIN_VERSION, [
9-
ac_cv_path_TOX="$ac_path_TOX"
10-
ac_path_TOX_found=:
10+
AX_COMPARE_VERSION([$tox_version], [lt], [4], [
11+
AX_COMPARE_VERSION([$tox_version], [ge], TOX3_MIN_VERSION, [
12+
ac_cv_path_TOX="$ac_path_TOX"
13+
ac_path_TOX_found=:
14+
])
15+
], [
16+
AX_COMPARE_VERSION([$tox_version], [ge], TOX4_MIN_VERSION, [
17+
ac_cv_path_TOX="$ac_path_TOX"
18+
ac_path_TOX_found=:
19+
])
1120
])
1221
])
1322
])
1423
])
1524
AS_IF([test -z "$ac_cv_path_TOX"],
1625
[sage_spkg_install_tox=yes])
26+
m4_popdef([TOX4_MIN_VERSION])
27+
m4_popdef([TOX3_MIN_VERSION])
1728
])

0 commit comments

Comments
 (0)
This repository has been archived.