wok annotate kbd/receipt @ rev 25599
Update some current_version
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Sun Jul 16 13:38:12 2023 +0000 (10 months ago) |
parents | da39e47234a2 |
children |
rev | line source |
---|---|
pankso@708 | 1 # SliTaz package receipt. |
pankso@708 | 2 |
pankso@708 | 3 PACKAGE="kbd" |
Hans-G?nter@24697 | 4 VERSION="2.4.0" |
pankso@708 | 5 CATEGORY="system-tools" |
Hans-G?nter@21089 | 6 TAGS="keyboard" |
Hans-G?nter@21089 | 7 SHORT_DESC="Keyboard mapping definitions and tools." |
pankso@708 | 8 MAINTAINER="pankso@slitaz.org" |
pascal@14770 | 9 LICENSE="GPL2" |
Hans-G?nter@24697 | 10 WEB_SITE="https://kbd-project.org/" |
Hans-G?nter@21089 | 11 |
al@17920 | 12 TARBALL="$PACKAGE-$VERSION.tar.xz" |
pascal@17923 | 13 WGET_URL="https://www.kernel.org/pub/linux/utils/kbd/$TARBALL" |
pankso@12882 | 14 |
Hans-G?nter@24697 | 15 SUGGESTED="kbd-lang" |
Hans-G?nter@24697 | 16 DEPENDS="gcc83-lib-base kbd-base" |
Hans-G?nter@24697 | 17 BUILD_DEPENDS="advancecomp automake check-dev flex gcc83 pam-dev" |
Hans-G?nter@22981 | 18 |
Hans-G?nter@21089 | 19 HOST_ARCH="i486 arm" |
pankso@15943 | 20 |
pankso@15943 | 21 # Handle cross compilation. |
pankso@15943 | 22 case "$ARCH" in |
Hans-G?nter@21089 | 23 arm) BUILD_DEPENDS="check-dev flex" ;; |
pankso@15943 | 24 esac |
pankso@708 | 25 |
Hans-G?nter@24697 | 26 # @maintainer: Please update also: kbd-base, kbd-busybox, kbd-lang and kbd-vlock |
Hans-G?nter@24697 | 27 |
pascal@25599 | 28 # What is the latest version available today? |
pascal@24093 | 29 current_version() |
pascal@24093 | 30 { |
pascal@24093 | 31 wget -O - https://github.com/legionus/kbd/releases 2>/dev/null | \ |
pascal@25599 | 32 sed '/tag\//!d;s|.*tag/v*||;s|".*||;q' |
pascal@24093 | 33 } |
pascal@24093 | 34 |
pankso@708 | 35 # Rules to configure and make the package. |
pankso@708 | 36 compile_rules() |
pankso@708 | 37 { |
al@14904 | 38 # standard locale placement |
Hans-G?nter@24697 | 39 # 2.4.0 no longer required |
Hans-G?nter@24697 | 40 # sed -i 's|localedir = .*|localedir = @localedir@|' \ |
Hans-G?nter@24697 | 41 # po/Makefile.in.in |
Hans-G?nter@21089 | 42 |
pankso@15943 | 43 # Handle cross compilation. |
pankso@15943 | 44 case "$ARCH" in |
Hans-G?nter@24697 | 45 (arm) |
pankso@15943 | 46 # No PAM support for ARM |
Hans-G?nter@21089 | 47 ./configure \ |
Hans-G?nter@21089 | 48 --datadir=/usr/share/kbd \ |
Hans-G?nter@21089 | 49 --localedir=/usr/share/locale \ |
Hans-G?nter@21089 | 50 --disable-vlock \ |
Hans-G?nter@24697 | 51 $CONFIGURE_ARGS |
Hans-G?nter@24697 | 52 ;; |
Hans-G?nter@24697 | 53 (i486) |
Hans-G?nter@21089 | 54 ./configure \ |
Hans-G?nter@24697 | 55 CC=gcc-83 \ |
Hans-G?nter@24697 | 56 CXX=g++-83 \ |
Hans-G?nter@21089 | 57 --datadir=/usr/share/kbd \ |
Hans-G?nter@21089 | 58 --localedir=/usr/share/locale \ |
Hans-G?nter@24697 | 59 $CONFIGURE_ARGS |
Hans-G?nter@24697 | 60 ;; |
pankso@15943 | 61 esac && |
Hans-G?nter@24697 | 62 |
Hans-G?nter@24697 | 63 make && |
Hans-G?nter@21089 | 64 make install && |
Hans-G?nter@21089 | 65 |
pascal@19248 | 66 find $DESTDIR/usr/share/kbd -name '*gz' -exec advdef -z4 {} \; |
pankso@708 | 67 } |
pankso@708 | 68 |
pascal@19248 | 69 |
pankso@708 | 70 # Rules to gen a SliTaz package suitable for Tazpkg. |
pankso@708 | 71 genpkg_rules() |
pankso@708 | 72 { |
pankso@708 | 73 mkdir -p $fs/usr/share |
pankso@12882 | 74 |
al@14904 | 75 # Copy all kbd files (should we split fonts?) |
Hans-G?nter@22981 | 76 cp -a $install/usr/share/kbd $fs/usr/share |
pankso@12882 | 77 |
pankso@708 | 78 # Tools |
Hans-G?nter@22981 | 79 cp -a $install/usr/bin $fs/usr |
al@14904 | 80 |
al@14904 | 81 # Remove files provided by kbd-base and kbd-vlock. |
Hans-G?nter@22981 | 82 for keymap in $(cat $WOK/kbd-base/stuff/keymaps-path.list) |
Hans-G?nter@22981 | 83 do |
Hans-G?nter@24697 | 84 rm -f $fs/usr/share/kbd/keymaps/i386/$keymap |
Hans-G?nter@22981 | 85 done |
Hans-G?nter@22981 | 86 rm -rf $fs/usr/share/kbd/keymaps/include |
Hans-G?nter@22981 | 87 rm -rf $fs/usr/share/kbd/keymaps/i386/include |
Hans-G?nter@22981 | 88 rm -f $fs/usr/bin/loadkeys |
Hans-G?nter@22981 | 89 rm -f $fs/usr/bin/setfont |
Hans-G?nter@22981 | 90 rm -f $fs/usr/bin/vlock |
pankso@708 | 91 } |
pankso@708 | 92 |
pascal@8878 | 93 # Overlap busybox |
pascal@8878 | 94 pre_install() |
pascal@8878 | 95 { |
pankso@12882 | 96 rm -f $root/usr/bin/deallocvt |
pankso@12882 | 97 rm -f $root/usr/bin/chvt |
pankso@12882 | 98 rm -f $root/usr/bin/setkeycodes |
pankso@12882 | 99 rm -f $root/usr/bin/openvt |
pankso@12882 | 100 rm -f $root/usr/bin/kbd_mode |
pascal@8878 | 101 } |
pascal@8878 | 102 |
pascal@8878 | 103 post_remove() |
pascal@8878 | 104 { |
pankso@12882 | 105 ln -s /bin/busybox $root/usr/bin/deallocvt |
pankso@12882 | 106 ln -s /bin/busybox $root/usr/bin/chvt |
pankso@12882 | 107 ln -s /bin/busybox $root/usr/bin/setkeycodes |
pankso@12882 | 108 ln -s /bin/busybox $root/usr/bin/openvt |
pankso@12882 | 109 ln -s /bin/busybox $root/usr/bin/kbd_mode |
pascal@8878 | 110 } |