wok-6.x view dhid/receipt @ rev 24439
Add some current_version
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Sun Feb 13 18:01:32 2022 +0000 (2022-02-13) |
parents | 429355d87af5 |
children | bc2b9d9bed6f |
line source
1 # SliTaz package receipt.
3 PACKAGE="dhid"
4 VERSION="5.5"
5 CATEGORY="network"
6 SHORT_DESC="Open source Dynamic IP Updater."
7 MAINTAINER="pankso@slitaz.org"
8 LICENSE="BSD"
9 TARBALL="$PACKAGE-$VERSION.tar.gz"
10 WEB_SITE="http://dhis.org"
11 WGET_URL="ftp://ftp.dhis.org/pub/dhis/$TARBALL"
12 CONFIG_FILES="/etc/dhid.conf"
13 HOST_ARCH="i486 arm"
15 DEPENDS="gmp"
16 BUILD_DEPENDS="gmp-dev"
18 # What is the latest version available today?
19 current_version()
20 {
21 wget -O - ${WGET_URL%/*}/ 2>/dev/null | \
22 sed "/latest/d;/$PACKAGE-[0-9]/!d;/tar/!d;s|.*$PACKAGE-\\(.*\\).tar.*\".*|\\1|" | sort -Vr | sed q
23 }
25 # Handle cross comilation
26 case "$ARCH" in
27 arm) ARCH_FLAGS=" LFLAGS=-L/cross/$ARCH/sysroot/usr/lib" ;;
28 esac
30 # Rules to configure and make the package.
31 compile_rules()
32 {
33 make CC=${HOST_SYSTEM}-gcc ${ARCH_FLAGS}
34 }
36 # Rules to gen a SliTaz package suitable for Tazpkg.
37 genpkg_rules()
38 {
39 mkdir -p $fs/usr/sbin $fs/etc $fs/usr/share/doc/dhid
40 cp ${src}/dhid.conf.sample ${fs}/etc/dhid.conf
41 cp ${src}/README ${fs}/usr/share/doc/dhid
42 cp -a ${src}/dhid ${fs}/usr/sbin
43 cp -a ${stuff}/init.d ${fs}/etc
44 }