Skip Menu |

This queue is for tickets about the PerlMagick CPAN distribution.

Report information
The Basics
Id: 113734
Status: open
Priority: 0/
Queue: PerlMagick

People
Owner: Nobody in particular
Requestors: kes-kes [...] yandex.ru
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: fatal error: magick/magick-baseconfig.h: No such file or directory
$ cpan Image::MagickLoading internal null logger. Install Log::Log4perl for logging messages Reading '/home/user/.cpan/Metadata' Database was generated on Tue, 12 Apr 2016 16:17:02 GMT Running install for module 'Image::Magick' Checksum for /home/user/.cpan/sources/authors/id/J/JC/JCRISTY/PerlMagick-6.89-1.tar.gz ok Configuring J/JC/JCRISTY/PerlMagick-6.89-1.tar.gz with Makefile.PL Checking if your kit is complete... Looks good Generating a Unix-style Makefile Writing Makefile for Image::Magick Writing MYMETA.yml and MYMETA.json JCRISTY/PerlMagick-6.89-1.tar.gz /usr/bin/perl Makefile.PL INSTALLDIRS=site -- OK Running make for J/JC/JCRISTY/PerlMagick-6.89-1.tar.gz cp Magick.pm blib/lib/Image/Magick.pm AutoSplitting blib/lib/Image/Magick.pm (blib/lib/auto/Image/Magick) Running Mkbootstrap for Image::Magick () chmod 644 "Magick.bs" "/usr/bin/perl" "/usr/share/perl/5.22/ExtUtils/xsubpp" -typemap "/usr/share/perl/5.22/ExtUtils/typemap" -typemap "typemap" Magick.xs > Magick.xsc && mv Magick.xsc Magick.c x86_64-linux-gnu-gcc -c -I/usr/local/include/ImageMagick-6 -DMAGICKCORE_HDRI_ENABLE=0 -DMAGICKCORE_QUANTUM_DEPTH=16 -I/usr/include/libxml2 -I"/usr/include/ImageMagick-6" -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fwrapv -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/freetype2 -g -O2 -Wall -pthread -DMAGICKCORE_HDRI_ENABLE=0 -DMAGICKCORE_QUANTUM_DEPTH=16 -O2 -g -DVERSION=\"6.89\" -DXS_VERSION=\"6.89\" -fPIC "-I/usr/lib/x86_64-linux-gnu/perl/5.22/CORE" -D_LARGE_FILES=1 -DHAVE_CONFIG_H Magick.c In file included from /usr/include/ImageMagick-6/magick/MagickCore.h:29:0, from Magick.xs:60: /usr/include/ImageMagick-6/magick/magick-config.h:21:38: fatal error: magick/magick-baseconfig.h: No such file or directory compilation terminated. Makefile:349: recipe for target 'Magick.o' failed make: *** [Magick.o] Error 1 JCRISTY/PerlMagick-6.89-1.tar.gz /usr/bin/make -- NOT OK user@ubuntu-1604-amd64-setupru:~/work/setup.ru/site/app/lib/SC/Site$ find /usr/include/x86_64-linux-gnu/ImageMagick-6/ /usr/include/x86_64-linux-gnu/ImageMagick-6/ /usr/include/x86_64-linux-gnu/ImageMagick-6/magick /usr/include/x86_64-linux-gnu/ImageMagick-6/magick/magick-baseconfig.h
From: jason [...] dickson.st
On Wed Apr 13 03:09:36 2016, KES wrote: Show quoted text
> 6/magick/MagickCore.h:29:0, > from Magick.xs:60: > /usr/include/ImageMagick-6/magick/magick-config.h:21:38: fatal error: > magick/magick-baseconfig.h: No such file or directory > compilation terminated.
Also reported as a debian bug: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=774951 Diff for a workaround included. Thanks to TonyC for help on that one.
Subject: workaround.diff
--- Makefile.PL 2014-09-22 07:23:03.000000000 +1000 +++ Makefile.PL.new 2016-07-12 11:03:55.665432349 +1000 @@ -162,8 +162,9 @@ # defaults for LIBS & INC & CCFLAGS params that we later pass to Writemakefile my $INC_magick = '-I/usr/local/include/ImageMagick-6 -DMAGICKCORE_HDRI_ENABLE=0 -DMAGICKCORE_QUANTUM_DEPTH=16 -I/usr/include/libxml2 -I"' . $Config{'usrinc'} . '/ImageMagick-6"'; -my $LIBS_magick = '-L/usr/local/lib -lMagickCore-6.Q16 -lperl -lm'; -my $CCFLAGS_magick = "$Config{'ccflags'} -I/usr/include/freetype2 -g -O2 -Wall -pthread -DMAGICKCORE_HDRI_ENABLE=0 -DMAGICKCORE_QUANTUM_DEPTH=16"; +my $LIBS_magick = '-L/usr/local/lib -lMagickCore-6.Q16 -lm'; +chomp(my $flags = `pkg-config --cflags ImageMagick`); +my $CCFLAGS_magick = "$Config{'ccflags'} -I/usr/include/freetype2 -g -O2 -Wall -pthread $flags"; my $LDFLAGS_magick = "-L/usr/local/lib -lMagickCore-6.Q16 $Config{'ldflags'} "; my $LDDLFLAGS_magick = "-L/usr/local/lib -lMagickCore-6.Q16 $Config{'lddlflags'} ";
On Mon Jul 11 21:08:57 2016, jasonblewis wrote: Show quoted text
> Diff for a workaround included. Thanks to TonyC for help on that one.
The proper fix is probably to set $INC_magick to the value from pkg-config if pkg-config is available. The -lperl caused link-time failures for me when building against the Debian packaged imagemagick. Tony
With that patch applied tests do not pass: # perl Makefile.PL Generating a Unix-style Makefile Writing Makefile for Image::Magick Writing MYMETA.yml and MYMETA.json root@9c13df2df60a:~/.cpan/build/PerlMagick-6.89-olDjKi# make cp Magick.pm blib/lib/Image/Magick.pm AutoSplitting blib/lib/Image/Magick.pm (blib/lib/auto/Image/Magick) Running Mkbootstrap for Image::Magick () chmod 644 "Magick.bs" "/usr/bin/perl" "/usr/share/perl/5.22/ExtUtils/xsubpp" -typemap "/usr/share/perl/5.22/ExtUtils/typemap" -typemap "typemap" Magick.xs > Magick.xsc && mv Magick.xsc Magick.c x86_64-linux-gnu-gcc -c -I/usr/local/include/ImageMagick-6 -DMAGICKCORE_HDRI_ENABLE=0 -DMAGICKCORE_QUANTUM_DEPTH=16 -I/usr/include/libxml2 -I"/usr/include/ImageMagick-6" -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fwrapv -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/freetype2 -g -O2 -Wall -pthread -fopenmp -DMAGICKCORE_HDRI_ENABLE=0 -DMAGICKCORE_QUANTUM_DEPTH=16 -I/usr/local/include/ImageMagick-6 -O2 -g -DVERSION=\"6.89\" -DXS_VERSION=\"6.89\" -fPIC "-I/usr/lib/x86_64-linux-gnu/perl/5.22/CORE" -D_LARGE_FILES=1 -DHAVE_CONFIG_H Magick.c rm -f blib/arch/auto/Image/Magick/Magick.so x86_64-linux-gnu-gcc -L/usr/local/lib -lMagickCore-6.Q16 -shared -L/usr/local/lib -fstack-protector-strong Magick.o -o blib/arch/auto/Image/Magick/Magick.so \ -L/usr/local/lib -lMagickCore-6.Q16 -lm \ chmod 755 blib/arch/auto/Image/Magick/Magick.so "/usr/bin/perl" -MExtUtils::Command::MM -e 'cp_nonempty' -- Magick.bs blib/arch/auto/Image/Magick/Magick.bs 644 Manifying 1 pod document root@9c13df2df60a:~/.cpan/build/PerlMagick-6.89-olDjKi# make test Running Mkbootstrap for Image::Magick () chmod 644 "Magick.bs" PERL_DL_NONLAZY=1 "/usr/bin/perl" "-MExtUtils::Command::MM" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; test_harness(0, 'blib/lib', 'blib/arch')" t/*.t t/jpeg/*.t t/jng/*.t t/mpeg/*.t t/png/*.t t/tiff/*.t t/zlib/*.t t/blob.t .......... ok t/composite.t ..... ok t/filter.t ........ Failed 1/58 subtests t/getattribute.t .. ok t/jng/read.t ...... ok t/jng/write.t ..... ok t/jpeg/read.t ..... ok t/jpeg/write.t .... ok t/montage.t ....... ok t/mpeg/read.t ..... Failed 2/2 subtests t/ping.t .......... ok t/png/read-16.t ... ok t/png/read.t ...... ok t/png/write-16.t .. ok t/png/write.t ..... ok t/read.t .......... ok t/setattribute.t .. ok t/tiff/read.t ..... Failed 2/16 subtests t/tiff/write.t .... Failed 2/10 subtests t/write.t ......... ok t/zlib/read.t ..... ok t/zlib/write.t .... ok Test Summary Report ------------------- t/filter.t (Wstat: 0 Tests: 58 Failed: 1) Failed test: 47 t/mpeg/read.t (Wstat: 0 Tests: 2 Failed: 2) Failed tests: 1-2 t/tiff/read.t (Wstat: 0 Tests: 16 Failed: 2) Failed tests: 2-3 t/tiff/write.t (Wstat: 0 Tests: 10 Failed: 2) Failed tests: 1, 3 Files=22, Tests=352, 4 wallclock secs ( 0.19 usr 0.02 sys + 5.54 cusr 0.63 csys = 6.38 CPU) Result: FAIL Failed 4/22 test programs. 7/352 subtests failed. Makefile:992: recipe for target 'test_dynamic' failed make: *** [test_dynamic] Error 255
Same problem here on Linux Mint 18 with perlbrew Perl 5.24.1. I followed the suggestion to set $INC_magick to pkg-config output and manually removed the -lperl library reference. I get these failures: PERL_DL_NONLAZY=1 "/home/bjoern/perl5/perlbrew/perls/perl-5.24.1/bin/perl" "-MExtUtils::Command::MM" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; test_harness(0, 'blib/lib', 'blib/arch')" t/*.t t/bzlib/*.t t/jpeg/*.t t/jng/*.t t/mpeg/*.t t/png/*.t t/tiff/*.t t/wmf/*.t t/zlib/*.t t/blob.t .......... ok t/bzlib/read.t .... ok t/bzlib/write.t ... ok t/composite.t ..... ok t/filter.t ........ ok t/getattribute.t .. ok t/jng/read.t ...... ok t/jng/write.t ..... ok t/jpeg/read.t ..... ok t/jpeg/write.t .... ok t/montage.t ....... ok t/mpeg/read.t ..... Failed 2/2 subtests t/ping.t .......... ok t/png/read-16.t ... ok t/png/read.t ...... ok t/png/write-16.t .. ok t/png/write.t ..... ok t/read.t .......... 1/47 Readimage (input.rle): Exception 425: improper image header `input.rle' @ error/rle.c/ReadRLEImage/333 at t/subroutines.pl line 313. t/read.t .......... Failed 1/47 subtests t/setattribute.t .. ok t/tiff/read.t ..... ok t/tiff/write.t .... ok t/wmf/read.t ...... ok t/write.t ......... ok t/zlib/read.t ..... ok t/zlib/write.t .... ok Test Summary Report ... For the t/mpeg/read.t test cases, I get a window with a smiley that I seem to have to close manually (titled "ImageMagick: input.m2v"). For the t/read.t test case, the failing one is: Alias/Wavefront RLE image format ... Readimage (input.rle): Exception 425: improper image header `input.rle' @ error/rle.c/ReadRLEImage/333 at t/subroutines.pl line 313. not ok 27 I get the same from the system `convert`: % convert t/input.rle delme.png convert: improper image header `t/input.rle' @ error/rle.c/ReadRLEImage/333. convert: no images defined `delme.png' @ error/convert.c/ConvertImageCommand/3210. % convert -v Version: ImageMagick 6.8.9-9 Q16 x86_64 2016-11-29 http://www.imagemagick.org