git: f38d0fdbea88 - main - chinese/ibus-pinyin: fix build with sqlite3 DQS option off

From: Robert Clausecker <fuz_at_FreeBSD.org>
Date: Wed, 22 Mar 2023 20:17:22 UTC
The branch main has been updated by fuz:

URL: https://cgit.FreeBSD.org/ports/commit/?id=f38d0fdbea8833b50db2f8830894390c958972e8

commit f38d0fdbea8833b50db2f8830894390c958972e8
Author:     Henry Hu <henry.hu.sh@gmail.com>
AuthorDate: 2023-03-21 18:13:22 +0000
Commit:     Robert Clausecker <fuz@FreeBSD.org>
CommitDate: 2023-03-22 20:15:30 +0000

    chinese/ibus-pinyin: fix build with sqlite3 DQS option off
    
    Also mention that ibus-libpinyin should be preferred.
    
    See also:       PR 270064
    PR:             270376
---
 chinese/ibus-pinyin/Makefile                             |  2 +-
 .../ibus-pinyin/files/patch-data_db_english_english.awk  | 16 ++++++++++++++++
 .../files/{patch-init-config => patch-src_PYConfig.cc}   |  4 +---
 chinese/ibus-pinyin/pkg-descr                            |  4 ++++
 4 files changed, 22 insertions(+), 4 deletions(-)

diff --git a/chinese/ibus-pinyin/Makefile b/chinese/ibus-pinyin/Makefile
index f701bb83d537..724d8093c612 100644
--- a/chinese/ibus-pinyin/Makefile
+++ b/chinese/ibus-pinyin/Makefile
@@ -1,6 +1,6 @@
 PORTNAME=	ibus-pinyin
 PORTVERSION=	1.5.0
-PORTREVISION=	9
+PORTREVISION=	10
 CATEGORIES=	chinese
 
 MAINTAINER=	henry.hu.sh@gmail.com
diff --git a/chinese/ibus-pinyin/files/patch-data_db_english_english.awk b/chinese/ibus-pinyin/files/patch-data_db_english_english.awk
new file mode 100644
index 000000000000..baca5af059e3
--- /dev/null
+++ b/chinese/ibus-pinyin/files/patch-data_db_english_english.awk
@@ -0,0 +1,16 @@
+--- data/db/english/english.awk.orig	2023-03-20 04:01:48 UTC
++++ data/db/english/english.awk
+@@ -16,10 +16,10 @@ BEGIN {
+ }
+ 
+     # Insert data into english table
+-    {   printf "INSERT INTO english (word, freq) VALUES (\"%s\", \"%f\");\n", $1, $2}
++    {   printf "INSERT INTO english (word, freq) VALUES (\'%s\', \'%f\');\n", $1, $2}
+ 
+     #quit sqlite3
+ END {
+     # Commit the transcation
+     print "COMMIT;"
+-}
+\ No newline at end of file
++}
diff --git a/chinese/ibus-pinyin/files/patch-init-config b/chinese/ibus-pinyin/files/patch-src_PYConfig.cc
similarity index 77%
rename from chinese/ibus-pinyin/files/patch-init-config
rename to chinese/ibus-pinyin/files/patch-src_PYConfig.cc
index 7e70422cb132..9df4ad6a73eb 100644
--- a/chinese/ibus-pinyin/files/patch-init-config
+++ b/chinese/ibus-pinyin/files/patch-src_PYConfig.cc
@@ -1,6 +1,4 @@
-diff --git a/src/PYConfig.cc b/src/PYConfig.cc
-index 7e24b2c..1ef0b99 100644
---- src/PYConfig.cc
+--- src/PYConfig.cc.orig	2012-12-19 15:30:43 UTC
 +++ src/PYConfig.cc
 @@ -114,6 +114,7 @@ Config::initDefaultValues (void)
      m_init_full_punct = TRUE;
diff --git a/chinese/ibus-pinyin/pkg-descr b/chinese/ibus-pinyin/pkg-descr
index aa438e9ed01a..0649ebfe14e1 100644
--- a/chinese/ibus-pinyin/pkg-descr
+++ b/chinese/ibus-pinyin/pkg-descr
@@ -1 +1,5 @@
 PinYin engine for IBus.
+
+This pinyin input method is deprecated; new users should switch to
+chinese/ibus-libpinyin, which is a contemporary implementation of pinyin input
+method.