wok-6.x view kbd/receipt @ rev 25044

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