Ticket #54543: glib2-devel-genmarshal-review.patch

File glib2-devel-genmarshal-review.patch, 3.1 KB (added by Ionic (Mihai Moldovan), 7 years ago)
  • devel/glib2-devel/Portfile

    commit b09eec357efe9f5f6ff87ec294a9eaab8c1f0034
    Author: Mihai Moldovan <ionic@ionic.de>
    Date:   Sat Jul 29 09:46:04 2017 +0200
    
        devel/glib2-devel: fix linking errors for projects using C++ and glib-genmarshal.
        
        Fixes: https://trac.macports.org/ticket/54543.
    
    diff --git a/devel/glib2-devel/Portfile b/devel/glib2-devel/Portfile
    index c904ad4..7160a70 100644
    a b name glib2-devel 
    99conflicts                   glib2
    1010set my_name                 glib
    1111version                     2.53.4
     12revision                    1
    1213set branch                  [join [lrange [split ${version} .] 0 1] .]
    1314categories                  devel
    1415maintainers                 {ryandesign @ryandesign} openmaintainer
    checksums rmd160 e5fbb4461eddd12a4bdf6f660d5b68c6e15cd9e7 \ 
    3637# patch-configure-switch-for-gappinfo-impl-mp.diff: understand comments inline!
    3738#   => https://trac.macports.org/ticket/53911
    3839#   => https://bugzilla.gnome.org/show_bug.cgi?id=781548
     40# patch-gobject_glib-genmarshal.in-fix-CXX-projects.diff:
     41#   => https://trac.macports.org/ticket/54543
     42#   => https://bugzilla.gnome.org/show_bug.cgi?id=785554
    3943patchfiles                  patch-configure.diff \
    4044                            patch-glib-2.0.pc.in.diff \
    4145                            patch-glib-gmain.c.diff \
    patchfiles patch-configure.diff \ 
    4549                            patch-gio_gdbusprivate.c.diff \
    4650                            patch-get-launchd-dbus-session-address.diff \
    4751                            patch-gmodule-gmodule-dl.c.diff \
    48                             patch-configure-switch-for-gappinfo-impl-mp.diff
     52                            patch-configure-switch-for-gappinfo-impl-mp.diff \
     53                            patch-gobject_glib-genmarshal.in-fix-CXX-projects.diff
    4954
    5055depends_build               bin:xmllint:libxml2
    5156
  • new file devel/glib2-devel/files/patch-gobject_glib-genmarshal.in-fix-CXX-projects.diff

    diff --git a/devel/glib2-devel/files/patch-gobject_glib-genmarshal.in-fix-CXX-projects.diff b/devel/glib2-devel/files/patch-gobject_glib-genmarshal.in-fix-CXX-projects.diff
    new file mode 100644
    index 0000000..a3037a0
    - +  
     1--- gobject/glib-genmarshal.in.old      2017-07-17 16:21:48.000000000 +0200
     2+++ gobject/glib-genmarshal.in  2017-07-29 09:22:31.000000000 +0200
     3@@ -556,7 +556,7 @@ def generate_prototype(retval, params,
     4                        va_marshal=False):
     5     '''Generate a marshaller declaration with the given @visibility. If @va_marshal
     6     is True, the marshaller will use variadic arguments in place of a GValue array.'''
     7-    signature = []
     8+    signature = ['G_BEGIN_DECLS']
     9 
     10     if visibility == Visibility.INTERNAL:
     11         signature += ['G_GNUC_INTERNAL']
     12@@ -585,6 +585,8 @@ def generate_prototype(retval, params,
     13         signature += [indent('int       n_params,', level=width, fill=' ')]
     14         signature += [indent('GType    *param_types);', level=width, fill=' ')]
     15 
     16+    signature += ['G_END_DECLS']
     17+
     18     return signature
     19 
     20