[input-pad] Fixed build errors.

Takao Fujiwara fujiwara at fedoraproject.org
Wed Apr 4 04:08:31 UTC 2012


commit e828e33a1613c990aee8817e976d6e09f189d881
Author: Takao Fujiwara <tfujiwar at redhat.com>
Date:   Wed Apr 4 13:01:14 2012 +0900

    Fixed build errors.

 input-pad-HEAD.patch |  110 ++++++++++++++++++++++++++++++++++++++++++++++++++
 input-pad.spec       |    9 +++-
 2 files changed, 116 insertions(+), 3 deletions(-)
---
diff --git a/input-pad-HEAD.patch b/input-pad-HEAD.patch
index 8b13789..c82e1b2 100644
--- a/input-pad-HEAD.patch
+++ b/input-pad-HEAD.patch
@@ -1 +1,111 @@
+From d168b5cbb3507a33acfca0c249073637f23e9b1b Mon Sep 17 00:00:00 2001
+From: Daiki Ueno <ueno at unixuser.org>
+Date: Mon, 2 Apr 2012 10:33:02 +0900
+Subject: [PATCH] Fix ABI breakage of eekboard 1.0.6.
+
+---
+ configure.ac        |    2 +-
+ input-pad/eek-gtk.c |   21 ++++++++++++++-------
+ 2 files changed, 15 insertions(+), 8 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 20f9e8d..7b8c10b 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -142,7 +142,7 @@ AC_MSG_RESULT($enable_eek)
+ if test x"$enable_eek" = xyes; then
+     dnl - check eek is available
+     PKG_CHECK_MODULES(EEK, [
+-        eek-gtk-0.90 eek-xkl-0.90
++        eek-gtk-0.90 >= 1.0.6, eek-xkl-0.90 >= 1.0.6
+ 	],, AC_MSG_ERROR([libeek not found]))
+     AM_CONDITIONAL(HAVE_EEK, true)
+ else
+diff --git a/input-pad/eek-gtk.c b/input-pad/eek-gtk.c
+index abe966f..86ad0a5 100644
+--- a/input-pad/eek-gtk.c
++++ b/input-pad/eek-gtk.c
+@@ -27,6 +27,7 @@
+ #include <X11/keysym.h>
+ #include <eek/eek-gtk.h>
+ #include <eek/eek-xkl.h>
++#include <gdk/gdkx.h>
+ 
+ #include "eek-gtk.h"
+ #include "geometry-xkb.h"
+@@ -72,7 +73,7 @@ on_window_keyboard_changed_eek (InputPadGtkWindow *window,
+     g_return_if_fail (INPUT_PAD_IS_GTK_KBDUI_EEK (data));
+ 
+     kbdui = INPUT_PAD_GTK_KBDUI_EEK (data);
+-    eek_keyboard_set_group (kbdui->priv->eek_keyboard, group);
++    eek_element_set_group (EEK_ELEMENT(kbdui->priv->eek_keyboard), group);
+ }
+ 
+ static void
+@@ -81,7 +82,7 @@ on_eek_keyboard_key_pressed (EekKeyboard *keyboard,
+                              gpointer     user_data)
+ {
+     InputPadGtkWindow *window;
+-    char *str, *empty = "";
++    const gchar *str, *empty = "";
+     guint keycode;
+     EekSymbol *symbol;
+     EekSymbol *symbol0;
+@@ -102,7 +103,7 @@ on_eek_keyboard_key_pressed (EekKeyboard *keyboard,
+     str = eek_symbol_get_label (symbol);
+     if (str == NULL)
+         str = empty;
+-    group = eek_keyboard_get_group (keyboard);
++    group = eek_element_get_group (EEK_ELEMENT(keyboard));
+     symbol0 = eek_key_get_symbol_at_index (key, group, 0, 0, 0);
+     if (EEK_IS_KEYSYM(symbol0))
+         keysym0 = eek_keysym_get_xkeysym (EEK_KEYSYM(symbol0));
+@@ -119,8 +120,6 @@ on_eek_keyboard_key_pressed (EekKeyboard *keyboard,
+     g_signal_emit_by_name (window, "button-pressed",
+                    str, INPUT_PAD_TABLE_TYPE_KEYSYMS, keysym, keycode, state,
+                    &retval);
+-    if (str != empty)
+-        g_free (str);
+ 
+     if (keysym0 == XK_Num_Lock) {
+         keysym0 = XK_Shift_L;
+@@ -128,7 +127,7 @@ on_eek_keyboard_key_pressed (EekKeyboard *keyboard,
+     input_pad_gtk_window_set_keyboard_state_with_keysym (window, keysym0);
+     if (keysym0 == XK_Shift_L || keysym0 == XK_Shift_R) {
+         state = input_pad_gtk_window_get_keyboard_state (window);
+-        eek_keyboard_set_level (keyboard, state & ShiftMask ? 1 : 0);
++        eek_element_set_level (EEK_ELEMENT(keyboard), state & ShiftMask ? 1 : 0);
+     }
+ }
+ 
+@@ -142,11 +141,18 @@ create_keyboard_layout_ui_real_eek (InputPadGtkKbdui  *kbdui,
+     EekLayout *layout;
+     GtkWidget *widget;
+     gdouble width, height;
++    Display *xdisplay = GDK_WINDOW_XDISPLAY (gtk_widget_get_window (GTK_WIDGET (window)));
++    GError *error = NULL;
+ 
+     g_return_if_fail (INPUT_PAD_IS_GTK_KBDUI_EEK (kbdui));
+ 
+     kbdui_eek = INPUT_PAD_GTK_KBDUI_EEK (kbdui);
+-    layout = eek_xkl_layout_new ();
++    layout = eek_xkl_layout_new (xdisplay, &error);
++    if (layout == NULL) {
++        g_warning ("Can't get XKL layout: %s", error->message);
++        g_error_free (error);
++        return;
++    }
+ 
+     keyboard = kbdui_eek->priv->eek_keyboard = eek_keyboard_new (layout, 640, 480);
+     g_object_unref (layout);
+@@ -258,6 +264,7 @@ input_pad_module_arg_init_post (int                            *argc,
+ gboolean
+ input_pad_module_init (InputPadGtkWindow *window)
+ {
++    eek_init ();
+     return TRUE;
+ }
+ 
+-- 
+1.7.9.1
 
diff --git a/input-pad.spec b/input-pad.spec
index 5e2e75d..fab4be1 100644
--- a/input-pad.spec
+++ b/input-pad.spec
@@ -22,13 +22,13 @@
 
 Name:       input-pad
 Version:    1.0.1
-Release:    3%{?dist}
+Release:    4%{?dist}
 Summary:    On-screen Input Pad to Send Characters with Mouse
 License:    LGPLv2+
 Group:      System Environment/Libraries
 URL:        http://code.google.com/p/input-pad/
 Source0:    http://input-pad.googlecode.com/files/%{name}-%{version}.tar.gz
-# Patch0:     input-pad-HEAD.patch
+Patch0:     input-pad-HEAD.patch
 
 BuildRoot:  %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
@@ -100,7 +100,7 @@ The input-pad-eek package contains eekboard extension module
 
 %prep
 %setup -q
-# %patch0 -p1
+%patch0 -p1
 
 %build
 # for configure.ac patch
@@ -197,6 +197,9 @@ rm -rf $RPM_BUILD_ROOT
 %endif
 
 %changelog
+* Wed Apr 04 2012 Takao Fujiwara <tfujiwar at redhat.com> - 1.0.1-4
+- Added input-pad-HEAD.patch from upstream
+
 * Fri Jan 13 2012 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 1.0.1-3
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
 


More information about the scm-commits mailing list