Page 1 of 1

Compiling error!

Posted: 2006-12-28T02:50:41-07:00
by stanleyweike
Hi,
I was programming with magickcore. And when compiling, I came across the following message:

imgfilter.cpp: In function `int main(int, char **)':
imgfilter.cpp:32: implicit declaration of function `int AcquireExceptionInfo(...)'
imgfilter.cpp:32: assignment to `ExceptionInfo *' from `int' lacks a cast
imgfilter.cpp:50: implicit declaration of function `int AcquireQuantizeInfo(...)'
imgfilter.cpp:50: assignment to `QuantizeInfo *' from `int' lacks a cast
imgfilter.cpp:70: void value not ignored as it ought to be
imgfilter.cpp:15: warning: unused variable `struct Image * qimage'

and my compiling command line is :

cc `Magick-config --cflags --cppflags` imgfilter.cpp `Magick-config --ldflags --libs` -I/homes/xxx/download/ImageMagick-6.3.0/include

and it seems some library is not included, is there anyone who used to have similar problem?

Posted: 2006-12-28T07:51:56-07:00
by magick
Did you include the MagickCore API header in your source module? You need
  • #include <magick/MagickCore.h>

Posted: 2006-12-28T15:49:35-07:00
by stanleyweike
definitely, I included this header file.