wok-6.x view python-rpi-gpio/receipt @ rev 24569

sokojs: add shrink.sh (again)
author Pascal Bellard <pascal.bellard@slitaz.org>
date Sat Feb 26 18:46:53 2022 +0000 (2022-02-26)
parents 814362194a8d
children
line source
1 # SliTaz package receipt.
3 PACKAGE="python-rpi-gpio"
4 VERSION="0.5.5"
5 CATEGORY="system-tools"
6 SHORT_DESC="Python class to control the GPIO on a Raspberry Pi."
7 MAINTAINER="pankso@slitaz.org"
8 LICENSE="BSD"
9 SOURCE="RPi.GPIO"
10 TARBALL="$SOURCE-$VERSION.tar.gz"
11 WEB_SITE="https://pypi.python.org/pypi/RPi.GPIO"
12 WGET_URL="https://pypi.python.org/packages/source/R/$SOURCE/$TARBALL"
13 TAGS="raspberrypi rpi"
14 HOST_ARCH="arm"
16 DEPENDS="python python-smbus"
17 BUILD_DEPENDS="python-dev python-setuptools"
19 # What is the latest version available today?
20 current_version()
21 {
22 wget -O - https://pypi.org/project/$SOURCE/ 2>/dev/null | \
23 sed "/$SOURCE-/!d;/tar/!d;s|.*$SOURCE-||;s|.tar.*||;q"
24 }
26 # Rules to configure and make the package.
27 compile_rules()
28 {
29 # Cross compilation hack
30 case "$ARCH" in
31 arm*)
32 mv /usr/bin/i486-slitaz-linux-gcc /tmp &&
33 ln -s /cross/${ARCH}/tools/bin/arm-slitaz-linux-gnueabi-gcc \
34 /usr/bin/i486-slitaz-linux-gcc ;;
35 esac &&
36 python setup.py install --root=$DESTDIR
37 case "$ARCH" in
38 arm*)
39 rm /usr/bin/i486-slitaz-linux-gcc &&
40 mv /tmp/i486-slitaz-linux-gcc /usr/bin ;;
41 esac
42 }
44 # Rules to gen a SliTaz package suitable for Tazpkg.
45 genpkg_rules()
46 {
47 cp -a $install/usr $fs
48 }