wok-current annotate tp_smapi64/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 f2bea3663690
children
rev   line source
pascal@20240 1 # SliTaz package receipt.
pascal@20240 2
pascal@20240 3 PACKAGE="tp_smapi64"
pascal@20240 4 SOURCE="tp_smapi"
pascal@20240 5 VERSION="0.41"
pascal@20240 6 CATEGORY="base-system"
pascal@20240 7 SHORT_DESC="IBM ThinkPad SMAPI BIOS driver"
pascal@20240 8 MAINTAINER="domcox@slitaz.org"
pascal@20240 9 LICENSE="GPL2"
pascal@20240 10 TARBALL="$SOURCE-$VERSION.tar.gz"
pascal@20240 11 WEB_SITE="https://github.com/evgeni/tp_smapi"
pascal@20240 12 WGET_URL="https://github.com/downloads/evgeni/$SOURCE/$TARBALL"
pascal@20240 13 PROVIDE="tp_smapi:linux64"
pascal@20240 14
pascal@20240 15 BUILD_DEPENDS="linux64-module-headers linux-source wget \
pascal@20240 16 uclibc-cross-compiler-x86_64"
pascal@20240 17
pascal@20240 18 # Aufs enable chroot
pascal@20240 19 AUFS_NOT_RAMFS="uclibc-cross-compiler-x86_64 is not compatible with aufs+tmpfs 8("
pascal@20240 20
pascal@24304 21 # What is the latest version available today?
pascal@24304 22 current_version()
pascal@24304 23 {
pascal@24304 24 wget -O - $WEB_SITE/releases 2>/dev/null | \
pascal@24304 25 sed '/archive.*tar/!d;s|.*/[A-Za-z_-]*\(.*\).tar.*|\1|;q'
pascal@24304 26 }
pascal@24304 27
pascal@20240 28 # Rules to configure and make the package.
pascal@20240 29 compile_rules()
pascal@20240 30 {
pascal@20240 31 sed -i "s/uname -r/echo $kvers-slitaz64/" Makefile
pascal@20241 32 make modules HDAPS=1 CFLAGS="-Os -pipe -fomit-frame-pointer"
pascal@20240 33 }
pascal@20240 34
pascal@20240 35 # Rules to gen a SliTaz package suitable for Tazpkg.
pascal@20240 36 genpkg_rules()
pascal@20240 37 {
pascal@20240 38 MOD_DIR=lib/modules/$kvers-slitaz64/extra
pascal@20240 39 mkdir -p $fs/$MOD_DIR
pascal@20240 40 cp -a $src/*.ko $fs/$MOD_DIR
pascal@20240 41 }
pascal@20240 42
pascal@20240 43 # Post install/remove commands for Tazpkg.
pascal@20240 44 post_install()
pascal@20240 45 {
pascal@20240 46 chroot "$1/" depmod -a ${EXTRAVERSION#_}-slitaz64
pascal@20240 47 }
pascal@20240 48
pascal@20240 49 post_remove()
pascal@20240 50 {
pascal@20240 51 chroot "$1/" depmod -a ${EXTRAVERSION#_}-slitaz64
pascal@20240 52 }