blob: e382b05d4d516ce80e6188b135137d2b00998ab5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
|
# Contributor: Natanael Copa <ncopa@alpinelinux.org>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=kbd
pkgver=2.0.0
pkgrel=1
pkgdesc="Tools for configuring the console (keyboard, virtual terminals, etc.)"
url="http://ftp.altlinux.org/pub/people/legion/kbd"
arch="all"
license="GPLv2+"
depends="kbd-misc"
makedepends="bison flex autoconf automake linux-pam-dev"
install=""
subpackages="$pkgname-misc $pkgname-doc"
source="ftp://ftp.altlinux.org/pub/people/legion/kbd/kbd-$pkgver.tar.gz
"
_builddir="$srcdir"/kbd-$pkgver
prepare() {
local i
cd "$_builddir"
for i in $source; do
case $i in
*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
esac
done
aclocal -I m4 && autoreconf || return 1
# fixes from fedora
# 7-bit maps are obsolete; so are non-euro maps
cd "$_builddir"/data/keymaps/i386
mv qwerty/fi.map qwerty/fi-old.map
cp qwerty/fi-latin9.map qwerty/fi.map
cp qwerty/pt-latin9.map qwerty/pt.map
cp qwerty/sv-latin1.map qwerty/se-latin1.map
mv azerty/fr.map azerty/fr-old.map
cp azerty/fr-latin9.map azerty/fr.map
cp azerty/fr-latin9.map azerty/fr-latin0.map # legacy alias
# Rename conflicting keymaps
mv dvorak/no.map dvorak/no-dvorak.map
mv fgGIod/trf.map fgGIod/trf-fgGIod.map
mv olpc/es.map olpc/es-olpc.map
mv olpc/pt.map olpc/pt-olpc.map
mv qwerty/cz.map qwerty/cz-qwerty.map
}
build() {
cd "$_builddir"
./configure \
--build=$CBUILD \
--host=$CHOST \
--prefix=/usr \
--datadir=/lib/kbd \
--localedir=/usr/share/locale \
--disable-nls \
--mandir=/usr/share/man \
|| return 1
make || return 1
}
package() {
cd "$_builddir"
make DESTDIR="$pkgdir" install || return 1
rm -f "$pkgdir"/usr/lib/*.la
# ro_win.map.gz is useless
rm -f "$pkgdir"/lib/kbd/keymaps/i386/qwerty/ro_win.map.gz
# Create additional name for Serbian latin keyboard
ln -s sr-cy.map.gz "$pkgdir"/lib/kbd/keymaps/i386/qwerty/sr-latin.map.gz
# The rhpl keyboard layout table is indexed by kbd layout names,
# so we need a Korean keyboard
ln -s us.map.gz "$pkgdir"/lib/kbd/keymaps/i386/qwerty/ko.map.gz
# Move binaries which we use before /usr is mounted to /bin.
mkdir -p "$pkgdir"/bin
for binary in setfont dumpkeys kbd_mode unicode_start unicode_stop loadkeys ; do
mv "$pkgdir"/usr/bin/$binary "$pkgdir"/bin/ || return 1
done
# Link open to openvt
ln -s openvt "$pkgdir"/usr/bin/open
}
misc() {
pkgdesc="Data for kbd package"
arch="noarch"
depends=
mkdir -p "$subpkgdir"/lib
mv "$pkgdir"/lib/kbd "$subpkgdir"/lib/
}
md5sums="5ba259a0b2464196f6488a72070a3d60 kbd-2.0.0.tar.gz"
sha256sums="960f0ac40eba90a699e66d8241b34ef9471e5f1e5cf20c6114d28f96b368c1e6 kbd-2.0.0.tar.gz"
sha512sums="44f950b68080106da824bd0db37718a52085ebeacd047f4da3d00beffd7d13f9a1aad756dd7ef474a51e266cb2c3d49e30f64401cf39af31e0c9dd2dd946b991 kbd-2.0.0.tar.gz"
|