[packages/gtkmathview] - added patches from Fedora/Debian (marshalling-functions-git7d938a,fix-ComputerModernShaper-git2102

qboosh qboosh at pld-linux.org
Mon Jun 5 18:16:36 CEST 2023


commit 30825bc3a3777284ce88ffe7f405bf6ac4000138
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Mon Jun 5 18:19:02 2023 +0200

    - added patches from Fedora/Debian (marshalling-functions-git7d938a,fix-ComputerModernShaper-git210206,lowercasegreek-gitb03152,t1lib-private,gcc6,gcc7,fix-cpp-headers)
    - added link patch to fix backend libs linking
    - release 11

 ...thview-fix-ComputerModernShaper-git210206.patch |  20 ++
 gtkmathview-fix-cpp-headers.patch                  |  46 +++++
 gtkmathview-gcc6.patch                             |  99 ++++++++++
 gtkmathview-gcc7.patch                             |  26 +++
 gtkmathview-link.patch                             |  44 +++++
 gtkmathview-lowercasegreek-gitb03152.patch         |  24 +++
 gtkmathview-marshalling-functions-git7d938a.patch  | 203 +++++++++++++++++++++
 gtkmathview-no_static_viewer.patch.with-missingLib |  76 ++++++++
 gtkmathview-t1lib-private.patch                    |  59 ++++++
 gtkmathview.spec                                   |  94 +++++++++-
 10 files changed, 681 insertions(+), 10 deletions(-)
---
diff --git a/gtkmathview.spec b/gtkmathview.spec
index 0aa8d36..4b0b10f 100644
--- a/gtkmathview.spec
+++ b/gtkmathview.spec
@@ -2,7 +2,7 @@ Summary:	A GTK+ viewer to view MathML documents
 Summary(pl.UTF-8):	Przeglądarka dokumentów MathML dla GTK+
 Name:		gtkmathview
 Version:	0.8.0
-Release:	10
+Release:	11
 License:	LGPL v3+
 Group:		X11/Applications/Graphics
 Source0:	http://helm.cs.unibo.it/mml-widget/sources/%{name}-%{version}.tar.gz
@@ -11,10 +11,19 @@ Patch0:		%{name}-no_static_viewer.patch
 Patch1:		%{name}-gcc.patch
 Patch2:		gcc44.patch
 Patch3:		gcc47.patch
+Patch4:		%{name}-marshalling-functions-git7d938a.patch
+Patch5:		%{name}-fix-ComputerModernShaper-git210206.patch
+Patch6:		%{name}-lowercasegreek-gitb03152.patch
+Patch7:		%{name}-t1lib-private.patch
+Patch8:		%{name}-gcc6.patch
+Patch9:		%{name}-gcc7.patch
+Patch10:	%{name}-fix-cpp-headers.patch
+Patch11:	%{name}-link.patch
 URL:		http://helm.cs.unibo.it/mml-widget/
 BuildRequires:	autoconf >= 2.50
 BuildRequires:	automake
 BuildRequires:	gdome2-cpp_smart-devel >= 0.1.8
+BuildRequires:	glib2-devel >= 1:2.2.1
 BuildRequires:	gtk+2-devel >= 1:2.10.0
 BuildRequires:	libstdc++-devel
 BuildRequires:	libtool >= 2:1.5
@@ -26,8 +35,6 @@ BuildRequires:	t1lib-x-devel >= 1.2
 Requires:	%{name}-libs = %{version}-%{release}
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
-%define		skip_post_check_so	libmathview_backend_gtk.so.%{version} libmathview_backend_svg.so.%{version} libmathview_backend_ps.so.%{version}
-
 %description
 GtkMathView is a GTK+ Widget for rendering MathML documents.
 
@@ -39,7 +46,9 @@ Summary:	A GTK+ Widget for rendering MathML documents
 Summary(pl.UTF-8):	Biblioteki GTK+ Widget do renderowania dokumentów MathML
 Group:		Development/Libraries
 Requires:	gdome2-cpp_smart >= 0.1.8
+Requires:	glib2 >= 1:2.2.1
 Requires:	gtk+2 >= 2:2.10.0
+Requires:	libxml2 >= 1:2.6.26
 
 %description libs
 GTK+ Widgets for rendering MathML documents.
@@ -53,6 +62,7 @@ Summary(pl.UTF-8):	Biblioteki GTK+ Widget do renderowania dokumentów MathML - p
 Group:		Development/Libraries
 Requires:	%{name}-libs = %{version}-%{release}
 Requires:	gdome2-cpp_smart-devel >= 0.1.8
+Requires:	glib2-devel >= 1:2.2.1
 Requires:	gtk+2-devel >= 2:2.10.0
 Requires:	libxml2-devel >= 1:2.6.26
 
@@ -80,6 +90,14 @@ Wersja statyczna bibliotek dla GTK+ do renderowania dokumentów MathML.
 %patch1 -p1
 %patch2 -p1
 %patch3 -p1
+%patch4 -p1
+%patch5 -p1
+%patch6 -p1
+%patch7 -p1
+%patch8 -p1
+%patch9 -p1
+%patch10 -p1
+%patch11 -p1
 
 # AM_BINRELOC missing, just ignore
 echo 'AC_DEFUN([AM_BINRELOC], [])' > acinclude.m4
@@ -102,6 +120,7 @@ rm -rf $RPM_BUILD_ROOT
 %{__make} install \
 	DESTDIR=$RPM_BUILD_ROOT
 
+# obsoleted by pkg-config
 %{__rm} $RPM_BUILD_ROOT%{_libdir}/lib*.la
 
 %clean
@@ -116,22 +135,77 @@ rm -rf $RPM_BUILD_ROOT
 %attr(755,root,root) %{_bindir}/mathmlps
 %attr(755,root,root) %{_bindir}/mathmlsvg
 %attr(755,root,root) %{_bindir}/mathmlviewer
-%{_mandir}/man1/math*.1*
+%{_mandir}/man1/mathmlviewer.1*
 %{_datadir}/%{name}
 
 %files libs
 %defattr(644,root,root,755)
-%attr(755,root,root) %{_libdir}/lib*.so.*.*.*
-%attr(755,root,root) %ghost %{_libdir}/lib*.so.?
+%attr(755,root,root) %{_libdir}/libgtkmathview_custom_reader.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libgtkmathview_custom_reader.so.0
+%attr(755,root,root) %{_libdir}/libgtkmathview_gmetadom.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libgtkmathview_gmetadom.so.0
+%attr(755,root,root) %{_libdir}/libgtkmathview_libxml2.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libgtkmathview_libxml2.so.0
+%attr(755,root,root) %{_libdir}/libgtkmathview_libxml2_reader.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libgtkmathview_libxml2_reader.so.0
+%attr(755,root,root) %{_libdir}/libmathview.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libmathview.so.0
+%attr(755,root,root) %{_libdir}/libmathview_backend_gtk.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libmathview_backend_gtk.so.0
+%attr(755,root,root) %{_libdir}/libmathview_backend_ps.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libmathview_backend_ps.so.0
+%attr(755,root,root) %{_libdir}/libmathview_backend_svg.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libmathview_backend_svg.so.0
+%attr(755,root,root) %{_libdir}/libmathview_frontend_custom_reader.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libmathview_frontend_custom_reader.so.0
+%attr(755,root,root) %{_libdir}/libmathview_frontend_gmetadom.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libmathview_frontend_gmetadom.so.0
+%attr(755,root,root) %{_libdir}/libmathview_frontend_libxml2.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libmathview_frontend_libxml2.so.0
+%attr(755,root,root) %{_libdir}/libmathview_frontend_libxml2_reader.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libmathview_frontend_libxml2_reader.so.0
 %dir %{_sysconfdir}/gtkmathview
 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/gtkmathview/gtkmathview.conf.xml
 
 %files devel
 %defattr(644,root,root,755)
-%attr(755,root,root) %{_libdir}/lib*.so
-%{_pkgconfigdir}/*.pc
-%{_includedir}/%{name}
+%attr(755,root,root) %{_libdir}/libgtkmathview_custom_reader.so
+%attr(755,root,root) %{_libdir}/libgtkmathview_gmetadom.so
+%attr(755,root,root) %{_libdir}/libgtkmathview_libxml2.so
+%attr(755,root,root) %{_libdir}/libgtkmathview_libxml2_reader.so
+%attr(755,root,root) %{_libdir}/libmathview.so
+%attr(755,root,root) %{_libdir}/libmathview_backend_gtk.so
+%attr(755,root,root) %{_libdir}/libmathview_backend_ps.so
+%attr(755,root,root) %{_libdir}/libmathview_backend_svg.so
+%attr(755,root,root) %{_libdir}/libmathview_frontend_custom_reader.so
+%attr(755,root,root) %{_libdir}/libmathview_frontend_gmetadom.so
+%attr(755,root,root) %{_libdir}/libmathview_frontend_libxml2.so
+%attr(755,root,root) %{_libdir}/libmathview_frontend_libxml2_reader.so
+%{_pkgconfigdir}/gtkmathview-custom-reader.pc
+%{_pkgconfigdir}/gtkmathview-gmetadom.pc
+%{_pkgconfigdir}/gtkmathview-libxml2.pc
+%{_pkgconfigdir}/gtkmathview-libxml2-reader.pc
+%{_pkgconfigdir}/mathview-backend-gtk.pc
+%{_pkgconfigdir}/mathview-backend-ps.pc
+%{_pkgconfigdir}/mathview-backend-svg.pc
+%{_pkgconfigdir}/mathview-core.pc
+%{_pkgconfigdir}/mathview-frontend-custom-reader.pc
+%{_pkgconfigdir}/mathview-frontend-gmetadom.pc
+%{_pkgconfigdir}/mathview-frontend-libxml2.pc
+%{_pkgconfigdir}/mathview-frontend-libxml2-reader.pc
+%{_includedir}/gtkmathview
 
 %files static
 %defattr(644,root,root,755)
-%{_libdir}/lib*.a
+%{_libdir}/libgtkmathview_custom_reader.a
+%{_libdir}/libgtkmathview_gmetadom.a
+%{_libdir}/libgtkmathview_libxml2.a
+%{_libdir}/libgtkmathview_libxml2_reader.a
+%{_libdir}/libmathview.a
+%{_libdir}/libmathview_backend_gtk.a
+%{_libdir}/libmathview_backend_ps.a
+%{_libdir}/libmathview_backend_svg.a
+%{_libdir}/libmathview_frontend_custom_reader.a
+%{_libdir}/libmathview_frontend_gmetadom.a
+%{_libdir}/libmathview_frontend_libxml2.a
+%{_libdir}/libmathview_frontend_libxml2_reader.a
diff --git a/gtkmathview-fix-ComputerModernShaper-git210206.patch b/gtkmathview-fix-ComputerModernShaper-git210206.patch
new file mode 100644
index 0000000..82be55d
--- /dev/null
+++ b/gtkmathview-fix-ComputerModernShaper-git210206.patch
@@ -0,0 +1,20 @@
+From 2102063ce75c41f8ba13370eb2ddf63a7d3ec86e Mon Sep 17 00:00:00 2001
+From: Luca Padovani <padovani at di.unito.it>
+Date: Fri, 14 May 2010 09:17:53 +0000
+Subject: 	modified:   src/backend/common/ComputerModernShaper.cc
+
+	applied patch by Andrew Stacey
+---
+diff --git a/src/backend/common/ComputerModernShaper.cc b/src/backend/common/ComputerModernShaper.cc
+index e44f36f..0372422 100644
+--- a/src/backend/common/ComputerModernShaper.cc
++++ b/src/backend/common/ComputerModernShaper.cc
+@@ -975,7 +975,7 @@ static ComputerModernShaper::PlainChar msbmMap[] =
+ static ComputerModernShaper::PlainChar32 msbmMap32[] =
+   {
+     { 0x1D538, 0x41 },  //double A
+-    { 0x1D538, 0x42 },  //double B
++    { 0x1D539, 0x42 },  //double B
+     { 0x1D53B, 0x44 },  //double D
+     { 0x1D53C, 0x45 },  //double E
+     { 0x1D53D, 0x46 },  //double F
diff --git a/gtkmathview-fix-cpp-headers.patch b/gtkmathview-fix-cpp-headers.patch
new file mode 100644
index 0000000..54f3681
--- /dev/null
+++ b/gtkmathview-fix-cpp-headers.patch
@@ -0,0 +1,46 @@
+Index: gtkmathview-0.8.0/src/widget/gtkmathview_common.h
+===================================================================
+--- gtkmathview-0.8.0.orig/src/widget/gtkmathview_common.h
++++ gtkmathview-0.8.0/src/widget/gtkmathview_common.h
+@@ -22,6 +22,17 @@
+ 
+ #include <gtk/gtkwidget.h>
+ 
++/* Include these outside the extern "c" bit */
++#if GTKMATHVIEW_USES_CUSTOM_READER
++#include "c_customXmlReader.h"
++#elif GTKMATHVIEW_USES_LIBXML2_READER
++#include <libxml/xmlreader.h>
++#elif GTKMATHVIEW_USES_LIBXML2
++#include <libxml/tree.h>
++#elif GTKMATHVIEW_USES_GMETADOM
++#include <gdome.h>
++#endif
++
+ #ifdef __cplusplus
+ extern "C" {
+ #endif /* __cplusplus */
+@@ -45,23 +56,19 @@ extern "C" {
+   typedef void*                     GtkMathViewReaderData;
+ 
+ #if GTKMATHVIEW_USES_CUSTOM_READER
+-#include "c_customXmlReader.h"
+ #define GTKMATHVIEW_METHOD_NAME(name) gtk_math_view_##name##__##custom_reader
+   typedef void*                     GtkMathViewModelId;
+   typedef const char*               GtkMathViewModelString;
+ #elif GTKMATHVIEW_USES_LIBXML2_READER
+-#include <libxml/xmlreader.h>
+ #define GTKMATHVIEW_METHOD_NAME(name) gtk_math_view_##name##__##libxml2_reader
+   typedef void*                     GtkMathViewModelId;
+   typedef const xmlChar*            GtkMathViewModelString;
+ #elif GTKMATHVIEW_USES_LIBXML2
+-#include <libxml/tree.h>
+ #define GTKMATHVIEW_METHOD_NAME(name) gtk_math_view_##name##__##libxml2
+   typedef xmlElement*               GtkMathViewModelId;
+   typedef xmlDoc*                   GtkMathViewModelDocument;
+   typedef const xmlChar*            GtkMathViewModelString;
+ #elif GTKMATHVIEW_USES_GMETADOM
+-#include <gdome.h>
+ #define GTKMATHVIEW_METHOD_NAME(name) gtk_math_view_##name##__##gmetadom
+   typedef GdomeElement*             GtkMathViewModelId;
+   typedef GdomeDocument*            GtkMathViewModelDocument;
diff --git a/gtkmathview-gcc6.patch b/gtkmathview-gcc6.patch
new file mode 100644
index 0000000..7361f8e
--- /dev/null
+++ b/gtkmathview-gcc6.patch
@@ -0,0 +1,99 @@
+From: Gert Wollny <gw.fossdev at gmail.com>
+Date: Sun, 26 Jun 2016 13:25:00 +0200
+Description: gcc 6.0 build fixes
+Bug: https://bugs.debian.org/811682
+
+--- a/src/engine/common/View.cc
++++ b/src/engine/common/View.cc
+@@ -291,7 +291,7 @@
+ 	  }
+     }
+ 
+-  return false;
++  return SmartPtr<Element>();
+ }
+ 
+ bool
+--- a/src/backend/common/tfm/TFM.hh
++++ b/src/backend/common/tfm/TFM.hh
+@@ -37,7 +37,7 @@
+     unsigned char face;
+     const char* codingScheme;
+     int designSize;
+-    int checksum;
++    unsigned int checksum;
+     unsigned int nDimensions;
+     unsigned int nCharacters;
+   };
+@@ -52,7 +52,7 @@
+   struct Kerning
+   {
+     UChar8 index;
+-    int value;
++    unsigned int value;
+   };
+ 
+   struct Ligature
+@@ -67,7 +67,7 @@
+     UChar8 index;
+     int width;
+     int height;
+-    int depth;
++    unsigned int depth;
+     int italicCorrection;
+     unsigned char nKernings;
+     const Kerning* kerning;
+--- a/src/backend/common/ComputerModernShaper.cc
++++ b/src/backend/common/ComputerModernShaper.cc
+@@ -578,7 +578,7 @@
+   };
+ #endif
+ 
+-static ComputerModernShaper::PlainChar cmsMap[] =
++static ComputerModernShaper::PlainChar32 cmsMap[] =
+   {
+     { 0x007B, 0x66 },  // LEFT CURLY BRACKET
+     { 0x007D, 0x67 },  // RIGHT CURLY BRACKET
+--- a/src/backend/common/StandardSymbolsShaper.hh
++++ b/src/backend/common/StandardSymbolsShaper.hh
+@@ -32,20 +32,20 @@
+   struct HStretchyChar
+   {
+     Char16 ch;
+-    Char8 normal;
+-    Char8 left;
+-    Char8 glue;
+-    Char8 right;
++    UChar8 normal;
++    UChar8 left;
++    UChar8 glue;
++    UChar8 right;
+   };
+   
+   struct VStretchyChar
+   {
+     Char16 ch;
+-    Char8 normal;
+-    Char8 top;
+-    Char8 glue;
+-    Char8 middle;
+-    Char8 bottom;
++    UChar8 normal;
++    UChar8 top;
++    UChar8 glue;
++    UChar8 middle;
++    UChar8 bottom;
+   };
+ 
+ protected:
+--- a/src/backend/common/StandardSymbolsShaper.cc
++++ b/src/backend/common/StandardSymbolsShaper.cc
+@@ -29,7 +29,7 @@
+ #include "ShapingContext.hh"
+ 
+ struct GlyphMap {
+-  Char8 index;
++  UChar8 index;
+   Char16 ch;
+ };
+ 
diff --git a/gtkmathview-gcc7.patch b/gtkmathview-gcc7.patch
new file mode 100644
index 0000000..18340ba
--- /dev/null
+++ b/gtkmathview-gcc7.patch
@@ -0,0 +1,26 @@
+Description: Fix "call of overloaded 'abs(guint32)' is ambiguous"
+Author: Dmitry Marakasov <amdmi3 at FreeBSD.org>
+Origin: https://svnweb.freebsd.org/ports/head/x11-toolkits/gtkmathview/files/patch-src_widget_gtkmathview__common.cc?view=markup
+Bug-Debian: https://bugs.debian.org/853436
+Last-Update: 2017-12-19
+
+--- a/src/widget/gtkmathview_common.cc
++++ b/src/widget/gtkmathview_common.cc
+@@ -909,7 +909,7 @@
+ 	  math_view->select_state == SELECT_STATE_NO &&
+ 	  fabs(math_view->button_press_x - event->x) <= CLICK_SPACE_RANGE &&
+ 	  fabs(math_view->button_press_y - event->y) <= CLICK_SPACE_RANGE &&
+-	  abs(math_view->button_press_time - event->time) <= CLICK_TIME_RANGE)
++	  abs((long)math_view->button_press_time - (long)event->time) <= CLICK_TIME_RANGE)
+ 	{
+ 	  // the mouse should have not moved more than one pixel in each direction
+ 	  // and the time elapsed from the press event should be no more than 250ms
+@@ -969,7 +969,7 @@
+       (math_view->select_state == SELECT_STATE_YES ||
+        fabs(math_view->button_press_x - x) > CLICK_SPACE_RANGE ||
+        fabs(math_view->button_press_y - y) > CLICK_SPACE_RANGE ||
+-       abs(math_view->button_press_time - event->time) > CLICK_TIME_RANGE))
++       abs((long)math_view->button_press_time - (long)event->time) > CLICK_TIME_RANGE))
+     {
+       if (math_view->select_state == SELECT_STATE_NO)
+ 	{
diff --git a/gtkmathview-link.patch b/gtkmathview-link.patch
new file mode 100644
index 0000000..962cc5c
--- /dev/null
+++ b/gtkmathview-link.patch
@@ -0,0 +1,44 @@
+--- gtkmathview-0.8.0/src/Makefile.am.orig	2007-04-25 10:14:46.000000000 +0200
++++ gtkmathview-0.8.0/src/Makefile.am	2023-06-05 05:42:54.508676777 +0200
+@@ -7,7 +7,7 @@ else
+ MAYBE_GTK_SUBDIRS = $(NULL)
+ endif
+ 
+-SUBDIRS = common engine backend frontend . view $(MAYBE_GTK_SUBDIRS)
++SUBDIRS = common engine frontend backend/common . backend view $(MAYBE_GTK_SUBDIRS)
+ 
+ if COND_BOXML
+ MAYBE_BOXML_LIBADD = \
+--- gtkmathview-0.8.0/src/backend/gtk/Makefile.am.orig	2007-08-17 12:02:42.000000000 +0200
++++ gtkmathview-0.8.0/src/backend/gtk/Makefile.am	2023-06-04 22:07:40.703315022 +0200
+@@ -76,6 +76,7 @@ mathview_HEADERS = \
+ #   Gtk_XftGlyphArea.hh
+ 
+ libmathview_backend_gtk_la_LIBADD = \
++  $(top_builddir)/src/libmathview.la \
+   $(PANGOX_LIBS) \
+   $(GTK_LIBS) \
+   $(T1_LIBS) \
+--- gtkmathview-0.8.0/src/backend/ps/Makefile.am.orig	2007-08-17 12:02:40.000000000 +0200
++++ gtkmathview-0.8.0/src/backend/ps/Makefile.am	2023-06-05 06:29:17.067018452 +0200
+@@ -35,6 +35,9 @@ endif
+ 
+ libmathview_backend_ps_la_CPPFLAGS = -DGMV_BackEnd_DLL
+ libmathview_backend_ps_la_LDFLAGS = -version-info @MATHVIEW_VERSION_INFO@
++libmathview_backend_ps_la_LIBADD = \
++  $(top_builddir)/src/libmathview.la \
++  $(T1_LIBS)
+ 
+ libmathview_backend_ps_la_SOURCES = \
+   PS_AreaFactory.hh \
+--- gtkmathview-0.8.0/src/backend/svg/Makefile.am.orig	2007-04-25 10:14:33.000000000 +0200
++++ gtkmathview-0.8.0/src/backend/svg/Makefile.am	2023-06-05 06:29:58.096465275 +0200
+@@ -30,6 +30,8 @@ endif
+ 
+ libmathview_backend_svg_la_CPPFLAGS = -DGMV_BackEnd_DLL
+ libmathview_backend_svg_la_LDFLAGS = -version-info @MATHVIEW_VERSION_INFO@
++libmathview_backend_svg_la_LIBADD = \
++  $(top_builddir)/src/libmathview.la
+ 
+ libmathview_backend_svg_la_SOURCES = \
+   SVG_AreaFactory.hh \
diff --git a/gtkmathview-lowercasegreek-gitb03152.patch b/gtkmathview-lowercasegreek-gitb03152.patch
new file mode 100644
index 0000000..bb8d34f
--- /dev/null
+++ b/gtkmathview-lowercasegreek-gitb03152.patch
@@ -0,0 +1,24 @@
+From b031525e2f07975654fb74c611a2b23933c9cbac Mon Sep 17 00:00:00 2001
+From: Luca Padovani <padovani at di.unito.it>
+Date: Thu, 24 Nov 2011 21:34:21 +0000
+Subject: + applied patch by Matthew Wiebe
+
+---
+diff --git a/src/backend/common/ComputerModernShaper.cc b/src/backend/common/ComputerModernShaper.cc
+index 0372422..5bc5c0a 100644
+--- a/src/backend/common/ComputerModernShaper.cc
++++ b/src/backend/common/ComputerModernShaper.cc
+@@ -1564,6 +1564,13 @@ ComputerModernShaper::registerShaper(const SmartPtr<ShaperManager>& sm, unsigned
+ {
+   assert(sm);
+ 
++  // make sure there are normal variant options for lower case greek letters
++  if (family->fontEnabled(ComputerModernFamily::FN_CMMI)) {
++    for (unsigned i = 0; cmmMap[i].ch; i++) {
++      sm->registerChar(cmmMap[i].ch, GlyphSpec(shaperId, makeFontId(ComputerModernFamily::FE_CMMI, NORMAL_VARIANT), cmmMap[i].index));
++    }
++  }
++
+   for (unsigned j = 0; j < sizeof(variantDesc) / sizeof(FontDesc); j++)
+     for (unsigned i = 0; cmrMap[i].ch; i++)
+       {
diff --git a/gtkmathview-marshalling-functions-git7d938a.patch b/gtkmathview-marshalling-functions-git7d938a.patch
new file mode 100644
index 0000000..3d4e5e4
--- /dev/null
+++ b/gtkmathview-marshalling-functions-git7d938a.patch
@@ -0,0 +1,203 @@
+From 7d938ac846ebc5947455e6e56260f72607319811 Mon Sep 17 00:00:00 2001
+From: Luca Padovani <luca at src.gnome.org>
+Date: Tue, 10 Jun 2008 16:17:42 +0000
+Subject: + applied patch by Ed Catmur for marshalling functions in recent GTK versions
+
+svn path=/trunk/; revision=1182
+---
+diff --git a/CONTRIBUTORS b/CONTRIBUTORS
+index a15c16b..d51c0ca 100644
+--- a/CONTRIBUTORS
++++ b/CONTRIBUTORS
+@@ -38,3 +38,5 @@ In no particular order:
+ * Nicola Rossi
+   PostScript backend and accents
+ 
++* Ed Catmur
++  patch for marshalling functions in new gtk
+diff --git a/configure.ac b/configure.ac
+index 96ea726..85d26b9 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -332,6 +332,9 @@ PKG_CHECK_MODULES(GLIB, [glib-2.0 >= 2.2.1],,[AC_MSG_ERROR(could not find GLIB)]
+ AC_SUBST(GLIB_CFLAGS)
+ AC_SUBST(GLIB_LIBS)
+ 
++GLIB_GENMARSHAL=`pkg-config --variable=glib_genmarshal glib-2.0`
++AC_SUBST(GLIB_GENMARSHAL)
++
+ have_gtk="no"
+ have_pango="no"
+ if test "$enable_gtk" = "auto" -o "$enable_gtk" = "yes"; then
+diff --git a/src/widget/Makefile.am b/src/widget/Makefile.am
+index 4135f0c..8222d78 100644
+--- a/src/widget/Makefile.am
++++ b/src/widget/Makefile.am
+@@ -68,10 +68,14 @@ libgtkmathview_libxml2_reader_la_LDFLAGS = -version-info @MATHVIEW_VERSION_INFO@
+ libgtkmathview_libxml2_la_LDFLAGS = -version-info @MATHVIEW_VERSION_INFO@
+ libgtkmathview_gmetadom_la_LDFLAGS = -version-info @MATHVIEW_VERSION_INFO@
+ 
+-libgtkmathview_custom_reader_la_SOURCES = gtkmathview_custom_reader.cc
+-libgtkmathview_libxml2_reader_la_SOURCES = gtkmathview_libxml2_reader.cc
+-libgtkmathview_libxml2_la_SOURCES = gtkmathview_libxml2.cc
+-libgtkmathview_gmetadom_la_SOURCES = gtkmathview_gmetadom.cc
++libgtkmathview_custom_reader_la_SOURCES = gtkmathview_custom_reader.cc \
++  gtkmathview_marshal.c
++libgtkmathview_libxml2_reader_la_SOURCES = gtkmathview_libxml2_reader.cc \
++  gtkmathview_marshal.c
++libgtkmathview_libxml2_la_SOURCES = gtkmathview_libxml2.cc \
++  gtkmathview_marshal.c
++libgtkmathview_gmetadom_la_SOURCES = gtkmathview_gmetadom.cc \
++  gtkmathview_marshal.c
+ 
+ libgtkmathview_custom_reader_la_CPPFLAGS = -DGMV_Widget_DLL
+ libgtkmathview_libxml2_reader_la_CPPFLAGS = -DGMV_Widget_DLL
+@@ -81,6 +85,7 @@ libgtkmathview_gmetadom_la_CPPFLAGS = -DGMV_Widget_DLL
+ EXTRA_DIST = \
+   gtkmathview_common.cc \
+   gtkmathview_decorators_common.cc \
++  marshal.list \
+   $(NULL)
+ 
+ gtkdir = $(includedir)/$(PACKAGE)/gtk
+@@ -94,6 +99,25 @@ gtk_HEADERS = \
+   gtkmathview_libxml2.h \
+   gtkmathview_gmetadom.h
+ 
++noinst_HEADERS = \
++  gtkmathview_marshal.h \
++  $(NULL)
++
++BUILT_SOURCES = \
++  gtkmathview_marshal.c \
++  gtkmathview_marshal.h \
++  $(NULL)
++
++CLEANFILES = \
++  $(BUILT_SOURCES) \
++  $(NULL)
++
++gtkmathview_marshal.h: marshal.list
++	$(GLIB_GENMARSHAL) --prefix=gtkmathview_marshal $< --header > $@
++
++gtkmathview_marshal.c: marshal.list
++	$(GLIB_GENMARSHAL) --prefix=gtkmathview_marshal $< --body > $@
++
+ INCLUDES = \
+   -I$(top_builddir)/auto \
+   -I$(top_srcdir)/auto \
+diff --git a/src/widget/gtkmathview_common.cc b/src/widget/gtkmathview_common.cc
+index 9e1d935..d8d8495 100644
+--- a/src/widget/gtkmathview_common.cc
++++ b/src/widget/gtkmathview_common.cc
+@@ -36,6 +36,8 @@
+ #include <gtk/gtkmain.h>
+ #include <gtk/gtksignal.h>
+ 
++#include "gtkmathview_marshal.h"
++
+ #include "gtkmathview_common.h"
+ #if GTKMATHVIEW_USES_CUSTOM_READER
+ #define GTK_MATH_VIEW_WIDGET_NAME "GtkMathView_Custom_Reader"
+@@ -512,7 +514,7 @@ gtk_math_view_class_init(GtkMathViewClass* math_view_class)
+ 		 G_SIGNAL_RUN_LAST,
+ 		 G_STRUCT_OFFSET(GtkMathViewClass,set_scroll_adjustments),
+ 		 NULL, NULL,
+-		 gtk_marshal_NONE__POINTER_POINTER,
++		 gtkmathview_marshal_VOID__POINTER_POINTER,
+ 		 G_TYPE_NONE , 2, GTK_TYPE_ADJUSTMENT, GTK_TYPE_ADJUSTMENT); 
+ 	
+   click_signal = 
+@@ -521,8 +523,8 @@ gtk_math_view_class_init(GtkMathViewClass* math_view_class)
+ 		 G_SIGNAL_RUN_FIRST,
+ 		 G_STRUCT_OFFSET(GtkMathViewClass, click),
+ 		 NULL, NULL,
+-		 gtk_marshal_NONE__POINTER,
+-		 G_TYPE_NONE, 1, GTK_TYPE_POINTER);
++		 g_cclosure_marshal_VOID__POINTER,
++		 G_TYPE_NONE, 1, G_TYPE_POINTER);
+ 
+   select_begin_signal=
+     g_signal_new("select_begin",
+@@ -530,8 +532,8 @@ gtk_math_view_class_init(GtkMathViewClass* math_view_class)
+ 		 G_SIGNAL_RUN_FIRST,
+ 		 G_STRUCT_OFFSET(GtkMathViewClass, select_begin),
+ 		 NULL, NULL,
+-		 gtk_marshal_NONE__POINTER,
+-		 G_TYPE_NONE, 1, GTK_TYPE_POINTER);
++		 g_cclosure_marshal_VOID__POINTER,
++		 G_TYPE_NONE, 1, G_TYPE_POINTER);
+ 	
+   select_over_signal = 
+     g_signal_new("select_over",
+@@ -539,8 +541,8 @@ gtk_math_view_class_init(GtkMathViewClass* math_view_class)
+ 		 G_SIGNAL_RUN_FIRST,
+ 		 G_STRUCT_OFFSET(GtkMathViewClass, select_over),
+ 		 NULL, NULL,
+-		 gtk_marshal_NONE__POINTER,
+-		 G_TYPE_NONE, 1, GTK_TYPE_POINTER);
++		 g_cclosure_marshal_VOID__POINTER,
++		 G_TYPE_NONE, 1, G_TYPE_POINTER);
+ 	
+   select_end_signal = 
+     g_signal_new("select_end",
+@@ -548,8 +550,8 @@ gtk_math_view_class_init(GtkMathViewClass* math_view_class)
+ 		 G_SIGNAL_RUN_FIRST,
+ 		 G_STRUCT_OFFSET(GtkMathViewClass, select_end),
+ 		 NULL, NULL,
+-		 gtk_marshal_NONE__POINTER,
+-		 G_TYPE_NONE, 1, GTK_TYPE_POINTER);
++		 g_cclosure_marshal_VOID__POINTER,
++		 G_TYPE_NONE, 1, G_TYPE_POINTER);
+ 	
+   select_abort_signal = 
+     g_signal_new("select_abort",
+@@ -557,7 +559,7 @@ gtk_math_view_class_init(GtkMathViewClass* math_view_class)
+ 		 G_SIGNAL_RUN_FIRST,
+ 		 G_STRUCT_OFFSET(GtkMathViewClass, select_abort),
+ 		 NULL, NULL,
+-		 gtk_marshal_NONE__NONE,
++		 g_cclosure_marshal_VOID__VOID,
+ 		 G_TYPE_NONE, 0);
+ 	
+   element_over_signal = 
+@@ -566,8 +568,8 @@ gtk_math_view_class_init(GtkMathViewClass* math_view_class)
+ 		 G_SIGNAL_RUN_FIRST,
+ 		 G_STRUCT_OFFSET(GtkMathViewClass, element_over),
+ 		 NULL, NULL,
+-		 gtk_marshal_NONE__POINTER,
+-		 G_TYPE_NONE, 1, GTK_TYPE_POINTER);
++		 g_cclosure_marshal_VOID__POINTER,
++		 G_TYPE_NONE, 1, G_TYPE_POINTER);
+ 
+   decorate_under_signal =
+     g_signal_new("decorate_under",
+@@ -575,8 +577,8 @@ gtk_math_view_class_init(GtkMathViewClass* math_view_class)
+ 		 G_SIGNAL_RUN_FIRST,
+ 		 G_STRUCT_OFFSET(GtkMathViewClass, decorate_under),
+ 		 NULL, NULL,
+-		 gtk_marshal_NONE__POINTER,
+-		 G_TYPE_NONE, 1, GTK_TYPE_POINTER);
++		 g_cclosure_marshal_VOID__POINTER,
++		 G_TYPE_NONE, 1, G_TYPE_POINTER);
+ 
+   decorate_over_signal =
+     g_signal_new("decorate_over",
+@@ -584,8 +586,8 @@ gtk_math_view_class_init(GtkMathViewClass* math_view_class)
+ 		 G_SIGNAL_RUN_FIRST,
+ 		 G_STRUCT_OFFSET(GtkMathViewClass, decorate_over),
+ 		 NULL, NULL, 
+-		 gtk_marshal_NONE__POINTER,
+-		 G_TYPE_NONE, 1, GTK_TYPE_POINTER);
++		 g_cclosure_marshal_VOID__POINTER,
++		 G_TYPE_NONE, 1, G_TYPE_POINTER);
+ 
+ #if 0	
+   g_object_class_install_property(gobject_class,
+diff --git a/src/widget/marshal.list b/src/widget/marshal.list
+new file mode 100644
+index 0000000..cd48853
+--- a/dev/null
++++ b/src/widget/marshal.list
+@@ -0,0 +1 @@
++VOID:POINTER,POINTER
diff --git a/gtkmathview-no_static_viewer.patch.with-missingLib b/gtkmathview-no_static_viewer.patch.with-missingLib
new file mode 100644
index 0000000..24e970d
--- /dev/null
+++ b/gtkmathview-no_static_viewer.patch.with-missingLib
@@ -0,0 +1,76 @@
+--- gtkmathview-0.8.0/viewer/Makefile.am.orig	2023-06-04 21:18:18.549362387 +0200
++++ gtkmathview-0.8.0/viewer/Makefile.am	2023-06-04 21:31:54.008278000 +0200
+@@ -8,9 +8,6 @@ endif
+ 
+ noinst_PROGRAMS = $(NULL)
+ if COND_GMETADOM
+-if COND_PROFILE
+-noinst_PROGRAMS += mathmlviewer.static
+-endif
+ endif
+ if COND_LIBXML2
+ noinst_PROGRAMS += test_embedding
+@@ -24,18 +21,6 @@ endif
+ 
+ noinst_HEADERS = guiGTK.h
+ 
+-mathmlviewer_static_SOURCES = main.cc aux.cc guiGTK.c
+-mathmlviewer_static_LDFLAGS = -no-install -static
+-mathmlviewer_static_LDADD = \
+-  $(POPT_LIBS) \
+-  $(DOM_LIBS) \
+-  $(GTK_LIBS) \
+-  $(top_builddir)/src/widget/libgtkmathview_gmetadom.la \
+-  $(top_builddir)/src/engine/boxml/libboxml.la \
+-  $(T1_LIBS) \
+-  $(T1_LIBS_X) \
+-  $(NULL)
+-
+ mathmlviewer_SOURCES = main.cc aux.cc guiGTK.c
+ mathmlviewer_LDADD = \
+   $(POPT_LIBS) \
+@@ -47,7 +32,7 @@ mathmlviewer_LDADD = \
+   $(NULL)
+ 
+ test_embedding_SOURCES = test_embedding.c dummy.cc
+-test_embedding_LDFLAGS = -no-install -static
++test_embedding_LDFLAGS = -no-install
+ test_embedding_LDADD = \
+   -lstdc++ \
+   $(XML_LIBS) \
+@@ -58,7 +43,7 @@ test_embedding_LDADD = \
+   $(NULL)
+ 
+ test_loading_SOURCES = test_loading.c dummy.cc
+-test_loading_LDFLASG = -no-install -static
++test_loading_LDFLASG = -no-install
+ test_loading_LDADD = \
+   -lstdc++ \
+   $(XML_LIBS) \
+@@ -69,7 +54,7 @@ test_loading_LDADD = \
+   $(NULL)
+ 
+ test_building_SOURCES = test_building.cc
+-test_building_LDFLASG = -no-install -static
++test_building_LDFLASG = -no-install
+ test_building_LDADD = \
+   -lstdc++ \
+   $(XML_LIBS) \
+@@ -80,7 +65,7 @@ test_building_LDADD = \
+   $(NULL)
+ 
+ test_rendering_SOURCES = test_rendering.cc
+-test_rendering_LDFLASG = -no-install -static
++test_rendering_LDFLASG = -no-install
+ test_rendering_LDADD = \
+   -lstdc++ \
+   $(XML_LIBS) \
+@@ -95,7 +80,7 @@ test_rendering_LDADD = \
+   $(NULL)
+ 
+ test_loading_reader_SOURCES = test_loading_reader.c
+-test_loading_reader_LDFLASG = -no-install -static
++test_loading_reader_LDFLASG = -no-install
+ test_loading_reader_LDADD = \
+   -lstdc++ \
+   $(XML_LIBS) \
diff --git a/gtkmathview-t1lib-private.patch b/gtkmathview-t1lib-private.patch
new file mode 100644
index 0000000..b593275
--- /dev/null
+++ b/gtkmathview-t1lib-private.patch
@@ -0,0 +1,59 @@
+diff -up gtkmathview-0.8.0/gtkmathview-custom-reader.pc.in.jx gtkmathview-0.8.0/gtkmathview-custom-reader.pc.in
+--- gtkmathview-0.8.0/gtkmathview-custom-reader.pc.in.jx	2007-10-15 03:12:23.000000000 -0400
++++ gtkmathview-0.8.0/gtkmathview-custom-reader.pc.in	2014-05-28 11:31:56.651369768 -0400
+@@ -10,6 +10,7 @@ Name: GtkMathView
+ Description: A GTK+ Widget for Rendering MathML Documents (custom reader frontend)
+ Version: @VERSION@
+ Requires: glib-2.0 gtk+-2.0 mathview-core mathview-backend-gtk mathview-frontend-custom-reader
+-Libs: -L${libdir} -lgtkmathview_custom_reader @T1_LIBS@
++Libs: -L${libdir} -lgtkmathview_custom_reader
++Libs.private: @T1_LIBS@
+ Cflags: -I${includedir}/@PACKAGE@ @GMV_ENABLE_BOXML_CFLAGS@ @GMV_HAVE_HASH_MAP_CFLAGS@ @GMV_HAVE_EXT_HASH_MAP_CFLAGS@
+
+diff -up gtkmathview-0.8.0/gtkmathview-gmetadom.pc.in.jx gtkmathview-0.8.0/gtkmathview-gmetadom.pc.in
+--- gtkmathview-0.8.0/gtkmathview-gmetadom.pc.in.jx	2007-10-15 03:12:20.000000000 -0400
++++ gtkmathview-0.8.0/gtkmathview-gmetadom.pc.in	2014-05-28 11:31:57.906373249 -0400
+@@ -10,6 +10,7 @@ Name: GtkMathView
+ Description: A GTK+ Widget for Rendering MathML Documents (GMetaDOM frontend)
+ Version: @VERSION@
+ Requires: glib-2.0 gtk+-2.0 gdome2-cpp-smart mathview-core mathview-backend-gtk mathview-frontend-gmetadom
+-Libs: @DOM_LIBS@ -L${libdir} -lgtkmathview_gmetadom @T1_LIBS@
++Libs: @DOM_LIBS@ -L${libdir} -lgtkmathview_gmetadom
++Libs.private: @T1_LIBS@
+ Cflags: @DOM_CFLAGS@ -I${includedir}/@PACKAGE@ @GMV_ENABLE_BOXML_CFLAGS@ @GMV_HAVE_HASH_MAP_CFLAGS@ @GMV_HAVE_EXT_HASH_MAP_CFLAGS@
+
+diff -up gtkmathview-0.8.0/gtkmathview-libxml2.pc.in.jx gtkmathview-0.8.0/gtkmathview-libxml2.pc.in
+--- gtkmathview-0.8.0/gtkmathview-libxml2.pc.in.jx	2007-10-15 03:12:29.000000000 -0400
++++ gtkmathview-0.8.0/gtkmathview-libxml2.pc.in	2014-05-28 11:31:57.908373235 -0400
+@@ -10,6 +10,7 @@ Name: GtkMathView
+ Description: A GTK+ Widget for Rendering MathML Documents (libxml2 frontend)
+ Version: @VERSION@
+ Requires: glib-2.0 gtk+-2.0 mathview-core mathview-backend-gtk mathview-frontend-libxml2
+-Libs: @XML_LIBS@ -L${libdir} -lgtkmathview_libxml2 @T1_LIBS@
++Libs: @XML_LIBS@ -L${libdir} -lgtkmathview_libxml2
++Libs.private: @T1_LIBS@
+ Cflags: @XML_CFLAGS@ -I${includedir}/@PACKAGE@ @GMV_ENABLE_BOXML_CFLAGS@ @GMV_HAVE_HASH_MAP_CFLAGS@ @GMV_HAVE_EXT_HASH_MAP_CFLAGS@
+
+diff -up gtkmathview-0.8.0/gtkmathview-libxml2-reader.pc.in.jx gtkmathview-0.8.0/gtkmathview-libxml2-reader.pc.in
+--- gtkmathview-0.8.0/gtkmathview-libxml2-reader.pc.in.jx	2007-10-15 03:12:26.000000000 -0400
++++ gtkmathview-0.8.0/gtkmathview-libxml2-reader.pc.in	2014-05-28 11:31:57.909373233 -0400
+@@ -10,6 +10,7 @@ Name: GtkMathView
+ Description: A GTK+ Widget for Rendering MathML Documents (libxml2 reader frontend)
+ Version: @VERSION@
+ Requires: glib-2.0 gtk+-2.0 mathview-core mathmlview-backend-gtk mathview-frontend-libxml2-reader
+-Libs: @XML_LIBS@ -L${libdir} -lgtkmathview_libxml2_reader @T1_LIBS@
++Libs: @XML_LIBS@ -L${libdir} -lgtkmathview_libxml2_reader
++Libs.private: @T1_LIBS@
+ Cflags: @XML_CFLAGS@ -I${includedir}/@PACKAGE@ @GMV_ENABLE_BOXML_CFLAGS@ @GMV_HAVE_HASH_MAP_CFLAGS@ @GMV_HAVE_EXT_HASH_MAP_CFLAGS@
+
+diff -up gtkmathview-0.8.0/mathview-core.pc.in.jx gtkmathview-0.8.0/mathview-core.pc.in
+--- gtkmathview-0.8.0/mathview-core.pc.in.jx	2007-10-15 03:12:17.000000000 -0400
++++ gtkmathview-0.8.0/mathview-core.pc.in	2014-05-28 11:31:57.912373215 -0400
+@@ -10,6 +10,7 @@ Name: MathView
+ Description: MathML rendering engine (core)
+ Version: @VERSION@
+ Requires: glib-2.0
+-Libs: -L${libdir} -lmathview @T1_LIBS@
++Libs: -L${libdir} -lmathview
++Libs.private: @T1_LIBS@
+ Cflags: -I${includedir}/@PACKAGE@ @GMV_ENABLE_BOXML_CFLAGS@ @GMV_HAVE_HASH_MAP_CFLAGS@ @GMV_HAVE_EXT_HASH_MAP_CFLAGS@
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/gtkmathview.git/commitdiff/30825bc3a3777284ce88ffe7f405bf6ac4000138



More information about the pld-cvs-commit mailing list