Magick-config uses $MAGICK_HOME instead of $prefix?

Questions and postings pertaining to the development of ImageMagick, feature enhancements, and ImageMagick internals. ImageMagick source code and algorithms are discussed here. Usage questions which are too arcane for the normal user list should also be posted here.
Post Reply
rmagick
Posts: 245
Joined: 2006-03-16T17:30:48-07:00
Location: Durham, NC, USA

Magick-config uses $MAGICK_HOME instead of $prefix?

Post by rmagick »

Below is an excerpt from the config.log produced while trying to install RMagick on OS X 10.4.9. I use `Magick-config --ldflags` to get the necessary flags. Apparently Magick-config --ldflags is returning paths with names that start with $MAGICK_HOME instead of the prefix. Is this new? How should I handle it?


configure:2471: checking for InitializeMagick in -lMagick
configure:2501: gcc -o conftest -I$MAGICK_HOME/include -L$MAGICK_HOME/lib -Wl,-syslibroot,/Developer/SDKs/MacOSX10.4u.sdk -L$MAGICK_HOME/bzlib -L$MAGICK_HOME/jp2 -L$MAGICK_HOME/jp2/src/libjasper -L$MAGICK_HOME/jp2/src/libjasper/.libs -L$MAGICK_HOME/jbig/libjbig -L$MAGICK_HOME/jpeg -L$MAGICK_HOME/lcms/src -L$MAGICK_HOME/lcms/src/.libs -L$MAGICK_HOME/magick -L$MAGICK_HOME/magick/.libs -L$MAGICK_HOME/png -L$MAGICK_HOME/png/.libs -L$MAGICK_HOME/tiff/libtiff -L$MAGICK_HOME/tiff/libtiff/.libs -L$MAGICK_HOME/ttf/objs -L$MAGICK_HOME/ttf/objs/.libs -L$MAGICK_HOME/wand -L$MAGICK_HOME/wand/.libs -L$MAGICK_HOME/wmf/src -L$MAGICK_HOME/wmf/src/.libs -L$MAGICK_HOME/xml -L$MAGICK_HOME/xml/.libs -L$MAGICK_HOME/zlib -L/X11R6/lib -lfreetype conftest.c -lMagick -lMagick -llcms -ltiff -lfreetype -ljpeg -lbz2 -lz -lpthread -lm -lpthread -lWand -lMagick >&5
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/lib) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/bzlib) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/jp2) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/jp2/src/libjasper) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/jp2/src/libjasper/.libs) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/jbig/libjbig) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/jpeg) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/lcms/src) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/lcms/src/.libs) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/magick) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/magick/.libs) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/png) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/png/.libs) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/tiff/libtiff) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/tiff/libtiff/.libs) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/ttf/objs) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/ttf/objs/.libs) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/wand) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/wand/.libs) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/wmf/src) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/wmf/src/.libs) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/xml) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/xml/.libs) does not exist
/usr/bin/ld: warning -L: directory name ($MAGICK_HOME/zlib) does not exist
/usr/bin/ld: warning -L: directory name (/X11R6/lib) does not exist
/usr/bin/ld: can't locate file for: -lfreetype
collect2: ld returned 1 exit status
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: Magick-config uses $MAGICK_HOME instead of $prefix?

Post by magick »

Did you grab the ImageMagick Mac OS X binary distribution? If so, it is behaving properly. The binary distributions are configured as "uninstalled" and requires that you set the MAGICK_HOME environment variable. You can build ImageMagick yourself with an "installed" configuration that relies on $prefix. See http://magick.imagemagick.org/script/ad ... php#macosx.
rmagick
Posts: 245
Joined: 2006-03-16T17:30:48-07:00
Location: Durham, NC, USA

Re: Magick-config uses $MAGICK_HOME instead of $prefix?

Post by rmagick »

No, this occurred after downloading ftp.imagemagick.org/pub/ImageMagick/ImageMagic.tar.gz and running the usual configure/make/make install. I've got a script that does this that I've been distributing for a month or so now. Haven't run into the problem myself, but the last time I test the script was two Sundays ago. I got this report from a user two days ago (this past Sunday). Maybe something changed in the past week?
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: Magick-config uses $MAGICK_HOME instead of $prefix?

Post by magick »

We don't see any references to MAGICK_HOME in the build other than a comment. Perhaps the user has two versions of ImageMagick installed that cause a conflict. Without additional information we can be of no further help.
rmagick
Posts: 245
Joined: 2006-03-16T17:30:48-07:00
Location: Durham, NC, USA

Re: Magick-config uses $MAGICK_HOME instead of $prefix?

Post by rmagick »

You're absolutely correct. I need to remember that whenever anybody reports a mysterious problem while installing RMagick that the first question to ask is "do you have more than one version of ImageMagick installed?" The answer is always "yes".

Thanks for your time!
Post Reply