I am building Image Magick into a custom directory (with configure --prefix=...), and I also want to build Perl Magick.
With PerlMagick-6.59, I could use the following recipe:
tar zxf PerlMagick-6.59.tar.gz
cd PerlMagick-6.59
export IM_INC="-I$IM_HOME/include/ImageMagick "
export IM_LIB="-L$IM_HOME/lib "
perl Makefile.PL
make
make install
In this case $IM_HOME is where I have installed ImageMagick.
The above recipe doesn't seem to work for PerlMagick-6.67. I get the error:
Note (probably harmless): No library found for -lMagickCore
and the make fails with:
Magick.xs:64:31: error: magick/MagickCore.h: No such file or directory
Is there a way I can specify the Image Magick include path and library path on the 'perl Makefile.PL' command?
custom include and library paths when building PerlMagick?
- anthony
- Posts: 8883
- Joined: 2004-05-31T19:27:03-07:00
- Authentication code: 8675308
- Location: Brisbane, Australia
Re: custom include and library paths when building PerlMagic
Generally to install a custom ImageMagick you also install the Custom PerlMagick at the same time.
It is very important that the two versions match.
The simplist way is to just configure both using
Then both will be installed into the location of MAGIC_HOME.
It is very important that the two versions match.
The simplist way is to just configure both using
Code: Select all
configure --prefix=$MAGICK_HOME --disable-installed
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
https://imagemagick.org/Usage/
Re: custom include and library paths when building PerlMagic
My apologies... PerlMagick-6.59 does not support the environment variables IM_LIB and IM_INC to tell PerlMagick where to find the ImageMagick libraries and include files. It turns out that this was a hack made to our source to support installing IM in a non-standard location.
it would be very nice if something like these environment variables were supported by ImageMagick/PerlMagick.
In addition, we've found that including -lperl in $LIBS_magick can be problematic, and it is not required, so we've removed it from the link command.
it would be very nice if something like these environment variables were supported by ImageMagick/PerlMagick.
In addition, we've found that including -lperl in $LIBS_magick can be problematic, and it is not required, so we've removed it from the link command.