diff options
author | Scott Talbert <swt@techie.net> | 2022-09-13 16:02:43 -0400 |
---|---|---|
committer | Scott Talbert <swt@techie.net> | 2022-09-13 16:02:43 -0400 |
commit | 78a01acebb81b83013fb0efe80906500a6e25136 (patch) | |
tree | 86c93600a48ca0ce8a1d2120908c7f2019945661 /tests/run.sh | |
parent | 39f4ceb33e292f2a2d9e3d76a6612a7f9fdb2855 (diff) | |
download | pycurl-78a01acebb81b83013fb0efe80906500a6e25136.tar.gz |
Fix tests/building docs with newer setuptools
In newer setuptools/distutils, the build directory has been changed from
using the Python version (e.g., 3.10) to using the cache tag (e.g.,
cpython-38). So, support both variants by making the dot optional.
Diffstat (limited to 'tests/run.sh')
-rwxr-xr-x | tests/run.sh | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/run.sh b/tests/run.sh index 36a6fb1..52b5227 100755 --- a/tests/run.sh +++ b/tests/run.sh @@ -7,8 +7,9 @@ test -n "$PYTHON" || PYTHON=python test -n "$PYTEST" || PYTEST=pytest mkdir -p tests/tmp -export PYTHONSUFFIX=$($PYTHON -V 2>&1 |awk '{print $2}' |awk -F. '{print $1 "." $2}') -export PYTHONPATH=$(ls -d build/lib.*$PYTHONSUFFIX):$PYTHONPATH +export PYTHONMAJOR=$($PYTHON -V 2>&1 |awk '{print $2}' |awk -F. '{print $1}') +export PYTHONMINOR=$($PYTHON -V 2>&1 |awk '{print $2}' |awk -F. '{print $2}') +export PYTHONPATH=$(ls -d build/lib.*$PYTHONMAJOR*$PYTHONMINOR):$PYTHONPATH extra_attrs= if test "$CI" = true; then |