Can't build ImageMagick 6.9.0-2

Post any defects you find in the released or beta versions of the ImageMagick software here. Include the ImageMagick version, OS, and any command-line required to reproduce the problem. Got a patch for a bug? Post it here.
Post Reply
lleche
Posts: 10
Joined: 2012-11-25T14:50:18-07:00
Authentication code: 6789

Can't build ImageMagick 6.9.0-2

Post by lleche »

Can't build ImageMagick 6.9.0-2. Could install 6.9.0-0 without problems on same configuration..

System: MacOSX 10.10.1 (14B25), with Xcode 6.1.1 (6A2008a).
Issue: error reported by 'make':

/bin/sh ./libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I. -I/usr/local/include -DMAGICKCORE_HDRI_ENABLE=1 -DMAGICKCORE_QUANTUM_DEPTH=16 -I/Volumes/Data/Users/Landry/Desktop/ImageMagick-6.9.0-2/magick -I/Volumes/Data/Users/Landry/Desktop/ImageMagick-6.9.0-2/wand -I/usr/X11/include -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/libxml2 -I/usr/local/Cellar/freetype/2.5.4/include/freetype2 -g -O2 -Wall -march=core2 -fexceptions -D_FORTIFY_SOURCE=0 -D_THREAD_SAFE -pthread -DMAGICKCORE_HDRI_ENABLE=1 -DMAGICKCORE_QUANTUM_DEPTH=16 -c -o coders/coders_palm_la-palm.lo `test -f 'coders/palm.c' || echo './'`coders/palm.c
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I. -I/usr/local/include -DMAGICKCORE_HDRI_ENABLE=1 -DMAGICKCORE_QUANTUM_DEPTH=16 -I/Volumes/Data/Users/Landry/Desktop/ImageMagick-6.9.0-2/magick -I/Volumes/Data/Users/Landry/Desktop/ImageMagick-6.9.0-2/wand -I/usr/X11/include -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/libxml2 -I/usr/local/Cellar/freetype/2.5.4/include/freetype2 -g -O2 -Wall -march=core2 -fexceptions -D_FORTIFY_SOURCE=0 -D_THREAD_SAFE -pthread -DMAGICKCORE_HDRI_ENABLE=1 -DMAGICKCORE_QUANTUM_DEPTH=16 -c coders/palm.c -fno-common -DPIC -o coders/.libs/coders_palm_la-palm.o
coders/palm.c:513:53: error: invalid operands to binary expression ('PixelPacket *' (aka 'struct _PixelPacket *')
and 'IndexPacket' (aka 'float'))
SetMagickPixelPacket(image,image->colormap+index,
~~~~~~~~~~~~~~~^~~~~~
1 error generated.
make[1]: *** [coders/coders_palm_la-palm.lo] Error 1
make: *** [all] Error 2

Configure options:
./configure CPPFLAGS='-I/usr/local/include' LDFLAGS='-L/usr/local/lib' --enable-delegate-build --enable-shared --enable-hdri --disable-static --disable-opencl --with-modules --with-perl=/Users/Landry/perl5/perlbrew/perls/stable/bin/perl --with-quantum-depth=16 --with-gslib --without-wmf --disable-silent-rules --disable-dependency-tracking --disable-openmp --with-gs-font-dir=/usr/local/share/ghostscript/fonts/ --with-lqr
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: Can't build ImageMagick 6.9.0-2

Post by magick »

We can reproduce the problem you posted and have a patch in ImageMagick 6.9.0-3 Beta, available by sometime tomorrow. Thanks.
kwm
Posts: 11
Joined: 2014-03-04T13:43:03-07:00
Authentication code: 6789

Re: Can't build ImageMagick 6.9.0-2

Post by kwm »

I couldn't reproduce the issue above or below but I had some helpfull users report this and submit the patch below.
CC coders/coders_yuv_la-yuv.lo
CC coders/coders_exr_la-exr.lo
coders/rle.c: In function 'ReadRLEImage':
coders/rle.c:459:24: error: array subscript is not an integer
*p=colormap[index];
^
coders/rle.c:470:28: error: array subscript is not an integer
*p=colormap[index];
^
Makefile:8055: recipe for target 'coders/coders_rle_la-rle.lo' failed
gmake[3]: *** [coders/coders_rle_la-rle.lo] Error 1
CC coders/coders_fpx_la-fpx.lo
gmake[3]: *** Waiting for unfinished jobs....
CC coders/coders_jbig_la-jbig.lo
Patch:

Code: Select all

--- coders/rle.c.orig   2015-01-01 21:02:49 UTC
+++ coders/rle.c
@@ -456,7 +456,7 @@ static Image *ReadRLEImage(const ImageIn
             if (IsValidColormapIndex(image,*p & mask,&index,exception) ==
                 MagickFalse)
               break;
-            *p=colormap[index];
+            *p=colormap[(ssize_t)index];
             p++;
           }
         else
@@ -467,7 +467,7 @@ static Image *ReadRLEImage(const ImageIn
                 if (IsValidColormapIndex(image,(size_t) (x*map_length+
                     (*p & mask)),&index,exception) == MagickFalse)
                   break;
-                *p=colormap[index];
+                *p=colormap[(ssize_t)index];
                 p++;
               }
         if ((i < (ssize_t) number_pixels) || (x < (ssize_t) number_planes))
Post Reply