ImageMagick folder in Perl?

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
User avatar
anthony
Posts: 8883
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia

Post by anthony »

@INC is the perl module search path, meaning perl can't resolve the "use ImageMagick" line pf the perl script. This can be resolve by either setting an environment variable PERL5LIB, before running the perl script, OR, adding a line...

Code: Select all

   use lib "/path/to/imagemagick/perl/module/directory";
I have used both in various projects.
For example in another (non-IM) project I use...

Code: Select all

use lib (getpwnam('duty'))[7] . '/acctdb/perl-lib';
use strict;
use AcctDB        qw( db_user db_uid db_gid bin_dir dist_dir pgp_dir );
and it works well.
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
User avatar
anthony
Posts: 8883
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia

Post by anthony »

In a normal install the PerlMagic is in the perl module library folder, and the binaries are in the system directories. However you indicated that this was not the case, and does not have to be the case either, with appropriate setup.
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
Post Reply