wok view libmcp23s17/receipt @ rev 25672

Up minidlna (1.3.3), phpmyadmin (5.2.1), pidgin (2.14.13), redis (7.2.4), rsync (3.2.7), rust (1.76.0), screen (4.9.1), squashfs (4.6.1), squid (6.7), stunnel (5.72), tcpdump (4.99.4)
author Pascal Bellard <pascal.bellard@slitaz.org>
date Mon Feb 26 14:07:44 2024 +0000 (8 months ago)
parents 59547e97954f
children
line source
1 # SliTaz package receipt.
3 PACKAGE="libmcp23s17"
4 VERSION="0.3.0"
5 CATEGORY="system-tools"
6 SHORT_DESC="A simple C library for accessing an MCP23S17 port expander."
7 MAINTAINER="pankso@slitaz.org"
8 LICENSE="GPL3"
9 TARBALL="$PACKAGE-$VERSION.tar.gz"
10 WEB_SITE="https://github.com/piface/libmcp23s17"
11 WGET_URL="https://github.com/piface/libmcp23s17/archive/v${VERSION}.tar.gz"
12 HOST_ARCH="arm"
14 DEPENDS="i2c-tools"
15 TAGS="raspberrypi rpi"
17 # What is the latest version available today?
18 current_version()
19 {
20 wget -O - ${WGET_URL%/arch*}/releases 2>/dev/null | \
21 sed '/tag\//!d;s|.*tag/v*||;s|".*||;q'
22 }
24 # Rules to configure and make the package.
25 compile_rules()
26 {
27 sed -i \
28 -e s"/^CC=gcc/CC=${HOST_SYSTEM}-gcc/" \
29 -e s"/^CFLAGS=.*/CFLAGS=-c -Wall $CFLAGS/" Makefile
30 make &&
31 ${HOST_SYSTEM}-gcc -o mcp23s17-example example.c -Isrc/ -L. -lmcp23s17
32 }
34 # Rules to gen a SliTaz package suitable for Tazpkg.
35 genpkg_rules()
36 {
37 mkdir -p $fs/usr/bin $fs/usr/lib $fs/usr/include
38 cp -a ${src}/*-example $fs/usr/bin
39 cp -a ${src}/${PACKAGE}.a ${fs}/usr/lib
40 cp -a ${src}/src/mcp23s17.h ${fs}/usr/include
41 }