|
|
@ -1,6 +1,6 @@ |
|
|
|
#!/bin/bash |
|
|
|
# Build script for Slackware |
|
|
|
# Copyright (C) 2018,2019 Damien Goutte-Gattat |
|
|
|
# Copyright (C) 2018,2019,2020 Damien Goutte-Gattat |
|
|
|
# |
|
|
|
# Redistribution and use of this script, with or without modifications, |
|
|
|
# is permitted provided that the following conditions are met: |
|
|
@ -25,14 +25,12 @@ |
|
|
|
# Latest acme sourcecode is available at: |
|
|
|
# <https://github.com/certbot/certbot>. |
|
|
|
# |
|
|
|
# Depends: l/josepy, l/python-requests-toolbelt, l/python-mock, l/pyrfc3339 |
|
|
|
# Depends: l/pytz |
|
|
|
# Depends: l/josepy, l/python-requests-toolbelt, l/pyrfc3339, l/pytz |
|
|
|
|
|
|
|
# Source package infos |
|
|
|
NAMESRC=${NAMESRC:-acme} |
|
|
|
VERSION=${VERSION:-0.40.1} |
|
|
|
VERSION=${VERSION:-1.5.0} |
|
|
|
ARCHIVE=${ARCHIVE:-$NAMESRC-$VERSION.tar.gz} |
|
|
|
WGET=${WGET:-https://files.pythonhosted.org/packages/ec/64/e1e609c6041a3d934a8878f3061b2c97cb9dbab681c043e6e7d90410928a/$ARCHIVE} |
|
|
|
|
|
|
|
# Build infos |
|
|
|
NAMEPKG=${NAMEPKG:-python-acme} |
|
|
@ -61,8 +59,7 @@ fi |
|
|
|
|
|
|
|
# Get and verify the source archive |
|
|
|
if [ ! -r $ARCHIVE ]; then |
|
|
|
wget -c -O $ARCHIVE.part "$WGET" |
|
|
|
mv $ARCHIVE.part $ARCHIVE |
|
|
|
pip3 download --no-binary :all: --no-deps $NAMESRC==$VERSION |
|
|
|
fi |
|
|
|
sha256sum -c $ARCHIVE.sha256 |
|
|
|
NAME=$(tar ft $ARCHIVE | head -n 1 | cut -d / -f 1) |
|
|
@ -72,8 +69,6 @@ cd $TMP |
|
|
|
echo "Building $ARCHIVE..." |
|
|
|
tar xf $CWD/$ARCHIVE |
|
|
|
cd $NAME |
|
|
|
python2 setup.py build |
|
|
|
python2 setup.py install --root=$PKG |
|
|
|
python3 setup.py build |
|
|
|
python3 setup.py install --root=$PKG |
|
|
|
|
|
|
@ -82,7 +77,7 @@ mkdir -p $PKG/usr/doc/$NAMEPKG-$VERSION |
|
|
|
install -m 644 LICENSE.txt PKG-INFO $PKG/usr/doc/$NAMEPKG-$VERSION |
|
|
|
|
|
|
|
# Build API docs if Sphinx and the readthedocs.org theme are available |
|
|
|
if type -p sphinx-build && python -c "import sphinx_rtd_theme" 2>/dev/null ; then |
|
|
|
if type -p sphinx-build && python3 -c "import sphinx_rtd_theme" 2>/dev/null ; then |
|
|
|
make -C docs html |
|
|
|
cp -r docs/_build/html $PKG/usr/doc/$NAMEPKG-$VERSION/html |
|
|
|
fi |
|
|
@ -94,7 +89,6 @@ install -D -m 644 $CWD/slack-desc $PKG/install/slack-desc |
|
|
|
cat <<EOF > $PKG/install/slack-required |
|
|
|
josepy |
|
|
|
pyrfc3339 |
|
|
|
python-mock |
|
|
|
python-requests-toolbelt |
|
|
|
pytz |
|
|
|
EOF |
|
|
|