]> git.pld-linux.org Git - packages/emacs.git/commitdiff
- started update to 25.1
authorJan Rękorajski <baggins@pld-linux.org>
Sun, 25 Dec 2016 12:05:54 +0000 (13:05 +0100)
committerJan Rękorajski <baggins@pld-linux.org>
Sun, 25 Dec 2016 12:05:54 +0000 (13:05 +0100)
- imagemagick code still needs fixing (or disabling)

emacs-fontconfig.patch [deleted file]
emacs-giflib.patch [deleted file]
emacs.spec
imagemagick7.patch [new file with mode: 0644]

diff --git a/emacs-fontconfig.patch b/emacs-fontconfig.patch
deleted file mode 100644 (file)
index 59dec34..0000000
+++ /dev/null
@@ -1,10 +0,0 @@
---- emacs-24.3/configure.ac.orig       2013-03-05 08:24:59.000000000 +0000
-+++ emacs-24.3/configure.ac    2013-04-17 07:09:43.617571656 +0000
-@@ -2403,6 +2403,7 @@
- ### Start of font-backend (under X11) section.
- if test "${HAVE_X11}" = "yes"; then
-    PKG_CHECK_MODULES(FONTCONFIG, fontconfig >= 2.2.0, HAVE_FC=yes, HAVE_FC=no)
-+   PKG_CHECK_MODULES(FREETYPE, freetype2, HAVE_FREETYPE=yes, HAVE_FREETYPE=no)
-    ## Use -lXft if available, unless `--with-xft=no'.
-    HAVE_XFT=maybe
diff --git a/emacs-giflib.patch b/emacs-giflib.patch
deleted file mode 100644 (file)
index 88b19bc..0000000
+++ /dev/null
@@ -1,140 +0,0 @@
-diff --git a/configure.ac b/configure.ac
-index 53426b6..0f05d8e 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -3109,8 +3109,9 @@ elif test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no" \
-         || test "${HAVE_W32}" = "yes"; then
-   AC_CHECK_HEADER(gif_lib.h,
- # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
--# Earlier versions can crash Emacs.
--    [AC_CHECK_LIB(gif, EGifPutExtensionLast, HAVE_GIF=yes, HAVE_GIF=maybe)])
-+# Earlier versions can crash Emacs, but version 5.0 removes EGifPutExtensionLast.
-+    [AC_CHECK_LIB(gif, GifMakeMapObject, HAVE_GIF=yes,
-+        [AC_CHECK_LIB(gif, EGifPutExtensionLast, HAVE_GIF=yes, HAVE_GIF=maybe)])])
-   if test "$HAVE_GIF" = yes; then
-     LIBGIF=-lgif
-diff --git a/src/image.c b/src/image.c
-index e429830..c414f5b 100644
---- a/src/image.c
-+++ b/src/image.c
-@@ -7219,14 +7219,23 @@ gif_image_p (Lisp_Object object)
- #endif /* HAVE_NTGUI */
-+#ifndef GIFLIB_MAJOR
-+#define GIFLIB_MAJOR 0
-+#endif
- #ifdef WINDOWSNT
- /* GIF library details.  */
--DEF_IMGLIB_FN (int, DGifCloseFile, (GifFileType *));
- DEF_IMGLIB_FN (int, DGifSlurp, (GifFileType *));
-+#if GIFLIB_MAJOR < 5
-+DEF_IMGLIB_FN (int, DGifCloseFile, (GifFileType *));
- DEF_IMGLIB_FN (GifFileType *, DGifOpen, (void *, InputFunc));
- DEF_IMGLIB_FN (GifFileType *, DGifOpenFileName, (const char *));
-+#else
-+DEF_IMGLIB_FN (int, DGifCloseFile, (GifFileType *, int *));
-+DEF_IMGLIB_FN (GifFileType *, DGifOpen, (void *, InputFunc, int *));
-+DEF_IMGLIB_FN (GifFileType *, DGifOpenFileName, (const char *, int *));
-+#endif
- static bool
- init_gif_functions (void)
-@@ -7206,7 +7214,11 @@ gif_load (struct frame *f, struct image *img)
-       }
-       /* Open the GIF file.  */
-+#if GIFLIB_MAJOR < 5
-       gif = fn_DGifOpenFileName (SSDATA (file));
-+#else
-+      gif = fn_DGifOpenFileName (SSDATA (file), NULL);
-+#endif
-       if (gif == NULL)
-       {
-         image_error ("Cannot open `%s'", file, Qnil);
-@@ -7227,7 +7239,11 @@ gif_load (struct frame *f, struct image *img)
-       memsrc.len = SBYTES (specified_data);
-       memsrc.index = 0;
-+#if GIFLIB_MAJOR < 5
-       gif = fn_DGifOpen (&memsrc, gif_read_from_memory);
-+#else
-+      gif = fn_DGifOpen (&memsrc, gif_read_from_memory, NULL);
-+#endif
-       if (!gif)
-       {
-         image_error ("Cannot open memory source `%s'", img->spec, Qnil);
-@@ -7241,7 +7242,11 @@
-   if (!check_image_size (f, gif->SWidth, gif->SHeight))
-     {
-       image_error ("Invalid image size (see `max-image-size')", Qnil, Qnil);
-+#if GIFLIB_MAJOR < 5
-       fn_DGifCloseFile (gif);
-+#else
-+      fn_DGifCloseFile (gif, NULL);
-+#endif
-       return 0;
-     }
-@@ -7250,7 +7255,11 @@
-   if (rc == GIF_ERROR || gif->ImageCount <= 0)
-     {
-       image_error ("Error reading `%s'", img->spec, Qnil);
-+#if GIFLIB_MAJOR < 5
-       fn_DGifCloseFile (gif);
-+#else
-+      fn_DGifCloseFile (gif, NULL);
-+#endif
-       return 0;
-     }
-@@ -7262,7 +7271,11 @@
-       {
-       image_error ("Invalid image number `%s' in image `%s'",
-                    image_number, img->spec);
-+#if GIFLIB_MAJOR < 5
-       fn_DGifCloseFile (gif);
-+#else
-+      fn_DGifCloseFile (gif, NULL);
-+#endif
-       return 0;
-       }
-   }
-@@ -7280,14 +7293,22 @@
-   if (!check_image_size (f, width, height))
-     {
-       image_error ("Invalid image size (see `max-image-size')", Qnil, Qnil);
-+#if GIFLIB_MAJOR < 5
-       fn_DGifCloseFile (gif);
-+#else
-+      fn_DGifCloseFile (gif, NULL);
-+#endif
-       return 0;
-     }
-   /* Create the X image and pixmap.  */
-   if (!x_create_x_image_and_pixmap (f, width, height, 0, &ximg, &img->pixmap))
-     {
-+#if GIFLIB_MAJOR < 5
-       fn_DGifCloseFile (gif);
-+#else
-+      fn_DGifCloseFile (gif, NULL);
-+#endif
-       return 0;
-     }
-@@ -7463,7 +7484,11 @@
-                           Fcons (make_number (gif->ImageCount),
-                                  img->lisp_data));
-+#if GIFLIB_MAJOR < 5
-   fn_DGifCloseFile (gif);
-+#else
-+  fn_DGifCloseFile (gif, NULL);
-+#endif
-   /* Maybe fill in the background field while we have ximg handy. */
-   if (NILP (image_spec_value (img->spec, QCbackground, NULL)))
index 572e876f0b9aa256b1577325143ec0a545fafa62..2e06519bc49a9f594e153630409fff157afef6d9 100644 (file)
@@ -18,13 +18,13 @@ Summary(pl.UTF-8):  GNU Emacs - edytor tekstu dla systemu X Window
 Summary(pt_BR.UTF-8):  GNU Emacs
 Summary(tr.UTF-8):     GNU Emacs
 Name:          emacs
