[SOLVED] Failed to install from source on raspbian

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
fapibo
Posts: 2
Joined: 2016-01-30T01:26:43-07:00
Authentication code: 1151

[SOLVED] Failed to install from source on raspbian

Post by fapibo »

Hello,

I am struggling since 3 days to install the last revision of image magick from source on my raspberry pi.
I am using usual raspbian distribution based on Debian.

I followed the guide from http://www.imagemagick.org/script/install-source.php

I used the following commands:

Code: Select all

$sudo apt-get update
$sudo apt-get upgrate
$sudo apt-get install build-essential checkinstall
$wget http://www.imagemagick.org/download/ImageMagick-6.9.3-2.tar.gz
$tar -xzvf ImageMagick-6.9.3-2.tar.gz
$cd ImageMagick-6.9.3-2
$sudo ./configure --prefix=/opt/imagemagick693#I tried also without the --prefix
$sudo make
$sudo checkinstall
I get plenty of warnings during "make" step but I guess it is not the root cause of my issue. I paste here for info:
coders/png.c:2238:8: warning: passing argument 3 of ‘png_set_keep_unknown_chunks’ discards ‘const’ qualifier from pointer target type [enabled by default]
/usr/include/libpng12/png.h:2589:8: note: expected ‘png_bytep’ but argument is of type ‘const png_byte *’
coders/png.c:2249:3: warning: passing argument 3 of ‘png_set_keep_unknown_chunks’ discards ‘const’ qualifier from pointer target type [enabled by default]
/usr/include/libpng12/png.h:2589:8: note: expected ‘png_bytep’ but argument is of type ‘const png_byte *’
CC coders/magick_libMagickCore_6_Q16_la-x.lo
CC coders/magick_libMagickCore_6_Q16_la-xwd.lo
CC filters/magick_libMagickCore_6_Q16_la-analyze.lo
CCLD magick/libMagickCore-6.Q16.la
copying selected object files to avoid basename conflicts...
CC wand/wand_libMagickWand_6_Q16_la-animate.lo
CC wand/wand_libMagickWand_6_Q16_la-compare.lo
CC wand/wand_libMagickWand_6_Q16_la-composite.lo
CC wand/wand_libMagickWand_6_Q16_la-conjure.lo
CC wand/wand_libMagickWand_6_Q16_la-convert.lo
CC wand/wand_libMagickWand_6_Q16_la-deprecate.lo
wand/deprecate.c: In function ‘MagickColorFloodfillImage’:
wand/deprecate.c:1199:3: warning: ‘ColorFloodfillImage’ is deprecated (declared at ./magick/deprecate.h:185) [-Wdeprecated-declarations]
wand/deprecate.c: In function ‘MagickFlattenImages’:
wand/deprecate.c:1269:3: warning: ‘FlattenImages’ is deprecated (declared at ./magick/deprecate.h:137) [-Wdeprecated-declarations]
wand/deprecate.c: In function ‘MagickMapImage’:
wand/deprecate.c:1593:3: warning: ‘MapImage’ is deprecated (declared at ./magick/deprecate.h:212) [-Wdeprecated-declarations]
wand/deprecate.c: In function ‘MagickMatteFloodfillImage’:
wand/deprecate.c:1665:3: warning: ‘MatteFloodfillImage’ is deprecated (declared at ./magick/deprecate.h:216) [-Wdeprecated-declarations]
wand/deprecate.c: In function ‘MagickMosaicImages’:
wand/deprecate.c:1840:3: warning: ‘MosaicImages’ is deprecated (declared at ./magick/deprecate.h:142) [-Wdeprecated-declarations]
wand/deprecate.c: In function ‘MagickOpaqueImage’:
wand/deprecate.c:1886:3: warning: ‘MagickPaintOpaqueImage’ is deprecated (declared at ./wand/deprecate.h:105) [-Wdeprecated-declarations]
wand/deprecate.c: In function ‘MagickPaintOpaqueImage’:
wand/deprecate.c:1987:3: warning: ‘MagickPaintOpaqueImageChannel’ is deprecated (declared at ./wand/deprecate.h:107) [-Wdeprecated-declarations]
wand/deprecate.c: In function ‘MagickRecolorImage’:
wand/deprecate.c:2133:3: warning: ‘RecolorImage’ is deprecated (declared at ./magick/deprecate.h:148) [-Wdeprecated-declarations]
wand/deprecate.c: In function ‘MagickTransparentImage’:
wand/deprecate.c:2377:3: warning: ‘MagickPaintTransparentImage’ is deprecated (declared at wand/deprecate.c:2039) [-Wdeprecated-declarations]
The issue seems during checkinstall step: first a warning
libtool: warning: relinking 'wand/libMagickWand-6.Q16.la'
Then the following error occured:
========================= Installation results ===========================
make install-am
make[1]: Entering directory '/home/pi/temp/ImageMagick-6.9.3-1'
make[2]: Entering directory '/home/pi/temp/ImageMagick-6.9.3-1'
/bin/mkdir -p '/opt/imagemagick693/lib'
/bin/mkdir: cannot create directory `/opt/imagemagick693': No such file or directory
Makefile:5411: recipe for target 'install-libLTLIBRARIES' failed
make[2]: *** [install-libLTLIBRARIES] Error 1
make[2]: Leaving directory '/home/pi/temp/ImageMagick-6.9.3-1'
Makefile:11255: recipe for target 'install-am' failed
make[1]: *** [install-am] Error 2
make[1]: Leaving directory '/home/pi/temp/ImageMagick-6.9.3-1'
Makefile:11249: recipe for target 'install' failed
make: *** [install] Error 2

**** Installation failed. Aborting package creation.

Cleaning up...OK

Bye.
It seems related to permission issues but I use sudo. I also tried logged as root.

Many thanks for your help!
Last edited by fapibo on 2016-01-30T07:04:49-07:00, edited 1 time in total.
fapibo
Posts: 2
Joined: 2016-01-30T01:26:43-07:00
Authentication code: 1151

Re: Failed to install from source on raspbian

Post by fapibo »

I finally found the root cause: the issue is in the checkinstall settings

The fix is simple:

Code: Select all

$sudo nano /etc/checkinstallrc
set TRANSLATE=0 (was TRANSLATE=1)
exit & save

and it works like a charm :D
hengsopheak
Posts: 16
Joined: 2017-03-21T07:45:32-07:00
Authentication code: 1151

Re: [SOLVED] Failed to install from source on raspbian

Post by hengsopheak »

I got this errors too and try to do as your commend-line but not work

sudo make install
make install-am
make[1]: Entering directory '/opt/ImageMagick-7.0.5-4'
CCLD MagickCore/libMagickCore-7.Q16HDRI.la
/usr/bin/ld: /usr/local/lib/libbz2.a(bzlib.o): relocation R_X86_64_32S against `BZ2_crc32Table' can not be used when making a shared object; recompile with -fPIC
/usr/local/lib/libbz2.a: error adding symbols: Bad value
collect2: error: ld returned 1 exit status
Makefile:6026: recipe for target 'MagickCore/libMagickCore-7.Q16HDRI.la' failed
make[1]: *** [MagickCore/libMagickCore-7.Q16HDRI.la] Error 1
make[1]: Leaving directory '/opt/ImageMagick-7.0.5-4'
Makefile:11332: recipe for target 'install' failed
make: *** [install] Error 2
Post Reply