* Mon Aug 04 2008 Adam Jackson <ajax@redhat.com> 1.4.99.906-3
- 10-x11-keymap.fdi, fedora-setup-keyboard: Attempt to read keyboard settings from /etc/sysconfig/keyboard and stuff them into hal.
This commit is contained in:
parent
91482befe9
commit
59994a9d39
8
10-x11-keymap.fdi
Normal file
8
10-x11-keymap.fdi
Normal file
@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="ISO-8859-1"?> <!-- -*- SGML -*- -->
|
||||
<deviceinfo version="0.2">
|
||||
<device>
|
||||
<match key="input.xkb.layout" exists="true">
|
||||
<append key="info.callouts.add" type="strlist">fedora-setup-keyboard</append>
|
||||
</match>
|
||||
</device>
|
||||
</deviceinfo>
|
33
fedora-setup-keyboard
Normal file
33
fedora-setup-keyboard
Normal file
@ -0,0 +1,33 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
# Trivial egregious hack to load the console keyboard layout into XKB.
|
||||
#
|
||||
# Yes, this should really just be written in python. If you can figure
|
||||
# out how to make hal callouts written in python _work_, then please
|
||||
# let me know. In the meantime, we'll do this.
|
||||
|
||||
[[ -x /usr/bin/python ]] || exit 0
|
||||
[[ -x /usr/bin/hal-set-property ]] || exit 0
|
||||
|
||||
source /etc/sysconfig/keyboard >& /dev/null || exit 0
|
||||
|
||||
[[ -n "$KEYTABLE" ]] || exit 0
|
||||
|
||||
rhplquery () {
|
||||
/usr/bin/python -c "import rhpl.keyboard_models; m = rhpl.keyboard_models.KeyboardModels().get_models(); print \"junk='%s' layout='%s' model='%s' variant='%s' options='%s'\" % tuple(m[\"$1\"])" || echo "exit 0"
|
||||
}
|
||||
|
||||
eval `rhplquery $KEYTABLE`
|
||||
|
||||
hal_set () {
|
||||
if [[ -n "${!1}" ]]; then
|
||||
/usr/bin/hal-set-property --direct --udi "$UDI" --key input.xkb.$1 --string "${!1}"
|
||||
else
|
||||
/usr/bin/hal-set-property --direct --udi "$UDI" --key input.xkb.$1 --remove
|
||||
fi
|
||||
}
|
||||
|
||||
hal_set layout
|
||||
hal_set model
|
||||
hal_set variant
|
||||
hal_set options
|
@ -35,6 +35,10 @@ Source2: commitid
|
||||
Source0: http://www.x.org/pub/individual/xserver/%{pkgname}-%{version}.tar.bz2
|
||||
%endif
|
||||
|
||||
# keyboard enablement
|
||||
Source10: 10-x11-keymap.fdi
|
||||
Source11: fedora-setup-keyboard
|
||||
|
||||
# OpenGL compositing manager feature/optimization patches.
|
||||
Patch100: xorg-x11-server-1.1.0-no-move-damage.patch
|
||||
Patch101: xserver-1.4.99-dont-backfill-bg-none.patch
|
||||
@ -312,6 +316,11 @@ mkdir -p $RPM_BUILD_ROOT%{_libdir}/xorg/modules/{drivers,input}
|
||||
# be able to parse the same modelist as the X server uses (rhpxl).
|
||||
mkdir -p $RPM_BUILD_ROOT%{_datadir}/xorg
|
||||
install -m 0444 hw/xfree86/common/{vesa,extra}modes $RPM_BUILD_ROOT%{_datadir}/xorg/
|
||||
|
||||
# fedora-isms to slurp keyboard settings out of /etc/sysconfig/keyboard
|
||||
mkdir -p $RPM_BUILD_ROOT%{_datadir}/hal/fdi/policy/10osvendor
|
||||
install -m 0444 %{SOURCE10} $RPM_BUILD_ROOT%{_datadir}/hal/fdi/policy/10osvendor
|
||||
install -m 0755 %{SOURCE11} $RPM_BUILD_ROOT%{_bindir}
|
||||
%endif
|
||||
|
||||
# Make the source package
|
||||
@ -377,9 +386,11 @@ rm -rf $RPM_BUILD_ROOT
|
||||
%defattr(-,root,root,-)
|
||||
%{_bindir}/X
|
||||
%attr(4711, root, root) %{_bindir}/Xorg
|
||||
%{_bindir}/gtf
|
||||
%{_bindir}/cvt
|
||||
%{_bindir}/fedora-setup-keyboard
|
||||
%{_bindir}/gtf
|
||||
%dir %{_datadir}/xorg
|
||||
%{_datadir}/hal/fdi/policy/10osvendor/10-x11-keymap.fdi
|
||||
%{_datadir}/xorg/vesamodes
|
||||
%{_datadir}/xorg/extramodes
|
||||
%dir %{_libdir}/xorg
|
||||
@ -477,6 +488,10 @@ rm -rf $RPM_BUILD_ROOT
|
||||
|
||||
|
||||
%changelog
|
||||
* Mon Aug 04 2008 Adam Jackson <ajax@redhat.com> 1.4.99.906-3
|
||||
- 10-x11-keymap.fdi, fedora-setup-keyboard: Attempt to read keyboard settings
|
||||
from /etc/sysconfig/keyboard and stuff them into hal.
|
||||
|
||||
* Thu Jul 31 2008 Adam Jackson <ajax@redhat.com> 1.4.99.906-2
|
||||
- Drop the evdev keyboarding patch.
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user