public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Takao Fujiwara <tfujiwar@redhat.com>
To: git-commits@fedoraproject.org
Subject: [rpms/ibus] autotool: Fix i18n ibus-setup
Date: Sun, 31 May 2026 02:07:10 GMT [thread overview]
Message-ID: <178019323098.1.10640436895244444991.rpms-ibus-5d405d9f5c7c@fedoraproject.org> (raw)
A new commit has been pushed.
Repo : rpms/ibus
Branch : autotool
Commit : 5d405d9f5c7cb886e581d0947e7756993b4b48a5
Author : Takao Fujiwara <tfujiwar@redhat.com>
Date : 2019-04-24T15:11:42+09:00
Stats : +196/-1 in 2 file(s)
URL : https://src.fedoraproject.org/rpms/ibus/c/5d405d9f5c7cb886e581d0947e7756993b4b48a5?branch=autotool
Log:
Fix i18n ibus-setup
- Also provide ibus.its
---
diff --git a/ibus-HEAD.patch b/ibus-HEAD.patch
index d9e7791..10833dc 100644
--- a/ibus-HEAD.patch
+++ b/ibus-HEAD.patch
@@ -145,3 +145,191 @@ index 226dd7a8..795365f6 100644
--
2.20.1
+From 1cb5032e85d85f496e349236d1b74f17fb8db966 Mon Sep 17 00:00:00 2001
+From: fujiwarat <takao.fujiwara1@gmail.com>
+Date: Tue, 23 Apr 2019 15:40:45 +0900
+Subject: [PATCH] configure: Move ibus-setup from configure.ac to Makefile.am
+
+@localedir@ can be extracted to ${datarootdir}/locale and
+it needs datarootdir=/usr/share in case configure.ac is used
+and deleting the datarootdir line caused a regression.
+All variables can be extracted in Makefile.am with sed.
+---
+ configure.ac | 1 -
+ setup/Makefile.am | 13 +++++++++++--
+ 2 files changed, 11 insertions(+), 3 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 9518e808..7503f3e8 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -724,7 +724,6 @@ ibus/interface/Makefile
+ ui/Makefile
+ ui/gtk3/Makefile
+ setup/Makefile
+-setup/ibus-setup
+ bindings/Makefile
+ bindings/pygobject/Makefile
+ bindings/vala/Makefile
+diff --git a/setup/Makefile.am b/setup/Makefile.am
+index cb4dd8d1..34c8f136 100644
+--- a/setup/Makefile.am
++++ b/setup/Makefile.am
+@@ -3,8 +3,8 @@
+ # ibus - The Input Bus
+ #
+ # Copyright (c) 2007-2014 Peng Huang <shawn.p.huang@gmail.com>
+-# Copyright (c) 2015-2018 Takao Fujiwara <takao.fujiwara1@gmail.com>
+-# Copyright (c) 2007-2018 Red Hat, Inc.
++# Copyright (c) 2015-2019 Takao Fujiwara <takao.fujiwara1@gmail.com>
++# Copyright (c) 2007-2019 Red Hat, Inc.
+ #
+ # This library is free software; you can redistribute it and/or
+ # modify it under the terms of the GNU Lesser General Public
+@@ -40,6 +40,15 @@ ibussetup_DATA = \
+ bin_SCRIPTS = ibus-setup
+ ibussetupdir = $(pkgdatadir)/setup
+
++ibus-setup: ibus-setup.in
++ $(AM_V_GEN) sed -e "s|\@datarootdir\@|$(datarootdir)|g" \
++ -e "s|\@localedir\@|$(localedir)|g" \
++ -e "s|\@libexecdir\@|$(libexecdir)|g" \
++ -e "s|\@prefix\@|$(prefix)|g" \
++ -e "s|\@PYTHON\@|$(PYTHON)|g" \
++ $< > $@.tmp && \
++ mv $@.tmp $@
++
+ desktop_notrans_files = ibus-setup.desktop
+ desktop_DATA = org.freedesktop.IBus.Setup.desktop
+ desktopdir = $(datadir)/applications
+--
+2.20.1
+
+From 1c54fea645b2ec3a385d492e4ca30a70dbb87c3a Mon Sep 17 00:00:00 2001
+From: fujiwarat <takao.fujiwara1@gmail.com>
+Date: Tue, 23 Apr 2019 18:44:45 +0900
+Subject: [PATCH] data/its: Add ibus.its for IME's component files
+
+IBusEngineDesc has translatable strings in longname and
+description tags and they needs to be extracted by xgettext.
+
+After you install the ibus.[its|loc] to /usr/share/gettext/its,
+each engine's component file needs to renamed with
+'.inputMethod.xml' in the source directory suffix. E.g.
+Rename 'anthy.xml' to 'anthy.inputMethod.xml' and write the file
+path to the engine's POTFILES.in
+---
+ configure.ac | 1 +
+ data/Makefile.am | 3 ++-
+ data/its/Makefile.am | 29 +++++++++++++++++++++++++++++
+ data/its/ibus.its | 14 ++++++++++++++
+ data/its/ibus.loc | 7 +++++++
+ 5 files changed, 53 insertions(+), 1 deletion(-)
+ create mode 100644 data/its/Makefile.am
+ create mode 100644 data/its/ibus.its
+ create mode 100644 data/its/ibus.loc
+
+diff --git a/configure.ac b/configure.ac
+index 7503f3e8..b5a87b56 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -711,6 +711,7 @@ util/IMdkit/Makefile
+ data/Makefile
+ data/annotations/Makefile
+ data/icons/Makefile
++data/its/Makefile
+ data/keymaps/Makefile
+ data/dconf/Makefile
+ docs/Makefile
+diff --git a/data/Makefile.am b/data/Makefile.am
+index 2533f444..aa3ee466 100644
+--- a/data/Makefile.am
++++ b/data/Makefile.am
+@@ -3,7 +3,7 @@
+ # ibus - The Input Bus
+ #
+ # Copyright (c) 2007-2016 Peng Huang <shawn.p.huang@gmail.com>
+-# Copyright (c) 2007-2018 Red Hat, Inc.
++# Copyright (c) 2007-2019 Red Hat, Inc.
+ #
+ # This library is free software; you can redistribute it and/or
+ # modify it under the terms of the GNU Lesser General Public
+@@ -23,6 +23,7 @@
+ SUBDIRS = \
+ annotations \
+ icons \
++ its \
+ keymaps \
+ $(NULL)
+
+diff --git a/data/its/Makefile.am b/data/its/Makefile.am
+new file mode 100644
+index 00000000..07c8a96d
+--- /dev/null
++++ b/data/its/Makefile.am
+@@ -0,0 +1,29 @@
++# vim:set noet ts=4:
++#
++# ibus - The Input Bus
++#
++# Copyright (c) 2019 Takao Fujiwara <takao.fujiwara1@gmail.com>
++# Copyright (c) 2019 Red Hat, Inc.
++#
++# This library is free software; you can redistribute it and/or
++# modify it under the terms of the GNU Lesser General Public
++# License as published by the Free Software Foundation; either
++# version 2.1 of the License, or (at your option) any later version.
++#
++# This library 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
++# Lesser General Public License for more details.
++#
++# You should have received a copy of the GNU Lesser General Public
++# License along with this library; if not, write to the Free Software
++# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
++# USA
++
++itsdir = $(datadir)/gettext/its
++its_DATA = \
++ ibus.its \
++ ibus.loc \
++ $(NULL)
++
++-include $(top_srcdir)/git.mk
+diff --git a/data/its/ibus.its b/data/its/ibus.its
+new file mode 100644
+index 00000000..30d8d4e2
+--- /dev/null
++++ b/data/its/ibus.its
+@@ -0,0 +1,14 @@
++<?xml version="1.0"?>
++<its:rules xmlns:its="http://www.w3.org/2005/11/its"
++ version="2.0">
++ <its:translateRule selector="/component" translate="no"/>
++ <its:translateRule selector="/engines" translate="no"/>
++ <its:translateRule selector="//engine" translate="no"/>
++ <its:translateRule selector="//longname |
++ //description"
++ translate="yes"/>
++ <its:translateRule selector="//longname[@translatable = 'no']"
++ translate="no"/>
++ <its:translateRule selector="//description[@translatable = 'no']"
++ translate="no"/>
++</its:rules>
+diff --git a/data/its/ibus.loc b/data/its/ibus.loc
+new file mode 100644
+index 00000000..5a73798b
+--- /dev/null
++++ b/data/its/ibus.loc
+@@ -0,0 +1,7 @@
++<?xml version="1.0"?>
++<locatingRules>
++ <locatingRule name="IBusEngineDesc" pattern="*.inputMethod.xml">
++ <documentRule localName="engines" target="ibus.its"/>
++ <documentRule localName="component" target="ibus.its"/>
++ </locatingRule>
++</locatingRules>
+--
+2.20.1
+
diff --git a/ibus.spec b/ibus.spec
index 7e934d6..a38fac7 100644
--- a/ibus.spec
+++ b/ibus.spec
@@ -35,7 +35,7 @@
Name: ibus
Version: 1.5.20
-Release: 2%{?dist}
+Release: 3%{?dist}
Summary: Intelligent Input Bus for Linux OS
License: LGPLv2+
URL: https://github.com/ibus/%name/wiki
@@ -219,6 +219,8 @@ Summary: Development tools for ibus
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
Requires: dbus-devel
Requires: glib2-devel
+# for %%{_datadir}/gettext/its
+Requires: gettext
%description devel
The ibus-devel package contains the header files and developer
@@ -418,6 +420,7 @@ dconf update || :
%{_libdir}/lib*.so
%{_libdir}/pkgconfig/*
%{_includedir}/*
+%{_datadir}/gettext/its/ibus.*
%dir %{_datadir}/gir-1.0
%{_datadir}/gir-1.0/IBus*-1.0.gir
%dir %{_datadir}/vala
@@ -432,6 +435,10 @@ dconf update || :
%{_datadir}/gtk-doc/html/*
%changelog
+* Tue Apr 23 2019 Takao Fujiwara <tfujiwar@redhat.com> - 1.5.20-3
+- Fix i18n ibus-setup
+- Provide ibus.its
+
* Tue Apr 16 2019 Takao Fujiwara <tfujiwar@redhat.com> - 1.5.20-2
- Rebuilt for unicode-ucd- 12.0.0
reply other threads:[~2026-05-31 2:07 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=178019323098.1.10640436895244444991.rpms-ibus-5d405d9f5c7c@fedoraproject.org \
--to=tfujiwar@redhat.com \
--cc=git-commits@fedoraproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox