source: projects/specs/trunk/k/kbd/kbd-vl.spec @ 11192

Revision 11192, 15.3 KB checked in by tomop, 7 years ago (diff)

kbd-2.0.4-1

Line 
1%global convert_xkb 0
2
3Summary: Tools for configuring the console (keyboard, virtual terminals, etc.)
4Summary(ja): コンソール(キーボードや仮想ターミナル等)を設定するツール群
5Name: kbd
6Version: 2.0.4
7Release: 1%{?_dist_release}
8License: GPL
9Group: System Environment/Base
10Source0: https://www.kernel.org/pub/linux/utils/kbd/kbd-%{version}.tar.xz
11Source1: kbd-latsun-fonts.tar.bz2
12Source2: kbd-latarcyrheb-32.tar.bz2
13Source3: xml2lst.pl
14Source4: vlock.pamd
15Source5: kbdinfo.1
16Source6: cz-map.patch
17Requires: pam >= 0.66-4, /etc/pam.d/system-auth, usermode
18BuildRequires: bison, flex, gettext, pam-devel
19%if 0%{convert_xkb}
20BuildRequires: console-setup
21%endif
22BuildRoot: %{_tmppath}/%{name}-root
23# Patch0: puts additional information into man pages
24Patch0: kbd-1.15-keycodes-man.patch
25# Patch1: sparc modifications
26Patch1: kbd-1.15-sparc.patch
27# Patch2: adds default unicode font to unicode_start script
28Patch2: kbd-1.15-unicode_start.patch
29# Patch3: add missing dumpkeys option to man page
30Patch3: kbd-1.15.3-dumpkeys-man.patch
31# Patch4: fixes decimal separator in Swiss German keyboard layout, bz 882529
32Patch4: kbd-1.15.5-sg-decimal-separator.patch
33# Patch5: adds xkb and legacy keymaps subdirs to loadkyes search path, bz 1028207
34Patch5: kbd-1.15.5-loadkeys-search-path.patch
35# Patch6: don't hardcode font used in unicode_start, take it from vconsole.conf,
36#   bz 1101007
37Patch6: kbd-2.0.2-unicode-start-font.patch
38
39Obsoletes: console-tools open
40Provides: console-tools open
41Conflicts: util-linux < 2.11r-9
42Requires(pre): initscripts >= 5.86-1
43ExcludeArch: s390 s390x
44
45Vendor: Project Vine
46Distribution: Vine Linux
47
48%description
49The %{name} package contains tools for managing a Linux
50system's console's behavior, including the keyboard, the screen
51fonts, the virtual terminals and font files.
52
53%prep
54
55%setup -q -a 1 -a 2
56cp -fp %{SOURCE3} .
57cp -fp %{SOURCE6} .
58%patch0 -p1 -b .keycodes-man
59%patch1 -p1 -b .sparc
60%patch2 -p1 -b .unicode_start
61%patch3 -p1 -b .dumpkeys-man
62%patch4 -p1 -b .sg-decimal-separator
63%if 0%{convert_xkb}
64%patch5 -p1 -b .loadkeys-search-path
65%endif
66%patch6 -p1 -b .unicode-start-font
67
68# 7-bit maps are obsolete; so are non-euro maps
69pushd data/keymaps/i386
70cp qwerty/pt-latin9.map qwerty/pt.map
71cp qwerty/sv-latin1.map qwerty/se-latin1.map
72
73mv azerty/fr.map azerty/fr-old.map
74cp azerty/fr-latin9.map azerty/fr.map
75
76cp azerty/fr-latin9.map azerty/fr-latin0.map # legacy alias
77
78# Rename conflicting keymaps
79mv dvorak/no.map dvorak/no-dvorak.map
80mv fgGIod/trf.map fgGIod/trf-fgGIod.map
81mv olpc/es.map olpc/es-olpc.map
82mv olpc/pt.map olpc/pt-olpc.map
83mv qwerty/cz.map qwerty/cz-qwerty.map
84popd
85
86# remove obsolete "gr" translation
87pushd po
88rm -f gr.po gr.gmo
89popd
90
91# Convert to utf-8
92iconv -f iso-8859-1 -t utf-8 < "ChangeLog" > "ChangeLog_"
93mv "ChangeLog_" "ChangeLog"
94
95%build
96export OLD_PO_FILE_INPUT=yes
97
98# We don't use % {configure} because the ./configure included here does not
99# understand most of the options.
100CFLAGS="$RPM_OPT_FLAGS"; export CFLAGS
101#./configure --prefix=%{_prefix} --datadir=/lib/kbd --mandir=%{_mandir}
102%configure --prefix=%{_prefix} --datadir=/lib/kbd --mandir=%{_mandir} --localedir=%{_datadir}/locale --enable-nls
103make %{?_smp_mflags}
104
105%install
106rm -rf $RPM_BUILD_ROOT
107
108# Basic install.
109make install DESTDIR=$RPM_BUILD_ROOT
110
111# Create additional name for Serbian latin keyboard
112ln -s sr-cy.map.gz $RPM_BUILD_ROOT/lib/kbd/keymaps/i386/qwerty/sr-latin.map.gz
113
114# The rhpl keyboard layout table is indexed by kbd layout names, so we need a
115# Korean keyboard
116ln -s us.map.gz $RPM_BUILD_ROOT/lib/kbd/keymaps/i386/qwerty/ko.map.gz
117
118# Move binaries which we use before /usr is mounted from %{_bindir} to /bin.
119mkdir -p $RPM_BUILD_ROOT/bin
120for binary in setfont dumpkeys kbd_mode unicode_start unicode_stop loadkeys ; do
121
122  mv $RPM_BUILD_ROOT%{_bindir}/$binary $RPM_BUILD_ROOT/bin/
123done
124
125# Some microoptimization
126sed -i -e 's,\<kbd_mode\>,/bin/kbd_mode,g;s,\<setfont\>,/bin/setfont,g' \
127        $RPM_BUILD_ROOT/bin/unicode_start
128
129# Link open to openvt
130ln -s openvt $RPM_BUILD_ROOT%{_bindir}/open
131ln -s openvt.1.gz $RPM_BUILD_ROOT%{_mandir}/man1/open.1.gz
132
133# install kbdinfo manpage
134gzip -c %SOURCE5 > $RPM_BUILD_ROOT/%{_mandir}/man1/kbdinfo.1.gz
135
136# Move locale files to correct place
137cp -r $RPM_BUILD_ROOT/lib/kbd/locale/ $RPM_BUILD_ROOT%{_datadir}/locale
138rm -rf $RPM_BUILD_ROOT/lib/kbd/locale
139
140# Install PAM configuration for vlock
141mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/pam.d
142install -m 644 %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}/pam.d/vlock
143
144%if 0%{convert_xkb}
145# Move original keymaps to legacy directory
146mkdir -p $RPM_BUILD_ROOT/lib/kbd/keymaps/legacy
147mv $RPM_BUILD_ROOT/lib/kbd/keymaps/{amiga,atari,i386,include,mac,ppc,sun} $RPM_B
148UILD_ROOT/lib/kbd/keymaps/legacy
149
150# Convert X keyboard layouts to console keymaps
151mkdir -p $RPM_BUILD_ROOT/lib/kbd/keymaps/xkb
152perl xml2lst.pl < /usr/share/X11/xkb/rules/base.xml > layouts-variants.lst
153while read line; do
154  XKBLAYOUT=`echo "$line" | cut -d " " -f 1`
155  echo "$XKBLAYOUT" >> layouts-list.lst
156  XKBVARIANT=`echo "$line" | cut -d " " -f 2`
157  ckbcomp "$XKBLAYOUT" "$XKBVARIANT" | gzip > $RPM_BUILD_ROOT/lib/kbd/keymaps/xk
158b/"$XKBLAYOUT"-"$XKBVARIANT".map.gz
159done < layouts-variants.lst
160
161# Convert X keyboard layouts (plain, no variant)
162cat layouts-list.lst | sort -u >> layouts-list-uniq.lst
163while read line; do
164  ckbcomp "$line" | gzip > $RPM_BUILD_ROOT/lib/kbd/keymaps/xkb/"$line".map.gz
165done < layouts-list-uniq.lst
166
167# wipe converted layouts which cannot input ASCII (#1031848)
168zgrep -L "U+0041" $RPM_BUILD_ROOT/lib/kbd/keymaps/xkb/* | xargs rm -f
169
170# Rename the converted default fi (kotoistus) layout (#1117891)
171gunzip $RPM_BUILD_ROOT/lib/kbd/keymaps/xkb/fi.map.gz
172mv $RPM_BUILD_ROOT/lib/kbd/keymaps/xkb/fi.map $RPM_BUILD_ROOT/lib/kbd/keymaps/xk
173b/fi-kotoistus.map
174gzip $RPM_BUILD_ROOT/lib/kbd/keymaps/xkb/fi-kotoistus.map
175
176# Fix converted cz layout - add compose rules
177gunzip $RPM_BUILD_ROOT/lib/kbd/keymaps/xkb/cz.map.gz
178patch $RPM_BUILD_ROOT/lib/kbd/keymaps/xkb/cz.map < %{SOURCE6}
179gzip $RPM_BUILD_ROOT/lib/kbd/keymaps/xkb/cz.map
180%endif
181
182%find_lang %{name}
183
184%clean
185[ "${RPM_BUILD_ROOT}" != "/" ] && rm -rf ${RPM_BUILD_ROOT}
186
187%triggerun -- kbd < 1.08-10.2
188/sbin/chkconfig --del keytable || :
189
190%files -f %{name}.lang
191%defattr(-,root,root)
192%doc ChangeLog AUTHORS README COPYING docs/doc/kbd.FAQ*.html docs/doc/font-formats/*.html docs/doc/utf/utf* docs/doc/dvorak/*
193/bin/*
194%{_bindir}/*
195%{_mandir}/*/*
196/lib/kbd
197%config(noreplace) %{_sysconfdir}/pam.d/vlock
198
199
200%changelog
201* Sun Sep 24 2017 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2.0.4-1
202- new upstream release.
203
204* Mon Dec 30 2013 Yoji TOYODA <bsyamato@sea.plala.or.jp> 1.12-22
205- rebuild with VineSeed environment
206
207* Fri Aug 15 2008 Shu KONNO <owa@bg.wakwak.com> 1.12-21vl5
208- applied new versioning policy, spec in utf-8
209
210* Sun May 20 2007 Daisuke SUZUKI <daisuke@linux.or.jp> 1.12-21vl1
211- initial build for Vine Linux based on Fedora package.
212
213* Tue Jan  9 2007 Miloslav Trmac <mitr@redhat.com> - 1.12-21
214- Add a "ko" (Korean) keyboard layout, equivalent to the "us" layout
215  Resolves: #220151
216
217* Thu Dec  7 2006 Miloslav Trmac <mitr@redhat.com> - 1.12-20
218- Document that setkeycodes doesn't affect USB keyboards and that the kernel
219  doesn't provide the raw scan codes by default
220  Resolves: #211803
221
222* Tue Oct 31 2006 Miloslav Trmac <mitr@redhat.com> - 1.12-19
223- Ship "el" translation instead of the obsolete "gr" translation
224  Resolves: #210749
225- Fix %% quoting in %%changelog
226
227* Fri Sep 29 2006 Miloslav Trmac <mitr@redhat.com> - 1.12-18
228- Add a missing tilde to U+00E3 in latarcyrheb-sun16.psfu (#204470)
229
230* Fri Jul 14 2006 Jesse Keating <jkeating@redhat.com> - 1.12-17
231- Obsoletes/Provides open
232- Create a symlink from open to openvt
233
234* Wed Jul 12 2006 Jesse Keating <jkeating@redhat.com> - 1.12-16.1
235- rebuild
236
237* Sun Jul  9 2006 Miloslav Trmac <mitr@redhat.com> - 1.12-16
238- Don't include <asm/kbdio.h> on SPARC (#198040, patch by Dennis Gilmore
239  <dennis@ausil.us>)
240
241* Mon May 29 2006 Miloslav Trmac <mitr@redhat.com> - 1.12-15
242- Fix missing BuildRequires (#193406)
243
244* Mon Mar 27 2006 Miloslav Trmac <mitr@redhat.com> - 1.12-14
245- Don't install resizecons.8 on non-x86 (#186877, patch by Keiichi Mori
246  <kmori@redhat.com>)
247
248* Fri Feb 10 2006 Jesse Keating <jkeating@redhat.com> - 1.12-13.2
249- bump again for double-long bug on ppc(64)
250
251* Tue Feb 07 2006 Jesse Keating <jkeating@redhat.com> - 1.12-13.1
252- rebuilt for new gcc4.1 snapshot and glibc changes
253
254* Fri Jan 20 2006 Miloslav Trmac <mitr@redhat.com> - 1.12-13
255- Fix build with new coreutils
256- Hardcode paths in unicode_start to avoid a few file lookups (#178329)
257- Drop unnecessary Prereq: sed mktemp
258
259* Fri Dec 09 2005 Jesse Keating <jkeating@redhat.com>
260- rebuilt
261
262* Thu Dec  1 2005 Miloslav Trmac <mitr@redhat.com> - 1.12-12
263- Don't reload the keymap in unicode_start (#172425)
264
265* Fri Nov 11 2005 Miloslav Trmac <mitr@redhat.com> - 1.12-11
266- Don't ship character set lists (they are already in glibc-common) and an
267  obsolete copy of kbd.FAQ
268
269* Fri May 20 2005 Miloslav Trmac <mitr@redhat.com> - 1.12-10
270- Don't attempt to open directories as source files (#141634, original patch by
271  Paul Nasrat)
272
273* Tue May 17 2005 Miloslav Trmac <mitr@redhat.com> - 1.12-9
274- Fix another violation of C aliasing rules (#157720, patch by Jan Kratochvil)
275
276* Sat Mar 12 2005 Miloslav Trmac <mitr@redhat.com> - 1.12-8
277- Fix violation of C aliasing rules (#150440)
278
279* Sun Mar  6 2005 Miloslav Trmac <mitr@redhat.com> - 1.12-7
280- Don't run ldconfig
281- Don't strip executables
282
283* Fri Mar  4 2005 Miloslav Trmac <mitr@redhat.com> - 1.12-6
284- Rebuild with gcc4
285
286* Sun Feb 20 2005 Miloslav Trmac <mitr@redhat.com> - 1.12-5
287- Put "Meta_acute" back in German keymaps, just ignore it in (loadkeys -u)
288  (patch by Jochen Schmitt)
289- Don't ship patch backup files, simpler way
290
291* Sat Feb 19 2005 Miloslav Trmac <mitr@redhat.com> - 1.12-4
292- Don't ship a patch backup file
293- Mention in setfont.8 that 512-glyph fonts reduce the number of available
294  colors (#140935, patch by Dmitry Butskoj)
295- Remove "Meta_acute" from German keymaps (#143124)
296- Make the %%triggerun script condition more precise, ignore failure of the
297  script
298
299* Mon Feb 14 2005 Adrian Havill <havill@redhat.com>
300- rebuilt
301
302* Tue Jun 15 2004 Elliot Lee <sopwith@redhat.com>
303- rebuilt
304
305* Thu Feb 26 2004 Adrian Havill <havill@redhat.com>
306- update to 1.12
307
308* Fri Feb 13 2004 Elliot Lee <sopwith@redhat.com>
309- rebuilt
310
311* Wed Jan 14 2004 Bill Nottingham <notting@redhat.com> 1.08-12
312- remove speakup patch at request of author
313
314* Fri Oct 10 2003 Bill Nottingham <notting@redhat.com> 1.08-11
315- remove keytable init script (#106783)
316
317* Tue Aug 12 2003 Adrian Havill <havill@rtedhat.com> 1.08-10.1
318- bump for RHEL
319
320* Tue Aug 12 2003 Adrian Havill <havill@rtedhat.com> 1.08-10
321- apply the rukbd patch (#78218)
322
323* Thu Jul 31 2003 Adrian Havill <havill@redhat.com> 1.08-9
324- don't print "plus before..." warnings about non-supported capslock
325  in unimode <Andries.Brouwer@cwi.nl> (#81855)
326
327* Wed Jul 30 2003 Adrian Havill <havill@redhat.com> 1.08-8
328- replaced Russian keyboard map with working UTF-8 equivalent (#79338)
329
330* Thu Jul 24 2003 Adrian Havill <havill@redhat.com> 1.08-7
331- make euro/latin-9 the default instead of latin-1 and 7-bit (#97013)
332- fix swedish keymap; se, not sv (#88791)
333- add fr-latin0 legacy alias of fr-latin-9 (#88324)
334- add ".map" ext to filename param of init script (#90562)
335
336* Wed Jun 04 2003 Elliot Lee <sopwith@redhat.com>
337- rebuilt
338
339* Thu Mar 06 2003 Florian La Roche <Florian.LaRoche@redhat.de>
340- build new rpm
341
342* Fri Feb 21 2003 Florian La Roche <Florian.LaRoche@redhat.de>
343- ExcludeArch mainframe
344
345* Thu Jan 30 2003 Bill Nottingham <notting@redhat.com> 1.08-4
346- remove condrestart from initscript
347
348* Wed Jan 22 2003 Tim Powers <timp@redhat.com>
349- rebuilt
350
351* Fri Dec  6 2002 Nalin Dahyabhai <nalin@redhat.com> 1.08-2
352- only output terminal unicode init sequence if both stdout and stderr are
353  connected to terminals, so that it doesn't show up when script outputs
354  get piped to files
355
356* Fri Nov 22 2002 Nalin Dahyabhai <nalin@redhat.com> 1.08-1
357- update to 1.08
358- drop updates which went mainline
359
360* Mon Nov 11 2002 Nalin Dahyabhai <nalin@redhat.com> 1.06-27
361- add detached signature
362- remove directory names from PAM configuration so that the same config file
363  can be used for any arch on multilib systems
364
365* Wed Sep  4 2002 Bill Nottingham <notting@redhat.com> 1.06-26
366- don't munge /etc/sysconfig/i18n
367
368* Tue Sep  3 2002 Bill Nottingham <notting@redhat.com> 1.06-25
369- don't run setsysfont in upgrade trigger on console-tools
370
371* Thu Aug 29 2002 Jakub Jelinek <jakub@redhat.com> 1.06-24
372- use cyr-sun16 cyrillic chars in latarcyrheb-sun16 font
373  instead of old LatArCyrHeb-16 chars
374- add Euro character to latarcyrheb-sun16
375- use latarcyrheb-sun16 by default in unicode_start script
376
377* Tue Aug 27 2002 Jakub Jelinek <jakub@redhat.com> 1.06-23
378- add back lat[02]-sun16 fonts plus latarcyrheb-sun16 font
379
380* Thu Aug 22 2002 Karsten Hopp <karsten@redhat.de>
381- needs to conflict with older util-linux packages
382  (kbdrate moved between packages)
383
384* Tue Aug 13 2002 Bill Nottingham <notting@redhat.com> 1.06-21
385- remove Evil Hack in favor of slightly-less-evil-hack in initscripts
386
387* Tue Jul  9 2002 Bill Nottingham <notting@redhat.com> 1.06-20
388- fix speakup keymap names
389
390* Tue Jul 09 2002 Phil Knirsch <pknirsch@redhat.com> 1.06-19
391- Evil hack to make setfont work correctly on all consoles (#68018)
392
393* Thu Jun 27 2002 Bill Nottingham <notting@redhat.com> 1.06-18
394- move unicode_stop to /bin too
395- fix path to loadkeys in keytable.init
396- add in speakup keymaps
397
398* Fri Jun 21 2002 Tim Powers <timp@redhat.com>
399- automated rebuild
400
401* Tue Jun 11 2002 Nalin Dahyabhai <nalin@redhat.com> 1.06-16
402- fix incorrect path in console.apps configuration file
403
404* Thu May 30 2002 Bill Nottingham <notting@redhat.com> 1.06-14
405- move some more stuff to /bin (unicode_start and dependencies)
406
407* Thu May 23 2002 Tim Powers <timp@redhat.com>
408- automated rebuild
409
410* Mon Feb 25 2002 Bernhard Rosenkraenzer <bero@redhat.com> 1.06-12
411- Rebuild in new environment
412
413* Wed Jan 30 2002 Bernhard Rosenkraenzer <bero@redhat.com> 1.06-11
414- Oops, actually list the pam files in %%files
415
416* Tue Jan 29 2002 Bernhard Rosenkraenzer <bero@redhat.com> 1.06-10
417- Add and consolehelper'ify kbdrate
418
419* Tue Jan 29 2002 Bernhard Rosenkraenzer <bero@redhat.com> 1.06-9
420- Re-remove kbdrate
421
422* Thu Jan 24 2002 Bernhard Rosenkraenzer <bero@redhat.com> 1.06-7
423- Fix build in current environment
424- Get rid of kbdrate, it's in util-linux these days
425
426* Wed Jul 18 2001 Matt Wilson <msw@redhat.com>
427- added a patch (Patch4) that allows --tty= in setfont
428- modified patch not to break translations
429
430* Tue Jul  3 2001 Bernhard Rosenkraenzer <bero@redhat.com> 1.06-4
431- Add cyrillic patches from leon@geon.donetsk.ua (#47144)
432
433* Tue Jun 26 2001 Bernhard Rosenkraenzer <bero@redhat.com> 1.06-3
434- Fix "Alt+AltGr=Compose" in qwertz-keyboards
435
436* Mon Jun 25 2001 Bernhard Rosenkraenzer <bero@redhat.com> 1.06-2
437- Fix "make install" and init script (#45327)
438
439* Sat Jun 16 2001 Than Ngo <than@redhat.com>
440- update to 1.0.6
441- use %%{_tmppath}
442- use find_lang
443- support new gettext
444- remove some patch files, which are included in 1.0.6
445- fix to use RPM_OPT_FLAGS
446
447* Thu May  3 2001 Bernhard Rosenkraenzer <bero@redhat.com> 1.05-3
448- Fix up resizecons
449
450* Wed May  2 2001 Bernhard Rosenkraenzer <bero@redhat.com> 1.05-2
451- Build everything, obsoletes console-tools
452- s/Copyright:/License:/
453- License is GPL, not just distributable
454- Add our compose mappings from old console-tools
455- Add triggerpostun -- console-tools magic to get sane fonts and mappings
456
457* Tue Apr 17 2001 Erik Troan <ewt@redhat.com>
458- initial packaging for kbdrate
Note: See TracBrowser for help on using the repository browser.