[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] master 980836d 3/3: Check for MagickAutoOrientImage
From: |
Lars Ingebrigtsen |
Subject: |
[Emacs-diffs] master 980836d 3/3: Check for MagickAutoOrientImage |
Date: |
Thu, 11 Feb 2016 03:22:09 +0000 |
branch: master
commit 980836d80e2447d8922f0f6cf287a12a6c914e8b
Author: Lars Ingebrigtsen <address@hidden>
Commit: Lars Ingebrigtsen <address@hidden>
Check for MagickAutoOrientImage
* configure.ac: Check for MagickAutoOrientImage.
* src/image.c (imagemagick_load_image): Don't use
MagickAutoOrientImage unless it's available.
---
configure.ac | 2 +-
src/image.c | 2 ++
2 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/configure.ac b/configure.ac
index c3e2554..6834473 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2414,7 +2414,7 @@ if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" =
"yes" || test "${HAVE_W32}"
OLD_LIBS=$LIBS
CFLAGS="$CFLAGS $IMAGEMAGICK_CFLAGS"
LIBS="$IMAGEMAGICK_LIBS $LIBS"
- AC_CHECK_FUNCS(MagickExportImagePixels MagickMergeImageLayers)
+ AC_CHECK_FUNCS(MagickExportImagePixels MagickMergeImageLayers
MagickAutoOrientImage)
CFLAGS=$OLD_CFLAGS
LIBS=$OLD_LIBS
fi
diff --git a/src/image.c b/src/image.c
index e1b167d..f22394f 100644
--- a/src/image.c
+++ b/src/image.c
@@ -8560,6 +8560,7 @@ imagemagick_load_image (struct frame *f, struct image
*img,
return 0;
}
+#ifdef HAVE_MAGICKAUTOORIENTIMAGE
/* If no :rotation is explicitly specified, apply the automatic
rotation from EXIF. */
if (NILP (image_spec_value (img->spec, QCrotation, NULL)))
@@ -8569,6 +8570,7 @@ imagemagick_load_image (struct frame *f, struct image
*img,
DestroyMagickWand (image_wand);
return 0;
}
+#endif
if (ino < 0 || ino >= MagickGetNumberImages (image_wand))
{