-%define        ver     24.3
+%define        ver     25.1
 Version:       %{ver}
-Release:       8
+Release:       0.1
 License:       GPL v3+
 Group:         Applications/Editors/Emacs
 Source0:       ftp://ftp.gnu.org/pub/gnu/emacs/%{name}-%{version}.tar.xz
-# Source0-md5: ea9ed000ca165280265aabb55b9afbd7
+# Source0-md5: 4f3d42fb22823a659e16bfa89078a74c
 Source1:       %{name}-dot%{name}
 Source2:       %{name}-site-start.el
 Source3:       %{name}.png
@@ -34,8 +34,7 @@ Source6:      %{name}-athena.desktop
 Source7:       %{name}-gtk.desktop
 Source8:       %{name}-motif.desktop
 Source9:       %{name}-nox.desktop
-Patch0:                %{name}-fontconfig.patch
-Patch1:                %{name}-giflib.patch
+Patch0:                imagemagick7.patch
 URL:           http://www.gnu.org/software/emacs/
 BuildRequires: autoconf
 BuildRequires: automake
@@ -371,7 +370,6 @@ exit 1
 
 %setup -q -n %{name}-%{ver}
 %patch0 -p1
-%patch1 -p1
 
 %build
 cp -f /usr/share/automake/config.* .
diff --git a/imagemagick7.patch b/imagemagick7.patch
new file mode 100644 (file)
index 0000000..3058401
--- /dev/null
@@ -0,0 +1,27 @@
+--- emacs-25.1/configure.ac~   2016-07-25 09:08:36.000000000 +0200
++++ emacs-25.1/configure.ac    2016-12-25 13:00:06.594562908 +0100
+@@ -2413,7 +2413,7 @@
+   if test "${with_imagemagick}" != "no"; then
+     ## 6.3.5 is the earliest version known to work; see Bug#17339.
+     ## 6.8.2 makes Emacs crash; see Bug#13867.
+-    IMAGEMAGICK_MODULE="Wand >= 6.3.5 Wand != 6.8.2"
++    IMAGEMAGICK_MODULE="MagickWand >= 6.3.5 MagickWand != 6.8.2"
+     EMACS_CHECK_MODULES([IMAGEMAGICK], [$IMAGEMAGICK_MODULE])
+     AC_SUBST(IMAGEMAGICK_CFLAGS)
+     AC_SUBST(IMAGEMAGICK_LIBS)
+--- emacs-24.3/src/image.c~    2016-12-25 12:47:48.000000000 +0100
++++ emacs-24.3/src/image.c     2016-12-25 12:52:35.931084598 +0100
+@@ -7618,11 +7618,11 @@
+ /* The GIF library also defines DrawRectangle, but its never used in Emacs.
+    Therefore rename the function so it doesn't collide with ImageMagick.  */
+ #define DrawRectangle DrawRectangleGif
+-#include <wand/MagickWand.h>
++#include <MagickWand/MagickWand.h>
+ /* ImageMagick 6.5.3 through 6.6.5 hid PixelGetMagickColor for some reason.
+    Emacs seems to work fine with the hidden version, so unhide it.  */
+-#include <magick/version.h>
++#include <MagickCore/version.h>
+ #if 0x653 <= MagickLibVersion && MagickLibVersion <= 0x665
+ extern WandExport void PixelGetMagickColor (const PixelWand *,
+                                           MagickPixelPacket *);
This page took 0.11798 seconds and 4 git commands to generate.