diff options
author | fourtysixandtwo <fourtysixandtwo@sliderr.net> | 2022-05-14 08:50:17 +0700 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2022-05-14 19:27:50 +0700 |
commit | cdcb1735df749b0b873a240efa40331cab77a163 (patch) | |
tree | 2db74116ce9a0433faedc426509cfabd2a8c37ba /python/click-legacy7 | |
parent | 5a863426ecff8d161ef712c471a5503e1b936b81 (diff) | |
download | slackbuilds-cdcb1735df749b0b873a240efa40331cab77a163.tar.gz |
python/click-legacy7: Added (Python command line utility).
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'python/click-legacy7')
-rw-r--r-- | python/click-legacy7/README | 16 | ||||
-rw-r--r-- | python/click-legacy7/click-legacy7.SlackBuild | 95 | ||||
-rw-r--r-- | python/click-legacy7/click-legacy7.info | 10 | ||||
-rw-r--r-- | python/click-legacy7/slack-desc | 19 |
4 files changed, 140 insertions, 0 deletions
diff --git a/python/click-legacy7/README b/python/click-legacy7/README new file mode 100644 index 0000000000..f2c0b2a048 --- /dev/null +++ b/python/click-legacy7/README @@ -0,0 +1,16 @@ +$ click-legacy7_ + +Click is a Python package for creating beautiful command line interfaces +in a composable way with as little code as necessary. It's the "Command +Line Interface Creation Kit". It's highly configurable but comes with +sensible defaults out of the box. + +It aims to make the process of writing command line tools quick and +fun while also preventing any frustration caused by the inability to +implement an intended CLI API. + +NOTE: +-This is a legacy version of click that supports python 2 and 3. + +IMPORTANT: +-Conflicts with click and both cannot be installed at the same time. diff --git a/python/click-legacy7/click-legacy7.SlackBuild b/python/click-legacy7/click-legacy7.SlackBuild new file mode 100644 index 0000000000..92b0a03052 --- /dev/null +++ b/python/click-legacy7/click-legacy7.SlackBuild @@ -0,0 +1,95 @@ +#!/bin/bash + +# Slackware build script for click-legacy7 + +# Copyright 2022 fourtysixandtwo <fourtysixandtwo@sliderr.net> +# Copyright 2014-2018 Dimitris Zlatanidis Orestiada, Greece +# All rights reserved. +# +# Redistribution and use of this script, with or without modification, is +# permitted provided that the following conditions are met: +# +# 1. Redistributions of this script must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR IMPLIED +# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO +# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; +# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR +# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +cd $(dirname $0) ; CWD=$(pwd) + +PRGNAM=click-legacy7 +SRCNAM=$(echo $PRGNAM | cut -c-5) +VERSION=${VERSION:-7.1.2} +BUILD=${BUILD:-1} +TAG=${TAG:-_SBo} +PKGTYPE=${PKGTYPE:-tgz} + +if [ -z "$ARCH" ]; then + case "$( uname -m )" in + i?86) ARCH=i586 ;; + arm*) ARCH=arm ;; + *) ARCH=$( uname -m ) ;; + esac +fi + +if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then + echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE" + exit 0 +fi + +TMP=${TMP:-/tmp/SBo} +PKG=$TMP/package-$PRGNAM +OUTPUT=${OUTPUT:-/tmp} + +if [ "$ARCH" = "i586" ]; then + SLKCFLAGS="-O2 -march=i586 -mtune=i686" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "i686" ]; then + SLKCFLAGS="-O2 -march=i686 -mtune=i686" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "x86_64" ]; then + SLKCFLAGS="-O2 -fPIC" + LIBDIRSUFFIX="64" +else + SLKCFLAGS="-O2" + LIBDIRSUFFIX="" +fi + +set -e + +rm -rf $PKG +mkdir -p $TMP $PKG $OUTPUT +cd $TMP +rm -rf $SRCNAM-$VERSION +tar xvf $CWD/$SRCNAM-$VERSION.tar.gz +cd $SRCNAM-$VERSION +chown -R root:root . +find -L . \ + \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ + -o -perm 511 \) -exec chmod 755 {} \; -o \ + \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ + -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; + +python2 setup.py install --root=$PKG +python3 setup.py install --root=$PKG + +find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \ + | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true + +mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION +cp -a CHANGES.rst LICENSE.rst README.rst docs/*.rst $PKG/usr/doc/$PRGNAM-$VERSION +cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild + +mkdir -p $PKG/install +cat $CWD/slack-desc > $PKG/install/slack-desc + +cd $PKG +/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE diff --git a/python/click-legacy7/click-legacy7.info b/python/click-legacy7/click-legacy7.info new file mode 100644 index 0000000000..2de6eff31b --- /dev/null +++ b/python/click-legacy7/click-legacy7.info @@ -0,0 +1,10 @@ +PRGNAM="click-legacy7" +VERSION="7.1.2" +HOMEPAGE="https://github.com/mitsuhiko/click" +DOWNLOAD="https://files.pythonhosted.org/packages/source/c/click/click-7.1.2.tar.gz" +MD5SUM="53692f62cb99a1a10c59248f1776d9c0" +DOWNLOAD_x86_64="" +MD5SUM_x86_64="" +REQUIRES="" +MAINTAINER="fourtysixandtwo" +EMAIL="fourtysixandtwo@sliderr.net" diff --git a/python/click-legacy7/slack-desc b/python/click-legacy7/slack-desc new file mode 100644 index 0000000000..70587976c0 --- /dev/null +++ b/python/click-legacy7/slack-desc @@ -0,0 +1,19 @@ +# HOW TO EDIT THIS FILE: +# The "handy ruler" below makes it easier to edit a package description. +# Line up the first '|' above the ':' following the base package name, and +# the '|' on the right side marks the last column you can put a character in. +# You must make exactly 11 lines for the formatting to be correct. It's also +# customary to leave one space after the ':' except on otherwise blank lines. + + |-----handy-ruler------------------------------------------------------| +click-legacy7: click-legacy7 (Python composable command line utility) +click-legacy7: +click-legacy7: Click is a Python package for creating beautiful command line +click-legacy7: interfaces in a composable way with as little code as necessary. +click-legacy7: It's the "Command Line Interface Creation Kit". It's highly +click-legacy7: configurable but comes with sensible defaults out of the box. +click-legacy7: +click-legacy7: Homepage: https://github.com/mitsuhiko/click +click-legacy7: +click-legacy7: +click-legacy7: |