[mingw-gtk3] Workaround knownfolders.h linker issue when using a recent mingw-w64 snapshot
Erik van Pienbroek
epienbro at fedoraproject.org
Fri Apr 5 11:27:28 UTC 2013
commit 82ccf489f4763e375805d848351ac3f8fda8e88b
Author: Erik van Pienbroek <epienbro at fedoraproject.org>
Date: Fri Apr 5 13:26:35 2013 +0200
Workaround knownfolders.h linker issue when using a recent mingw-w64 snapshot
As of mingw-w64 r5589 the header knownfolders.h was added
which contains definitions like FOLDERID_Windows
As these are also part of libuuid.a you'll get linker failures like:
/usr/i686-w64-mingw32/sys-root/mingw/lib/libuuid.a(lib32_libuuid_a-uuid.o):(.rdata+0x0):multiple definition of `FOLDERID_Windows'
win32/.libs/libgdk-win32.a(gdkdnd-win32.o):gdkdnd-win32.c:(.rdata+0x360):first defined here
Workaround this for now until mingw-w64 upstream has come up
with a statement whether this is expected behaviour and what
component should be fixed exactly
http://mingw-w64.svn.sourceforge.net/viewvc/mingw-w64?view=revision&revision=5589
gtk-dont-define-initguid.patch | 11 +++++++++++
mingw-gtk3.spec | 19 ++++++++++++++++++-
2 files changed, 29 insertions(+), 1 deletions(-)
---
diff --git a/gtk-dont-define-initguid.patch b/gtk-dont-define-initguid.patch
new file mode 100644
index 0000000..5f41a48
--- /dev/null
+++ b/gtk-dont-define-initguid.patch
@@ -0,0 +1,11 @@
+--- gdk/win32/gdkdnd-win32.c.orig 2013-04-04 21:15:55.689671748 +0200
++++ gdk/win32/gdkdnd-win32.c 2013-04-04 21:16:02.083782327 +0200
+@@ -70,8 +70,6 @@
+ *
+ */
+
+-#define INITGUID
+-
+ #include "gdkdnd.h"
+ #include "gdkproperty.h"
+ #include "gdkinternals.h"
diff --git a/mingw-gtk3.spec b/mingw-gtk3.spec
index 430de8c..ebfdff6 100644
--- a/mingw-gtk3.spec
+++ b/mingw-gtk3.spec
@@ -6,7 +6,7 @@
Name: mingw-gtk3
Version: 3.8.0
-Release: 1%{?dist}
+Release: 2%{?dist}
Summary: MinGW Windows GTK+ library
License: LGPLv2+
@@ -21,6 +21,19 @@ Source1: gtk.immodules
# https://bugzilla.gnome.org/show_bug.cgi?id=692638
Patch2: 0003-Don-t-use-AC_CANONICAL_TARGET.patch
+# As of mingw-w64 r5589 the header knownfolders.h was added
+# which contains definitions like FOLDERID_Windows
+# As these are also part of libuuid.a you'll get linker failures like:
+# /usr/i686-w64-mingw32/sys-root/mingw/lib/libuuid.a(lib32_libuuid_a-uuid.o):(.rdata+0x0): multiple definition of `FOLDERID_Windows'
+# win32/.libs/libgdk-win32.a(gdkdnd-win32.o):gdkdnd-win32.c:(.rdata+0x360): first defined here
+#
+# Workaround this for now until mingw-w64 upstream has come up
+# with a statement whether this is expected behaviour and what
+# component should be fixed exactly
+#
+# http://mingw-w64.svn.sourceforge.net/viewvc/mingw-w64?view=revision&revision=5589
+Patch3: gtk-dont-define-initguid.patch
+
BuildArch: noarch
BuildRequires: mingw32-filesystem >= 95
@@ -107,6 +120,7 @@ This package contains the MinGW Windows cross compiled GTK+ 3 library.
%prep
%setup -q -n gtk+-%{version}
%patch2 -p1
+%patch3 -p0
autoreconf -i --force
@@ -254,6 +268,9 @@ fi
%changelog
+* Fri Apr 5 2013 Erik van Pienbroek <epienbro at fedoraproject.org> - 3.8.0-2
+- Workaround knownfolders.h linker issue when using a recent mingw-w64 snapshot
+
* Tue Mar 26 2013 Erik van Pienbroek <epienbro at fedoraproject.org> - 3.8.0-1
- Update to 3.8.0
More information about the scm-commits
mailing list