packages: system-config-keyboard/system-config-keyboard.spec, system-config...
glen
glen at pld-linux.org
Sat Mar 3 16:15:37 CET 2012
Author: glen Date: Sat Mar 3 15:15:37 2012 GMT
Module: packages Tag: HEAD
---- Log message:
- up to 1.3.1
---- Files affected:
packages/system-config-keyboard:
system-config-keyboard.spec (1.17 -> 1.18) , s-c-keyboard-do_not_remove_the_OK_button.patch (NONE -> 1.1) (NEW), sck-1.3.1-no-pyxf86config.patch (NONE -> 1.1) (NEW), system-config-keyboard-beenset.patch (1.1 -> NONE) (REMOVED), system-config-keyboard-fixcomments.patch (1.1 -> NONE) (REMOVED)
---- Diffs:
================================================================
Index: packages/system-config-keyboard/system-config-keyboard.spec
diff -u packages/system-config-keyboard/system-config-keyboard.spec:1.17 packages/system-config-keyboard/system-config-keyboard.spec:1.18
--- packages/system-config-keyboard/system-config-keyboard.spec:1.17 Fri Feb 4 19:24:04 2011
+++ packages/system-config-keyboard/system-config-keyboard.spec Sat Mar 3 16:15:31 2012
@@ -2,20 +2,19 @@
Summary: A graphical interface for modifying the keyboard
Summary(pl.UTF-8): Graficzny interfejs do zmiany klawiatury
Name: system-config-keyboard
-Version: 1.2.15
-Release: 7
-License: GPL
+Version: 1.3.1
+Release: 0.10
+License: GPL v2+
Group: Base
-# https://fedorahosted.org/releases/s/y/system-config-keyboard/ (not yet)
-Source0: %{name}-%{version}.tar.gz
-# Source0-md5: 13a0e4444f7fcbb6a3e9c88f42285faf
-Patch1: %{name}-beenset.patch
-Patch2: %{name}-fixcomments.patch
+Source0: https://fedorahosted.org/releases/s/y/system-config-keyboard/%{name}-%{version}.tar.gz
+# Source0-md5: 012b1aec6d237f853bea6824e71d19ed
+Patch0: s-c-keyboard-do_not_remove_the_OK_button.patch
+Patch1: sck-1.3.1-no-pyxf86config.patch
URL: https://fedorahosted.org/system-config-keyboard/
BuildRequires: desktop-file-utils
BuildRequires: gettext-devel
BuildRequires: intltool
-BuildRequires: sed >= 4
+BuildRequires: sed >= 4.0
Requires(post,postun): gtk-update-icon-cache
Requires(post,postun): hicolor-icon-theme
Requires: firstboot >= 1.99
@@ -24,8 +23,6 @@
Requires: python-rhpl >= 0.53
Requires: python-xf86config
BuildArch: noarch
-ExclusiveOS: Linux
-ExcludeArch: s390 s390x ppc64
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%description
@@ -38,15 +35,18 @@
%prep
%setup -q
+%patch0 -p1
%patch1 -p1
-%patch2 -p0
+
+%build
+%{__make}
%install
rm -rf $RPM_BUILD_ROOT
-
%{__make} install \
INSTROOT=$RPM_BUILD_ROOT
+
desktop-file-install --vendor system --delete-original \
--dir $RPM_BUILD_ROOT%{_desktopdir} \
--add-category Application \
@@ -55,9 +55,12 @@
sed -i 's/\.py/.pyc/' $RPM_BUILD_ROOT%{_sbindir}/system-config-keyboard
-%py_comp $RPM_BUILD_ROOT%{_datadir}/system-config-keyboard
-%py_ocomp $RPM_BUILD_ROOT%{_datadir}/system-config-keyboard
-%py_postclean %{_datadir}/system-config-keyboard
+%py_ocomp $RPM_BUILD_ROOT%{py_sitescriptdir}
+%py_comp $RPM_BUILD_ROOT%{py_sitescriptdir}
+%py_ocomp $RPM_BUILD_ROOT%{_datadir}/%{name}
+%py_comp $RPM_BUILD_ROOT%{_datadir}/%{name}
+
+%py_postclean %{_datadir}/%{name}
%find_lang %{name}
@@ -72,16 +75,24 @@
%files -f %{name}.lang
%defattr(644,root,root,755)
-%config(noreplace) %verify(not md5 mtime size) /etc/security/console.apps/system-config-keyboard
-%config(noreplace) %verify(not md5 mtime size) /etc/pam.d/system-config-keyboard
-%attr(755,root,root) %{_sbindir}/system-config-keyboard
-%dir %{_datadir}/system-config-keyboard
-%{_datadir}/system-config-keyboard/*
+%config(noreplace) %verify(not md5 mtime size) /etc/security/console.apps/%{name}
+%config(noreplace) %verify(not md5 mtime size) /etc/pam.d/%{name}
+%attr(755,root,root) %{_bindir}/%{name}
+%attr(755,root,root) %{_sbindir}/%{name}
+%dir %{_datadir}/%{name}
+%{_datadir}/%{name}/*.py[co]
+%dir %{_datadir}/%{name}/pixmaps
+%{_datadir}/%{name}/pixmaps/%{name}.png
+%{_desktopdir}/%{name}.desktop
+%{_iconsdir}/hicolor/*/apps/%{name}.png
+
%dir %{_datadir}/firstboot
%dir %{_datadir}/firstboot/modules
-%{_datadir}/firstboot/modules/*
-%{_desktopdir}/system-config-keyboard.desktop
-%{_iconsdir}/hicolor/48x48/apps/system-config-keyboard.png
+%{_datadir}/firstboot/modules/*.py
+
+# python-%{name}
+%dir %{py_sitescriptdir}/system_config_keyboard
+%{py_sitescriptdir}/system_config_keyboard/*.py[co]
%define date %(echo `LC_ALL="C" date +"%a %b %d %Y"`)
%changelog
@@ -89,6 +100,9 @@
All persons listed below can be reached at <cvs_login>@pld-linux.org
$Log$
+Revision 1.18 2012/03/03 15:15:31 glen
+- up to 1.3.1
+
Revision 1.17 2011/02/04 18:24:04 wiget
- Requires(post,postun): gtk-update-icon-cache
================================================================
Index: packages/system-config-keyboard/s-c-keyboard-do_not_remove_the_OK_button.patch
diff -u /dev/null packages/system-config-keyboard/s-c-keyboard-do_not_remove_the_OK_button.patch:1.1
--- /dev/null Sat Mar 3 16:15:37 2012
+++ packages/system-config-keyboard/s-c-keyboard-do_not_remove_the_OK_button.patch Sat Mar 3 16:15:31 2012
@@ -0,0 +1,20 @@
+do not remove the OK button
+
+There's no hsep. The ugly hack removed the necessary OK button.
+
+Index: system-config-keyboard-1.3.1/src/keyboard_gui.py
+===================================================================
+--- system-config-keyboard-1.3.1.orig/src/keyboard_gui.py
++++ system-config-keyboard-1.3.1/src/keyboard_gui.py
+@@ -254,10 +254,6 @@ class moduleClass(Module):
+ okButton = self.mainWindow.add_button('gtk-ok', 0)
+ okButton.connect("clicked", self._okClicked)
+
+- # Remove the hsep from the dialog. It's ugly.
+- hsep = self.mainWindow.get_children()[0].get_children()[0]
+- self.mainWindow.get_children()[0].remove(hsep)
+-
+ self.mainWindow.vbox.pack_start(self.vbox)
+ self.mainWindow.show_all()
+
+
================================================================
Index: packages/system-config-keyboard/sck-1.3.1-no-pyxf86config.patch
diff -u /dev/null packages/system-config-keyboard/sck-1.3.1-no-pyxf86config.patch:1.1
--- /dev/null Sat Mar 3 16:15:37 2012
+++ packages/system-config-keyboard/sck-1.3.1-no-pyxf86config.patch Sat Mar 3 16:15:31 2012
@@ -0,0 +1,181 @@
+diff -up system-config-keyboard-1.3.1/src/keyboard_backend.py.jx system-config-keyboard-1.3.1/src/keyboard_backend.py
+--- system-config-keyboard-1.3.1/src/keyboard_backend.py.jx 2009-07-26 18:32:19.000000000 -0400
++++ system-config-keyboard-1.3.1/src/keyboard_backend.py 2011-12-01 15:54:28.235998250 -0500
+@@ -1,96 +0,0 @@
+-#
+-# keyboard_backend.py - backend code for keyboard configuration
+-#
+-# Copyright (C) 2002, 2003 Red Hat, Inc.
+-# Brent Fox <bfox at redhat.com>
+-#
+-# Copyright (C) 2008 Lubomir Kundrak <lkundrak at redhat.com>
+-#
+-# This program is free software; you can redistribute it and/or modify
+-# it under the terms of the GNU General Public License as published by
+-# the Free Software Foundation; either version 2 of the License, or
+-# (at your option) any later version.
+-#
+-# This program is distributed in the hope that it will be useful,
+-# but WITHOUT ANY WARRANTY; without even the implied warranty of
+-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+-# GNU General Public License for more details.
+-#
+-# You should have received a copy of the GNU General Public License
+-# along with this program; if not, write to the Free Software
+-# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+-#
+-
+-#!/usr/bin/python2.2
+-
+-import sys
+-import os
+-
+-class KeyboardBackend:
+-
+- def modifyXconfig(self, fullname, layout, model, variant, options):
+- #import xf86config and make the necessary changes
+- if os.access("/etc/X11/XF86Config", os.W_OK) or os.access("/etc/X11/xorg.conf", os.W_OK):
+- import xf86config
+- (xconfig, xconfigpath) = xf86config.readConfigFile()
+- try:
+- keyboard = xf86config.getCoreKeyboard(xconfig)
+- except:
+- xconfig.comment = "\n# This configuration file was broken by system-config-keyboard\n"
+- keyboard = xf86config.XF86ConfInput ();
+- keyboard.comment = "\n# Keyboard added by system-config-keyboard\n"
+- keyboard.identifier = "Keyboard0"
+- keyboard.driver = "kbd"
+- keyboard.options.insert (xf86config.XF86Option("XkbModel", "pc101"))
+- keyboard.options.insert (xf86config.XF86Option("XkbLayout", "us"))
+- xconfig.input.insert (keyboard)
+- if len(xconfig.layout) == 0:
+- xconfig.layout.insert(xf86config.XF86ConfLayout())
+-
+- xconfig.layout[0].inputs.insert (xf86config.XF86ConfInputref ("Keyboard0", "CoreKeyboard"));
+-
+- found = 0
+- for o in keyboard.options:
+- if o.name == "XkbLayout":
+- found = 1
+-
+- if not found:
+- #If there's not an XkbLayout option for some reason, create one
+- option = xf86config.XF86Option("XkbLayout")
+- keyboard.options.insert(option)
+-
+- found_variant = None
+- found_options = None
+- count = 0
+- for o in keyboard.options:
+- if o.name == "XkbModel":
+- o.val = model
+- if o.name == "XkbLayout":
+- o.val = layout
+- if o.name == "XkbVariant":
+- found_variant = 1
+- if variant == "":
+- #remove variant here
+- keyboard.options.remove(count)
+- o.val = variant
+-
+- if o.name == "XkbOptions":
+- found_options = 1
+- if options == "":
+- #remove option here
+- keyboard.options.remove(count)
+-
+- count = count + 1
+-
+- if variant != "" and found_variant == None:
+- #Need to create a XkbVariant entry
+- opt = xf86config.XF86Option("XkbVariant", variant)
+- keyboard.options.insert(opt)
+-
+- if options != "" and found_options == None:
+- #Need to create an XkbOptions entry
+- opt = xf86config.XF86Option("XkbOptions", options)
+- keyboard.options.insert(opt)
+-
+- xconfig.write(xconfigpath)
+-
+diff -up system-config-keyboard-1.3.1/src/keyboard_cli.py.jx system-config-keyboard-1.3.1/src/keyboard_cli.py
+--- system-config-keyboard-1.3.1/src/keyboard_cli.py.jx 2009-07-26 20:31:30.000000000 -0400
++++ system-config-keyboard-1.3.1/src/keyboard_cli.py 2011-12-01 15:53:29.390000097 -0500
+@@ -21,15 +21,12 @@
+
+ import sys
+ import string
+-import keyboard_backend
+ import system_config_keyboard.keyboard as keyboard
+ import gettext
+
+ _ = gettext.gettext
+ gettext.textdomain('system-config-keyboard')
+
+-keyboardBackend = keyboard_backend.KeyboardBackend()
+-
+ class childWindow:
+ def usage(self):
+ print _("""Usage: system-config-keyboard [--help] [--noui] [--text] [<keyboardtype>]
+@@ -67,7 +64,6 @@ class childWindow:
+ self.kbd.set(kbdtype)
+ self.kbd.write()
+ self.kbd.activate()
+- keyboardBackend.modifyXconfig(fullname, layout, model, variant, options)
+ else:
+ print (_("'%s' is an invalid keymap. Please run 'system-config-keyboard --help' "
+ "for a list of keymaps" % kbdtype))
+diff -up system-config-keyboard-1.3.1/src/keyboard_gui.py.jx system-config-keyboard-1.3.1/src/keyboard_gui.py
+--- system-config-keyboard-1.3.1/src/keyboard_gui.py.jx 2011-11-30 14:38:11.000000000 -0500
++++ system-config-keyboard-1.3.1/src/keyboard_gui.py 2011-12-01 15:54:01.257000089 -0500
+@@ -41,7 +41,6 @@ from firstboot.functions import *
+ from firstboot.module import *
+
+ sys.path.append('/usr/share/system-config-keyboard')
+-import keyboard_backend
+
+ _ = gettext.gettext
+ gettext.textdomain('system-config-keyboard')
+@@ -62,8 +61,6 @@ except:
+ except:
+ pass
+
+-keyboardBackend = keyboard_backend.KeyboardBackend()
+-
+ # hack around the fact that scroll-to in the installer acts wierd
+ def setupTreeViewFixupIdleHandler(view, store):
+ id = {}
+@@ -117,8 +114,6 @@ class moduleClass(Module):
+ # If the /etc/X11/XF86Config file exists, then change it's keyboard settings
+ fullname, layout, model, variant, options = self.kbdDict[self.kbd.get()]
+
+- keyboardBackend.modifyXconfig(fullname, layout, model, variant, options)
+-
+ try:
+ #If we're in reconfig mode, this will fail because there is no self.mainWindow
+ self.mainWindow.destroy()
+diff -up system-config-keyboard-1.3.1/src/keyboard_tui.py.jx system-config-keyboard-1.3.1/src/keyboard_tui.py
+--- system-config-keyboard-1.3.1/src/keyboard_tui.py.jx 2009-07-26 21:20:04.000000000 -0400
++++ system-config-keyboard-1.3.1/src/keyboard_tui.py 2011-12-01 15:53:58.874000023 -0500
+@@ -29,14 +29,11 @@
+
+ from snack import *
+ import gettext
+-import keyboard_backend
+ import system_config_keyboard.keyboard as keyboard
+
+ _ = gettext.gettext
+ gettext.textdomain('system-config-keyboard')
+
+-keyboardBackend = keyboard_backend.KeyboardBackend()
+-
+ class KeyboardWindow:
+ def __call__(self, screen):
+ self.kbd = keyboard.Keyboard()
+@@ -103,6 +100,5 @@ class childWindow:
+ kbd.write()
+ kbd.activate()
+ fullname, layout, model, variant, options = rc
+- keyboardBackend.modifyXconfig(fullname, layout, model, variant, options)
+ DONE = 1
+
================================================================
---- CVS-web:
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/system-config-keyboard/system-config-keyboard.spec?r1=1.17&r2=1.18&f=u
More information about the pld-cvs-commit
mailing list