summaryrefslogtreecommitdiff
path: root/app-i18n/tomoe/files
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
committerV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
commit8376ef56580626e9c0f796d5b85b53a0a1c7d5f5 (patch)
tree7681bbd4e8b05407772df40a4bf04cbbc8afc3fa /app-i18n/tomoe/files
parent30a9caf154332f12ca60756e1b75d2f0e3e1822d (diff)
gentoo resync : 14.07.2018
Diffstat (limited to 'app-i18n/tomoe/files')
-rw-r--r--app-i18n/tomoe/files/tomoe-export-symbols.patch240
-rw-r--r--app-i18n/tomoe/files/tomoe-gentoo.patch22
-rw-r--r--app-i18n/tomoe/files/tomoe-glib-2.32.patch33
-rw-r--r--app-i18n/tomoe/files/tomoe-ruby19.patch84
4 files changed, 379 insertions, 0 deletions
diff --git a/app-i18n/tomoe/files/tomoe-export-symbols.patch b/app-i18n/tomoe/files/tomoe-export-symbols.patch
new file mode 100644
index 000000000000..2b2d98b6ddd7
--- /dev/null
+++ b/app-i18n/tomoe/files/tomoe-export-symbols.patch
@@ -0,0 +1,240 @@
+Index: trunk/module/dict/tomoe-dict-xml.c
+===================================================================
+--- trunk/module/dict/tomoe-dict-xml.c (revision 1581)
++++ trunk/module/dict/tomoe-dict-xml.c (revision 1582)
+@@ -303,14 +303,14 @@
+ return success;
+
+ result.name = NULL;
+- result.chars = _tomoe_dict_ptr_array_get_array (TOMOE_DICT_PTR_ARRAY (dict));
+- success = _tomoe_xml_parser_parse_dictionary_file (dict->filename, &result);
++ result.chars = tomoe_dict_ptr_array_get_array (TOMOE_DICT_PTR_ARRAY (dict));
++ success = tomoe_xml_parser_parse_dictionary_file (dict->filename, &result);
+ if (result.name) {
+ g_free (dict->name);
+ dict->name = g_strdup (result.name);
+ g_free (result.name);
+ }
+- _tomoe_dict_ptr_array_sort (TOMOE_DICT_PTR_ARRAY (dict));
++ tomoe_dict_ptr_array_sort (TOMOE_DICT_PTR_ARRAY (dict));
+
+ return success;
+ }
+@@ -343,7 +343,7 @@
+ else
+ g_string_append (xml, "<dictionary>\n");
+
+- chars = _tomoe_dict_ptr_array_get_array (TOMOE_DICT_PTR_ARRAY (dict));
++ chars = tomoe_dict_ptr_array_get_array (TOMOE_DICT_PTR_ARRAY (dict));
+ for (i = 0; i < chars->len; i++) {
+ gchar *chr_xml;
+ TomoeChar *chr = g_ptr_array_index (chars, i);
+Index: trunk/module/dict/tomoe-dict-unihan.c
+===================================================================
+--- trunk/module/dict/tomoe-dict-unihan.c (revision 1581)
++++ trunk/module/dict/tomoe-dict-unihan.c (revision 1582)
+@@ -193,7 +193,7 @@
+ object = klass->constructor (type, n_props, props);
+ the_singleton = TOMOE_DICT_UNIHAN (object);
+
+- chars = _tomoe_dict_ptr_array_get_array (TOMOE_DICT_PTR_ARRAY (object));
++ chars = tomoe_dict_ptr_array_get_array (TOMOE_DICT_PTR_ARRAY (object));
+ _tomoe_unihan_create (chars);
+ } else {
+ object = g_object_ref (G_OBJECT (the_singleton));
+Index: trunk/lib/tomoe-char.c
+===================================================================
+--- trunk/lib/tomoe-char.c (revision 1581)
++++ trunk/lib/tomoe-char.c (revision 1582)
+@@ -143,7 +143,7 @@
+ TomoeChar*
+ tomoe_char_new_from_xml_data (const gchar *data, gssize len)
+ {
+- return _tomoe_xml_parser_parse_char_data (data, len);
++ return tomoe_xml_parser_parse_char_data (data, len);
+ }
+
+ static void
+Index: trunk/lib/tomoe-xml-parser.c
+===================================================================
+--- trunk/lib/tomoe-xml-parser.c (revision 1581)
++++ trunk/lib/tomoe-xml-parser.c (revision 1582)
+@@ -428,8 +428,8 @@
+ }
+
+ gboolean
+-_tomoe_xml_parser_parse_dictionary_file (const gchar *filename,
+- TomoeXMLParsedData *result)
++tomoe_xml_parser_parse_dictionary_file (const gchar *filename,
++ TomoeXMLParsedData *result)
+ {
+ GMarkupParseContext *context;
+ FILE *f;
+@@ -469,7 +469,7 @@
+ }
+
+ TomoeChar *
+-_tomoe_xml_parser_parse_char_data (const gchar *xml, gssize len)
++tomoe_xml_parser_parse_char_data (const gchar *xml, gssize len)
+ {
+ GMarkupParseContext *context;
+ TomoeXMLParsedData result;
+Index: trunk/lib/tomoe-xml-parser.h
+===================================================================
+--- trunk/lib/tomoe-xml-parser.h (revision 1581)
++++ trunk/lib/tomoe-xml-parser.h (revision 1582)
+@@ -37,10 +37,10 @@
+ GPtrArray *chars;
+ };
+
+-gboolean _tomoe_xml_parser_parse_dictionary_file (const gchar *filename,
+- TomoeXMLParsedData *result);
+-TomoeChar *_tomoe_xml_parser_parse_char_data (const gchar *xml,
+- gssize len);
++gboolean tomoe_xml_parser_parse_dictionary_file (const gchar *filename,
++ TomoeXMLParsedData *result);
++TomoeChar *tomoe_xml_parser_parse_char_data (const gchar *xml,
++ gssize len);
+
+
+ G_END_DECLS
+Index: trunk/lib/tomoe-dict-ptr-array.c
+===================================================================
+--- trunk/lib/tomoe-dict-ptr-array.c (revision 1581)
++++ trunk/lib/tomoe-dict-ptr-array.c (revision 1582)
+@@ -50,7 +50,7 @@
+
+ static TomoeDictClass *parent_class;
+
+-G_DEFINE_ABSTRACT_TYPE (TomoeDictPtrArray, _tomoe_dict_ptr_array, TOMOE_TYPE_DICT)
++G_DEFINE_ABSTRACT_TYPE (TomoeDictPtrArray, tomoe_dict_ptr_array, TOMOE_TYPE_DICT)
+
+ static void dispose (GObject *object);
+ static void set_property (GObject *object,
+@@ -75,7 +75,7 @@
+ static gchar *get_available_private_utf8 (TomoeDict *dict);
+
+ static void
+-_tomoe_dict_ptr_array_class_init (TomoeDictPtrArrayClass *klass)
++tomoe_dict_ptr_array_class_init (TomoeDictPtrArrayClass *klass)
+ {
+ GObjectClass *gobject_class;
+ TomoeDictClass *dict_class;
+@@ -123,7 +123,7 @@
+ }
+
+ static void
+-_tomoe_dict_ptr_array_init (TomoeDictPtrArray *dict)
++tomoe_dict_ptr_array_init (TomoeDictPtrArray *dict)
+ {
+ TomoeDictPtrArrayPrivate *priv = TOMOE_DICT_PTR_ARRAY_GET_PRIVATE (dict);
+ priv->chars = g_ptr_array_new();
+@@ -196,7 +196,7 @@
+ }
+
+ void
+-_tomoe_dict_ptr_array_sort (TomoeDictPtrArray *dict)
++tomoe_dict_ptr_array_sort (TomoeDictPtrArray *dict)
+ {
+ TomoeDictPtrArrayPrivate *priv;
+
+@@ -219,7 +219,7 @@
+
+ unregister_char (dict, tomoe_char_get_utf8 (chr));
+ g_ptr_array_add (priv->chars, g_object_ref (G_OBJECT (chr)));
+- _tomoe_dict_ptr_array_sort (TOMOE_DICT_PTR_ARRAY (dict));
++ tomoe_dict_ptr_array_sort (TOMOE_DICT_PTR_ARRAY (dict));
+
+ priv->modified = TRUE;
+
+@@ -449,7 +449,7 @@
+ g_ptr_array_add (*dest_chars, tomoe_char_dup (chr));
+ }
+
+-gboolean
++static gboolean
+ copy (TomoeDict *src_dict, TomoeDict *dest_dict)
+ {
+ TomoeDictPtrArrayPrivate *src_priv, *dest_priv;
+@@ -487,7 +487,7 @@
+ return TOMOE_DICT_PTR_ARRAY_GET_PRIVATE (dict)->editable;
+ }
+
+-gchar *
++static gchar *
+ get_available_private_utf8 (TomoeDict *dict)
+ {
+ TomoeDictPtrArrayPrivate *priv;
+@@ -523,7 +523,7 @@
+ }
+
+ GPtrArray *
+-_tomoe_dict_ptr_array_get_array (TomoeDictPtrArray *dict)
++tomoe_dict_ptr_array_get_array (TomoeDictPtrArray *dict)
+ {
+ g_return_val_if_fail (TOMOE_IS_DICT_PTR_ARRAY (dict), NULL);
+
+Index: trunk/lib/tomoe-dict-ptr-array.h
+===================================================================
+--- trunk/lib/tomoe-dict-ptr-array.h (revision 1581)
++++ trunk/lib/tomoe-dict-ptr-array.h (revision 1582)
+@@ -29,7 +29,7 @@
+
+ #include "tomoe-dict.h"
+
+-#define TOMOE_TYPE_DICT_PTR_ARRAY (_tomoe_dict_ptr_array_get_type ())
++#define TOMOE_TYPE_DICT_PTR_ARRAY (tomoe_dict_ptr_array_get_type ())
+ #define TOMOE_DICT_PTR_ARRAY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TOMOE_TYPE_DICT_PTR_ARRAY, TomoeDictPtrArray))
+ #define TOMOE_DICT_PTR_ARRAY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TOMOE_TYPE_DICT_PTR_ARRAY, TomoeDictPtrArrayClass))
+ #define TOMOE_IS_DICT_PTR_ARRAY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TOMOE_TYPE_DICT_PTR_ARRAY))
+@@ -49,9 +49,9 @@
+ TomoeDictClass parent_class;
+ };
+
+-GType _tomoe_dict_ptr_array_get_type (void) G_GNUC_CONST;
+-void _tomoe_dict_ptr_array_sort (TomoeDictPtrArray *dict);
+-GPtrArray *_tomoe_dict_ptr_array_get_array (TomoeDictPtrArray *dict);
++GType tomoe_dict_ptr_array_get_type (void) G_GNUC_CONST;
++void tomoe_dict_ptr_array_sort (TomoeDictPtrArray *dict);
++GPtrArray *tomoe_dict_ptr_array_get_array (TomoeDictPtrArray *dict);
+
+ G_END_DECLS
+
+Index: trunk/lib/Makefile.am
+===================================================================
+--- trunk/lib/Makefile.am (revision 1581)
++++ trunk/lib/Makefile.am (revision 1582)
+@@ -30,13 +30,15 @@
+ tomoe-context.h \
+ tomoe-config.h \
+ tomoe-dict.h \
++ tomoe-dict-ptr-array.h \
+ tomoe-module.h \
+ tomoe-module-impl.h \
+ tomoe-query.h \
+ tomoe-reading.h \
+ tomoe-recognizer.h \
+ tomoe-shelf.h \
+- tomoe-writing.h
++ tomoe-writing.h \
++ tomoe-xml-parser.h
+
+ enum_source_prefix = tomoe-enum-types
+
+@@ -103,15 +105,13 @@
+ tomoe-config.c \
+ tomoe-dict.c \
+ tomoe-dict-ptr-array.c \
+- tomoe-dict-ptr-array.h \
+ tomoe-module.c \
+ tomoe-query.c \
+ tomoe-reading.c \
+ tomoe-recognizer.c \
+ tomoe-shelf.c \
+ tomoe-writing.c \
+- tomoe-xml-parser.c \
+- tomoe-xml-parser.h
++ tomoe-xml-parser.c
+
+ libtomoe_la_LDFLAGS = \
+ -version-info $(LT_VERSION_INFO) \
diff --git a/app-i18n/tomoe/files/tomoe-gentoo.patch b/app-i18n/tomoe/files/tomoe-gentoo.patch
new file mode 100644
index 000000000000..92ed311a0a76
--- /dev/null
+++ b/app-i18n/tomoe/files/tomoe-gentoo.patch
@@ -0,0 +1,22 @@
+--- a/module/dict/Makefile.am
++++ b/module/dict/Makefile.am
+@@ -34,7 +34,7 @@
+
+ LIBADD = $(TOMOE_LIBS) \
+ $(top_builddir)/lib/libtomoe.la
+-LDFLAGS = \
++AM_LDFLAGS = \
+ -rpath $(dict_moduledir) -avoid-version -module \
+ -export-dynamic $(no_undefined) $(LIBTOOL_EXPORT_OPTIONS)
+
+--- a/module/recognizer/Makefile.am
++++ b/module/recognizer/Makefile.am
+@@ -23,7 +23,7 @@
+ AM_CPPFLAGS =
+ INCLUDES = $(TOMOE_CFLAGS)
+
+-LDFLAGS = \
++AM_LDFLAGS = \
+ -rpath $(recognizer_moduledir) -avoid-version -module \
+ -export-dynamic $(no_undefined) $(LIBTOOL_EXPORT_OPTIONS)
+
diff --git a/app-i18n/tomoe/files/tomoe-glib-2.32.patch b/app-i18n/tomoe/files/tomoe-glib-2.32.patch
new file mode 100644
index 000000000000..eb05ab8b8d50
--- /dev/null
+++ b/app-i18n/tomoe/files/tomoe-glib-2.32.patch
@@ -0,0 +1,33 @@
+--- a/lib/glib-compat-key-file.h
++++ b/lib/glib-compat-key-file.h
+@@ -51,7 +51,7 @@
+ #ifndef __G_KEY_FILE_H__
+ #define __G_KEY_FILE_H__
+
+-#include <glib/gerror.h>
++#include <glib.h>
+
+ G_BEGIN_DECLS
+
+--- a/lib/glib-utils.h
++++ b/lib/glib-utils.h
+@@ -28,7 +28,7 @@
+ #include "config.h"
+ #endif /* HAVE_CONFIG_H */
+
+-#include <glib/garray.h>
++#include <glib.h>
+ #include <glib/gi18n-lib.h>
+ #include "glib-compat-file-utilities.h"
+ #include "glib-compat-key-file.h"
+--- a/lib/tomoe.c
++++ b/lib/tomoe.c
+@@ -26,7 +26,7 @@
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <string.h>
+-#include <glib/garray.h>
++#include <glib.h>
+ #include "tomoe.h"
+
+ static gboolean initialized = FALSE;
diff --git a/app-i18n/tomoe/files/tomoe-ruby19.patch b/app-i18n/tomoe/files/tomoe-ruby19.patch
new file mode 100644
index 000000000000..bca6aa807f04
--- /dev/null
+++ b/app-i18n/tomoe/files/tomoe-ruby19.patch
@@ -0,0 +1,84 @@
+--- a/bindings/ruby/tomoe-rb-char.c
++++ b/bindings/ruby/tomoe-rb-char.c
+@@ -2,6 +2,10 @@
+
+ #define _SELF(obj) RVAL2TCHR(obj)
+
++#ifndef RSTRING_LEN
++# define RSTRING_LEN(s) (RSTRING(s)->len)
++#endif
++
+ static VALUE
+ tc_initialize(int argc, VALUE *argv, VALUE self)
+ {
+@@ -13,7 +17,7 @@
+ if (NIL_P(xml)) {
+ chr = tomoe_char_new();
+ } else {
+- chr = tomoe_char_new_from_xml_data(RVAL2CSTR(xml), RSTRING(xml)->len);
++ chr = tomoe_char_new_from_xml_data(RVAL2CSTR(xml), RSTRING_LEN(xml));
+ }
+
+ G_INITIALIZE(self, chr);
+--- a/macros/ruby.m4
++++ b/macros/ruby.m4
+@@ -28,13 +28,18 @@
+
+ changequote(<<, >>)
+ for var_name in archdir sitearchdir CFLAGS LIBRUBYARG libdir \
+- sitelibdir sitearchdir; do
+- rbconfig_tmp=`$rbconfig "print Config::CONFIG['$var_name']"`
++ sitelibdir rubyhdrdir rubyarchhdrdir; do
++ rbconfig_tmp=`$rbconfig "print RbConfig::CONFIG['$var_name']"`
+ eval "rbconfig_$var_name=\"$rbconfig_tmp\""
+ done
+ changequote([, ])
+
+- RUBY_CFLAGS="$RUBY_CFLAGS -I$rbconfig_archdir "
++ if test "x$rbconfig_rubyhdrdir" = "x"; then
++ RUBY_CFLAGS="$RUBY_CFLAGS -I$rbconfig_archdir "
++ else
++ RUBY_CFLAGS="$RUBY_CFLAGS -I$rbconfig_rubyhdrdir "
++ RUBY_CFLAGS="$RUBY_CFLAGS -I$rbconfig_rubyarchhdrdir "
++ fi
+ RUBY_CFLAGS="$RUBY_CFLAGS -I$rbconfig_sitearchdir "
+ RUBY_CFLAGS="$RUBY_CFLAGS $rbconfig_CFLAGS "
+ RUBY_LIBS="$rbconfig_LIBRUBYARG"
+--- a/module/dict/tomoe-dict-ruby.c
++++ b/module/dict/tomoe-dict-ruby.c
+@@ -52,6 +52,13 @@
+ #define TOMOE_IS_DICT_RUBY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TOMOE_TYPE_DICT_RUBY))
+ #define TOMOE_DICT_RUBY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), TOMOE_TYPE_DICT_RUBY, TomoeDictRubyClass))
+
++#ifndef RARRAY_LEN
++# define RARRAY_LEN(a) (RARRAY(a)->len)
++#endif
++#ifndef RARRAY_PTR
++# define RARRAY_PTR(a) (RARRAY(a)->ptr)
++#endif
++
+ enum {
+ PROP_0,
+ PROP_FILENAME,
+@@ -209,7 +216,7 @@
+ ruby_script (PACKAGE);
+ ruby_set_argv (1, argv);
+
+- if (RARRAY(rb_load_path)->len == 0) {
++ if (RARRAY_LEN(rb_load_path) == 0) {
+ ruby_init_loadpath ();
+ }
+ }
+@@ -405,10 +412,10 @@
+
+ rb_results = rb_funcall (dict->rb_dict, rb_intern ("search"),
+ 1, GOBJ2RVAL (query));
+- len = RARRAY (rb_results)->len;
++ len = RARRAY_LEN(rb_results);
+ for (i = len; i; i--) {
+ results = g_list_prepend (results,
+- RVAL2TCND (RARRAY (rb_results)->ptr[i]));
++ RVAL2TCND (RARRAY_PTR(rb_results)[i]));
+ }
+ return results;
+ }