ibus-anthy/ibus-anthy-HEAD.patch
Takao Fujiwara 14af61653e Update era.t with 2021
Check python3-pycotap.rpm in Fedora instead of pip
2021-10-22 09:25:22 +09:00

152 lines
4.9 KiB
Diff
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

From 50706f8e5fcf88f1a607ea1f977c4a8f2ebbf623 Mon Sep 17 00:00:00 2001
From: fujiwarat <takao.fujiwara1@gmail.com>
Date: Fri, 22 Oct 2021 00:22:09 +0900
Subject: [PATCH] data: Update era.t with 2021
---
data/Makefile.am | 9 +++++++++
data/era.t | 15 ++++++++++++++-
2 files changed, 23 insertions(+), 1 deletion(-)
diff --git a/data/Makefile.am b/data/Makefile.am
index 5e45c39..d76f17a 100644
--- a/data/Makefile.am
+++ b/data/Makefile.am
@@ -79,6 +79,15 @@ zipcode.t: $(ANTHY_ZIPCODE_FILE)
CLEANFILES += zipcode.t
endif
+check:
+ S_YEAR=`date '+%Y'`; \
+ M_YEAR=`echo $$S_YEAR | sed 'y/0123456789//'`; \
+ grep -q $$M_YEAR $(srcdir)/era.t; \
+ if test $$? -ne 0 ; then \
+ echo "This year $$M_YEAR is not included in era.y"; \
+ exit 1; \
+ fi;
+
install-data-hook:
if test -z "$(DESTDIR)"; then \
glib-compile-schemas $(schemasdir); \
diff --git a/data/era.t b/data/era.t
index 8d8cd32..a6d297e 100644
--- a/data/era.t
+++ b/data/era.t
@@ -2,7 +2,7 @@
#
# ibus-anthy - The Anthy engine for IBus
#
-# Copyright (c) 2010-2013 Takao Fujiwara <takao.fujiwara1@gmail.com>
+# Copyright (c) 2010-2021 Takao Fujiwara <takao.fujiwara1@gmail.com>
# Copyright (c) 2010-2013 Red Hat, Inc.
#
# This program is free software; you can redistribute it and/or modify
@@ -226,6 +226,10 @@
へいせい29 #T35*500 2017
へいせい3 #T35*500 平成3
へいせい3 #T35*500 1991
+へいせい30 #T35*500 平成30
+へいせい30 #T35*500 2018
+へいせい31 #T35*500 平成31
+へいせい31 #T35*500 2019
へいせい4 #T35*500 平成4
へいせい4 #T35*500 1992
へいせい5 #T35*500 平成5
@@ -328,6 +332,12 @@
めいじ8 #T35*500 1875
めいじ9 #T35*500 明治9
めいじ9 #T35*500 1876
+れいわ1 #T35*500 令和1
+れいわ1 #T35*500 2019
+れいわ2 #T35*500 令和2
+れいわ2 #T35*500 2020
+れいわ3 #T35*500 令和3
+れいわ3 #T35*500 2021
#T35*500 明治1
#T35*500 明治2
#T35*500 明治3
@@ -482,4 +492,7 @@
#T35*500 平成28
#T35*500 平成29
#T35*500 平成30
+ #T35*500 令和1
#T35*500 平成31
+ #T35*500 令和2
+ #T35*500 令和3
--
2.28.0
From 28aa550f728b3848b06a67579aca5f563e64d447 Mon Sep 17 00:00:00 2001
From: fujiwarat <takao.fujiwara1@gmail.com>
Date: Fri, 22 Oct 2021 00:22:41 +0900
Subject: [PATCH] tests: Check python3-pycotap.rpm in Fedora instead of pip
---
tests/Makefile.am | 7 +------
tests/test-build.sh | 17 ++++++++++++++++-
2 files changed, 17 insertions(+), 7 deletions(-)
diff --git a/tests/Makefile.am b/tests/Makefile.am
index d891ff2..a7a7108 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -2,7 +2,7 @@
#
# ibus-anthy - The Anthy engine for IBus
#
-# Copyright (c) 2017-2019 Takao Fujiwara <takao.fujiwara1@gmail.com>
+# Copyright (c) 2017-2021 Takao Fujiwara <takao.fujiwara1@gmail.com>
# Copyright (c) 2017-2019 Red Hat, Inc.
#
# This program is free software; you can redistribute it and/or modify
@@ -23,11 +23,6 @@
CLEANFILES =
check:
- @TAP_DIR=`python -m site --user-site`/tap; \
- if test x"$$TAP_DIR" != x -a ! -d "$$TAP_DIR" ; then \
- echo "pip install tap.py --user"; \
- pip install tap.py --user; \
- fi; \
bash -x $(srcdir)/test-build.sh --builddir=$(builddir) --srcdir=$(srcdir)
if ENABLE_INSTALLED_TESTS
diff --git a/tests/test-build.sh b/tests/test-build.sh
index 4c85af7..e83b78f 100755
--- a/tests/test-build.sh
+++ b/tests/test-build.sh
@@ -3,7 +3,7 @@
#
# ibus-anthy - The Anthy engine for IBus
#
-# Copyright (c) 2018 Takao Fujiwara <takao.fujiwara1@gmail.com>
+# Copyright (c) 2018-2021 Takao Fujiwara <takao.fujiwara1@gmail.com>
# Copyright (c) 2018 Red Hat, Inc.
#
# This program is free software; you can redistribute it and/or modify
@@ -68,6 +68,21 @@ init_environment()
if test x$FORCE_TEST != x ; then
RUN_ARGS="$RUN_ARGS --force";
fi;
+ HAS_TAP=0;
+ if test -f /etc/redhat-release ; then
+ rpm -q --quiet python3-pycotap
+ if test $? -ne 0 ; then
+ echo "Not found python3-pycotap";
+ exit -1;
+ fi;
+ HAS_TAP=1;
+ fi;
+ TAP_DIR=`python -m site --user-site`/pycotap;
+ if test $HAS_TAP -ne 1 && \
+ test x"$TAP_DIR" != x && test ! -d "$TAP_DIR" ; then
+ echo "pip install pycotap --user";
+ pip install pycotap --user;
+ fi;
if test ! -f $BUILDDIR/../data/$ANTHY_SCHEMA_FILE ; then
echo "Not found $BUILDDIR/../data/$ANTHY_SCHEMA_FILE";
exit -1;
--
2.28.0