I'm developing a C++ program using Magick++ in Linux. Up till now everything has been working great, but I've hit a wall while trying to build a Windows port using MinGW. To illustrate the problem, let's say we have a simple program:
Code: Select all
int main(int argc, char **argv)
{
#ifdef WIN32
InitializeMagick(*argv);
#endif
Image pic;
pic.read("a.bmp");
pic.crop( Geometry(100,100, 100, 100));
pic.write("b.bmp");
}
Code: Select all
neuviemep@ihuarraquax:magick$ i586-mingw32msvc-g++ -I/mnt/winxp/Program\ Files/ImageMagick-6.3.7-Q16/include/ -o mtest.exe mtest.cc -L/mnt/winxp/Program\ Files/ImageMagick-6.3.7-Q16/ -lCORE_RL_Magick++_
undefined reference to `Magick::Image::Image()'
undefined reference to Magick::Image::read(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'
[...]
collect2: ld returned 1 exit status