develooper Front page | perl.macosx | Postings from June 2002

Re: imagemagick again: FIXED

Thread Previous
From:
william ross
Date:
June 17, 2002 13:24
Subject:
Re: imagemagick again: FIXED
Message ID:
4104C5D1-8238-11D6-A3D1-0003938AF80E@spanner.org
oh well. with the help of some monkeys and typewriters i seem to have 
made perlmagick work.

I just had to add -lxml2 to the LIBS. it's likely that's because i did 
something stupid before which led to the installation happening in a 
different context to the usual one, but it is a different version of the 
fink package, so it may be that a different set of dependencies comes in 
with it.

Just in case that's the case, and the instructions need updating, i'll 
recap. but i'd strongly advise people to try the original instructions 
first. they're at
http://archive.develooper.com/macosx@perl.org/msg01106.html

1. Install ImageMagick from the source using fink (which will need to be 
told to use the unstable tree: the stable version is rather old, and 
anyway a binary package won't leave the necessary source files behind)
2. Unpack /sw/src/ImageMagick-5.4.5.tar.gz
3. cd to /sw/src/ImageMagick-5.4.5/PerlMagick/
4. edit Makefile.PL like so:

35c35
< foreach $delegate (qw/ bzlib fpx jp2 jpeg lcms mpeg png ps tiff ttf x 
xfig zlib/) {
---
 > foreach $delegate (qw/ ps tiff ttf x zlib/) {
55c55
<    'INC'	=> '-I../ -I.. -I/usr/include/libxml2 
-I/usr/include/freetype2 -D_REENTRANT -D_FILE_OFFSET_BITS=64 
-I/usr/local/include -I/usr/X11R6/include -I/usr/X11R6/include/X11',
---
 >    'INC'      => '-I../ -I.. -I/sw/include -I/usr/include/freetype2 
-I/usr/include/freetype2 -D_REENTRANT -D_FILE_OFFSET_BITS=64 
-I/usr/local/include -I/X11',
61c61
<    'LIBS'	=> ['-L/usr/lib -L/usr/lib -L/usr/local/lib 
-L/usr/X11R6/lib -L/home/cristy/ImageMagick/magick -lMagick -llcms 
-ltiff -lfreetype -ljasper -ljpeg -lpng -lfpx -ldpstk -ldps -lXext -lXt 
-lSM -lICE -lX11 -lbz2 -lxml2 -lz -lpthread -lm'],
---
 >    'LIBS'     => ['-L/sw/lib -L/usr/lib -L/usr/local/lib 
-L/usr/X11R6/lib -L/home/cristy/ImageMagick/magick -lMagick -ltiff 
-lfreetype  -ljasper  -lpng  -ldpstk -ldps -lXext -lXt  -lSM -lICE -lX11 
-lbz2  -lz -lpthread  -lm -lxml2'],
73c73
<    # 'PERLMAINCC'	=> 'gcc',
---
 >    # 'PERLMAINCC'	=> 'cc',

sorry if this is the wrong format. i'm a diff novice.
most of those changes are from Randal's original message, by the way. i 
just added -lxml2.

5. you should then be able to install perlmagick in the usual way.

hope this helps someone. if only me, next time.

will



ps. none of which explains why i was getting png and bz library errors 
before. i did something accidentally right at some point which made them 
turn into xml library errors and then managed to get rid of those. still 
mostly fumbling for light switches here :(


Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About