[gtk-osx: 5/17] Patch gobject-introspection for no-libtool



commit bff6adc2151e77eee60299181120524aa644bc1c
Author: Philip Chimento <philip chimento gmail com>
Date:   Sat Jun 27 15:08:32 2015 -0700

    Patch gobject-introspection for no-libtool
    
    This patch fixes https://bugzilla.gnome.org/show_bug.cgi?id=625195
    Without it, g-ir-scanner's no-libtool flag doesn't work on OSX. Only
    webkit2gtk3 uses the no-libtool flag, so if you are building it on
    modulesets or modulesets-unstable you'll need to apply the patch to the
    git repository yourself.

 modulesets-stable/gtk-osx.modules                  |    2 +
 ...95-Fix-non-libtool-linker-flags-on-Darwin.patch |   42 ++++++++++++++++++++
 patches/patch status                               |    3 +
 3 files changed, 47 insertions(+), 0 deletions(-)
---
diff --git a/modulesets-stable/gtk-osx.modules b/modulesets-stable/gtk-osx.modules
index 52c3978..3e197e8 100644
--- a/modulesets-stable/gtk-osx.modules
+++ b/modulesets-stable/gtk-osx.modules
@@ -123,6 +123,8 @@
             version="1.44.0"
             hash="sha256:6f0c2c28aeaa37b5037acbf21558098c4f95029b666db755d3a12c2f1e1627ad">
       <patch file="http://git.gnome.org/browse/gtk-osx/plain/patches/girscanner-objc.patch"; strip="1"/>
+      <patch file="gobject-introspection-625195-Fix-non-libtool-linker-flags-on-Darwin.patch"
+             strip="1"/>
     </branch>
     <dependencies>
       <dep package="glib"/>
diff --git a/patches/gobject-introspection-625195-Fix-non-libtool-linker-flags-on-Darwin.patch 
b/patches/gobject-introspection-625195-Fix-non-libtool-linker-flags-on-Darwin.patch
new file mode 100644
index 0000000..68305a6
--- /dev/null
+++ b/patches/gobject-introspection-625195-Fix-non-libtool-linker-flags-on-Darwin.patch
@@ -0,0 +1,42 @@
+From dde05e26be153002c7e52cc8f410e2e7be123707 Mon Sep 17 00:00:00 2001
+From: Philip Chimento <philip chimento gmail com>
+Date: Wed, 29 Apr 2015 22:20:47 -0700
+Subject: [PATCH] Fix non-libtool linker flags on Darwin
+
+Darwin's linker doesn't like "-rpath=path"; instead pass "-rpath path".
+Additionally, there is no equivalent for "--no-as-needed" (it seems to do
+the right thing by default?)
+---
+ giscanner/ccompiler.py | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/giscanner/ccompiler.py b/giscanner/ccompiler.py
+index 1c66aac..25ef55c 100644
+--- a/giscanner/ccompiler.py
++++ b/giscanner/ccompiler.py
+@@ -69,11 +69,11 @@ class CCompiler(object):
+                 else:
+                     args.append(str.lower(ns) + '.lib')
+             else:
+-                args.append('-Wl,-rpath=.')
++                args.append('-Wl,-rpath,.')
+ 
+         # Ensure libraries are always linked as we are going to use ldd to work
+         # out their names later
+-        if not libtool and pkgconfig_msvc_flags == '':
++        if not libtool and pkgconfig_msvc_flags == '' and not sys.platform == 'darwin':
+             args.append('-Wl,--no-as-needed')
+ 
+         for library in libraries:
+@@ -96,7 +96,7 @@ class CCompiler(object):
+                         args.append('-rpath')
+                         args.append(library_path)
+                     else:
+-                        args.append('-Wl,-rpath=' + library_path)
++                        args.append('-Wl,-rpath,' + library_path)
+ 
+     def get_external_link_flags(self, args, libraries, pkgconfig_msvc_flags):
+         # An "external" link is where the library to be introspected
+-- 
+2.3.2 (Apple Git-55)
+
diff --git a/patches/patch status b/patches/patch status
index 89494ce..6cef8be 100644
--- a/patches/patch status      
+++ b/patches/patch status      
@@ -11,6 +11,9 @@ gobject-intro:  0001-scanner-split-CC-environment-variable.patch fixed, not
                released in stable.
                girscanner-objc.patch: Bug 626995, will likely never be
                committed.
+               gobject-introspection-625195-Fix-non-libtool-linker-flags-on-Darwin.patch:
+               https://bugzilla.gnome.org/show_bug.cgi?id=625195, required only
+               for --no-libtool, i.e. webkit2gtk3.
 
 gtk2:          0004-Bug-571582-GtkSelection-implementation-for-quartz.patch
                0006-Bug-658722-Drag-and-Drop-sometimes-stops-working.patch


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]