wok annotate ola/receipt @ rev 24055

Add current_version for most github hosted softwares
author Pascal Bellard <pascal.bellard@slitaz.org>
date Tue Jun 08 08:46:05 2021 +0000 (2021-06-08)
parents 4e8d50d02b70
children 9773d49d458c
rev   line source
pascal@11226 1 # SliTaz package receipt.
pascal@11226 2
pascal@11226 3 PACKAGE="ola"
al@18702 4 VERSION="0.9.8"
pascal@11226 5 CATEGORY="network"
al@18702 6 SHORT_DESC="Open Lighting Architecture"
pascal@11258 7 MAINTAINER="kult-ex@aon.at"
pascal@14996 8 LICENSE="LGPL2.1"
pascal@11226 9 TARBALL="$PACKAGE-$VERSION.tar.gz"
al@18702 10 WEB_SITE="https://www.openlighting.org/ola/"
al@18702 11 WGET_URL="https://github.com/OpenLightingProject/ola/archive/$VERSION.tar.gz"
pascal@11226 12
al@18702 13 DEPENDS="libftdi liblo libmicrohttpd ncurses protobuf"
al@18702 14 BUILD_DEPENDS="libtool flex protobuf-dev util-linux-uuid-dev cppunit-dev \
al@18702 15 libmicrohttpd-dev libftdi-dev libusb-dev liblo-dev ncurses-dev"
pascal@11226 16
pascal@24055 17 current_version()
pascal@24055 18 {
pascal@24055 19 wget -O - ${WGET_URL%/arch*}/releases 2>/dev/null | \
pascal@24055 20 sed '/archive.*tar/!d;s|.*/\(.*\).tar.*|\1|;q'
pascal@24055 21 }
pascal@24055 22
pascal@11226 23 # Rules to configure and make the package.
pascal@11226 24 compile_rules()
pascal@11226 25 {
pascal@21400 26 sed -i 's|libusb_set_debug(m_context,\(.*\);|#if LIBUSB_API_VERSION >= 0x01000106\
pascal@21400 27 libusb_set_option(m_context, LIBUSB_OPTION_LOG_LEVEL,\1;\
pascal@21400 28 #else\
pascal@21400 29 \0\
pascal@21400 30 #endif|' tools/ja-rule/USBDeviceManager.cpp plugins/usbdmx/*yncPluginImpl.cpp
pascal@17670 31 export LDFLAGS="$LDFLAGS -ltinfo"
al@18702 32 autoreconf -i
pascal@11226 33 ./configure \
pascal@11226 34 --prefix=/usr \
pascal@11226 35 $CONFIGURE_ARGS &&
pascal@11226 36 make && make install
pascal@11226 37 }
pascal@11226 38
pascal@11226 39 # Rules to gen a SliTaz package suitable for Tazpkg.
pascal@11226 40 genpkg_rules()
pascal@11226 41 {
pascal@11226 42 mkdir -p $fs/usr/lib/olad
pascal@11226 43 cp -a $install/usr/bin $fs/usr
pascal@11226 44 cp -a $install/usr/lib/*.so* $fs/usr/lib
pascal@11226 45 cp -a $install/usr/share $fs/usr
pascal@11226 46 }