]> git.pld-linux.org Git - packages/gnustep-gui.git/commitdiff
- fix building with ImageMagick 7 auto/th/gnustep-gui-0.24.0-8
authorJan Rękorajski <baggins@pld-linux.org>
Sun, 25 Dec 2016 17:42:27 +0000 (18:42 +0100)
committerJan Rękorajski <baggins@pld-linux.org>
Sun, 25 Dec 2016 17:42:27 +0000 (18:42 +0100)
- rel 8

gnustep-gui.spec
imagemagick7.patch [new file with mode: 0644]

index 2ccc7e317d959af4fd721f92ae22b2f089f6fe53..a1284b7b98c44661443c21b7e9e0a456fbdd5e1d 100644 (file)
@@ -9,7 +9,7 @@ Summary(pl.UTF-8):      Biblioteka GNUstep GUI
 Name:          gnustep-gui
 %define        ver     0.24
 Version:       %{ver}.0
-Release:       7
+Release:       8
 License:       LGPL v2+ (library), GPL v3+ (applications)
 Group:         Libraries
 Source0:       ftp://ftp.gnustep.org/pub/gnustep/core/%{name}-%{version}.tar.gz
@@ -17,6 +17,7 @@ Source0:      ftp://ftp.gnustep.org/pub/gnustep/core/%{name}-%{version}.tar.gz
 Patch0:                %{name}-nocompressdocs.patch
 Patch1:                %{name}-doc.patch
 Patch2:                %{name}-giflib.patch
+Patch3:                imagemagick7.patch
 URL:           http://www.gnustep.org/
 %{?with_magick:BuildRequires:  ImageMagick-devel}
 BuildRequires: aspell-devel
@@ -80,6 +81,7 @@ biblioteki GNUstep GUI.
 %patch0 -p1
 %patch1 -p1
 %patch2 -p1
+%patch3 -p1
 
 %build
 export GNUSTEP_MAKEFILES=%{_datadir}/GNUstep/Makefiles
diff --git a/imagemagick7.patch b/imagemagick7.patch
new file mode 100644 (file)
index 0000000..b77c79c
--- /dev/null
@@ -0,0 +1,40 @@
+diff -ur gnustep-gui-0.24.0/Source/GSImageMagickImageRep.m gnustep-gui-0.24.0-im7/Source/GSImageMagickImageRep.m
+--- gnustep-gui-0.24.0/Source/GSImageMagickImageRep.m  2011-07-13 05:34:38.000000000 +0200
++++ gnustep-gui-0.24.0-im7/Source/GSImageMagickImageRep.m      2016-12-25 18:35:02.879438129 +0100
+@@ -43,7 +43,7 @@
+ #if HAVE_IMAGEMAGICK
+-#include <magick/MagickCore.h>
++#include <MagickCore/MagickCore.h>
+ @implementation GSImageMagickImageRep 
+@@ -82,11 +82,11 @@
+       NSSize res;
+       if (image->units == PixelsPerCentimeterResolution)
+       {
+-        res = NSMakeSize(image->x_resolution * 2.54, image->y_resolution * 2.54);
++        res = NSMakeSize(image->resolution.x * 2.54, image->resolution.y * 2.54);
+       }
+       else
+       {
+-        res = NSMakeSize(image->x_resolution, image->y_resolution);
++        res = NSMakeSize(image->resolution.x, image->resolution.y);
+       }
+       if (res.width > 0 && res.height > 0)
+@@ -117,11 +117,12 @@
+   ExceptionInfo *exception = AcquireExceptionInfo();
+   ImageInfo *imageinfo = CloneImageInfo(NULL);
++  const ColorInfo *colorinfo = GetColorInfo("none", exception);
+   Image *images, *image;
+   
+   // Set the background color to transparent
+   // (otherwise SVG's are rendered against a white background by default)
+-  QueryColorDatabase("none", &imageinfo->background_color, exception);
++  imageinfo->background_color = colorinfo->color;
+   images = BlobToImage(imageinfo, [data bytes], [data length], exception);
This page took 0.139004 seconds and 4 git commands to generate.