Package: imagemagick
Version: 7:6.2.4.5.dfsg1-0.12
Severity: serious
Tags: patch
Justification: no longer builds from source

Recent libpng actived MMX optimisations on amd64, it seems, and a
previously uncompiled code snippet in coders/png.c is now alive. It's
example code from libpng's man page, but contains a few cut&paste errors
that break compiling. Patch for those is attached. Unfortunately,
imagemagick doesn't build on amd64 with these fixes, either because of
linker errors due to a missing symbol in libpng. For Debian's purposes,
it would also be sufficient to simply disable the #if block as a whole,
but I'd prefer libpng to be fixed.

Regards,

Daniel.

--- imagemagick-6.2.4.5.dfsg1.orig/coders/png.c
+++ imagemagick-6.2.4.5.dfsg1/coders/png.c
@@ -1704,7 +1704,7 @@
 #if defined(PNG_USE_PNGGCCRD) && defined(PNG_ASSEMBLER_CODE_SUPPORTED) \
 && (PNG_LIBPNG_VER >= 10200)
   /* Disable thread-unsafe features of pnggccrd */
-  if (png_access_version() >= 10200)
+  if (png_access_version_number() >= 10200)
   {
     png_uint_32 mmx_disable_mask=0;
     png_uint_32 asm_flags;
@@ -1713,8 +1713,8 @@
                         | PNG_ASM_FLAG_MMX_READ_FILTER_SUB   \
                         | PNG_ASM_FLAG_MMX_READ_FILTER_AVG   \
                         | PNG_ASM_FLAG_MMX_READ_FILTER_PAETH );
-    asm_flags=png_get_asm_flags(png_ptr);
-    png_set_asm_flags(png_ptr, asm_flags & ~mmx_disable_mask);
+    asm_flags=png_get_asm_flags(ping);
+    png_set_asm_flags(ping, asm_flags & ~mmx_disable_mask);
   }
 #endif
 

Reply via email to