python3-tomli-w: updated to use python3-installer, if python3-flit-core is installed

This commit is contained in:
Tim Biermann 2023-03-31 16:08:11 +02:00
parent 6d9623fe14
commit 9d968fd90a
3 changed files with 13 additions and 11 deletions

View File

@ -3,11 +3,9 @@ drwxr-xr-x root/root usr/lib/
drwxr-xr-x root/root usr/lib/python3.10/
drwxr-xr-x root/root usr/lib/python3.10/site-packages/
drwxr-xr-x root/root usr/lib/python3.10/site-packages/tomli_w-1.0.0.dist-info/
-rw-r--r-- root/root usr/lib/python3.10/site-packages/tomli_w-1.0.0.dist-info/INSTALLER
-rw-r--r-- root/root usr/lib/python3.10/site-packages/tomli_w-1.0.0.dist-info/LICENSE
-rw-r--r-- root/root usr/lib/python3.10/site-packages/tomli_w-1.0.0.dist-info/METADATA
-rw-r--r-- root/root usr/lib/python3.10/site-packages/tomli_w-1.0.0.dist-info/RECORD
-rw-r--r-- root/root usr/lib/python3.10/site-packages/tomli_w-1.0.0.dist-info/REQUESTED (EMPTY)
-rw-r--r-- root/root usr/lib/python3.10/site-packages/tomli_w-1.0.0.dist-info/WHEEL
drwxr-xr-x root/root usr/lib/python3.10/site-packages/tomli_w/
-rw-r--r-- root/root usr/lib/python3.10/site-packages/tomli_w/__init__.py

View File

@ -1,5 +1,5 @@
untrusted comment: verify with /etc/ports/contrib.pub
RWSagIOpLGJF31pr9P2vUfpAi5vnqVMnO7MLptDrQuoorLEbSvZUncaYd3MZmILOcXrNYPbLg+Vj7eZZnYEJ8T35IM+knr6Fkgo=
SHA256 (Pkgfile) = 775aa9ca64c8ab80ae7e2127409dafc2c596e5c9e14922e58516cb65a672db11
SHA256 (.footprint) = 9d1c2a87b88869a80d03a19f181d2684038715650401835fcbb5953338352d30
RWSagIOpLGJF37Ie+YJ42TYo7qrUAtN0ukPZcCob6G11gJsRVosE7AAGm5DyAek4VwH/6nWkuhuRqWlugrcNsz2iL0/z/o2wlQU=
SHA256 (Pkgfile) = 0fd2d02fb5494920bba127bbdc4ed342b5365b90ffcf0766f3e7058a84c40f86
SHA256 (.footprint) = 524928af00519d48dadf7ac30d8373402942ef70da396d0dfa3593cac570ce3b
SHA256 (tomli-w-1.0.0.tar.gz) = 4fe1fb4696899c01356ef4e028c975103abf62e5fa9472f31f1714100f1b065d

View File

@ -1,8 +1,8 @@
# Description: A lil' TOML writer
# URL: https://github.com/hukkin/tomli-w
# Maintainer: Tim Biermann, tbier at posteo dot de
# Depends on: python3-pip python3-poetry
# Optional: python3-flit
# Depends on: python3-poetry
# Optional: python3-flit-core
name=python3-tomli-w
version=1.0.0
@ -12,10 +12,14 @@ source=(https://github.com/hukkin/tomli-w/archive/$version/tomli-w-$version.tar.
build() {
cd tomli-w-$version
if prt-get isinst python3-flit; then
/usr/bin/python3 -m flit build --format wheel
/usr/bin/pip3 install --isolate --root=$PKG --ignore-installed --no-deps dist/*.whl
_pyver=$(/usr/bin/python3 -c 'import sys; print("%s.%s" % sys.version_info[:2])')
if prt-get isinst python3-flit-core; then
/usr/bin/python3 -m build --wheel --skip-dependency-check --no-isolation
/usr/bin/python3 -m installer --compile-bytecode 0 --destdir=$PKG dist/*.whl
else
/usr/bin/pip3 install --isolate --root=$PKG --ignore-installed --no-deps tomli-w
/usr/bin/pip3 install --isolate --root=$PKG --ignore-installed --compile --no-deps tomli-w==$version
fi
rm -rf $PKG/usr/lib/python$_pyver/site-packages/tomli_w-$version.dist-info/{INSTALLER,REQUESTED}
}