I downloaded Magick++ MinGW version. I extracted it to MinGW folder. I moved the files from includes/ImageMagick-6 to includes, because it was complaning when I tried:
#include <ImageMagick-6/Magick++.h>
So now I can write just:
#include <Magick++.h>
main.cpp is:
Image image("100x100","black");
image.write("C:/blackness.png");
Now it writes the following error:
cd 'C:\cprojects\dotmap'
C:\MinGW\msys\1.0\bin\make.exe -f Makefile CONF=Debug
"/C/MinGW/msys/1.0/bin/make.exe" -f nbproject/Makefile-Debug.mk QMAKE= SUBPROJECTS= .build-conf
make.exe[1]: Entering directory `/c/cprojects/dotmap'
"/C/MinGW/msys/1.0/bin/make.exe" -f nbproject/Makefile-Debug.mk dist/Debug/MinGW-Windows/dotmap.exe
make.exe[2]: Entering directory `/c/cprojects/dotmap'
mkdir -p dist/Debug/MinGW-Windows
g++ -static-libgcc -static-libstdc++ -o dist/Debug/MinGW-Windows/dotmap build/Debug/MinGW-Windows/Cell.o build/Debug/MinGW-Windows/LasHandler.o build/Debug/MinGW-Windows/Point.o build/Debug/MinGW-Windows/main.o
build/Debug/MinGW-Windows/main.o: In function `main':
C:\cprojects\dotmap/main.cpp:65: undefined reference to `Magick::Color::Color(char const*)'
C:\cprojects\dotmap/main.cpp:65: undefined reference to `Magick::Geometry::Geometry(std::string const&)'
C:\cprojects\dotmap/main.cpp:65: undefined reference to `Magick::Image::Image(Magick::Geometry const&, Magick::Color const&)'
C:\cprojects\dotmap/main.cpp:65: undefined reference to `Magick::Geometry::~Geometry()'
C:\cprojects\dotmap/main.cpp:65: undefined reference to `Magick::Color::~Color()'
C:\cprojects\dotmap/main.cpp:69: undefined reference to `Magick::Image::write(std::string const&)'
C:\cprojects\dotmap/main.cpp:65: undefined reference to `Magick::Image::~Image()'
C:\cprojects\dotmap/main.cpp:49: undefined reference to `Magick::Geometry::~Geometry()'
C:\cprojects\dotmap/main.cpp:49: undefined reference to `Magick::Color::~Color()'
C:\cprojects\dotmap/main.cpp:65: undefined reference to `Magick::Image::~Image()'
collect2.exe: error: ld returned 1 exit status
make.exe[2]: *** [dist/Debug/MinGW-Windows/dotmap.exe] Error 1
make.exe[2]: Leaving directory `/c/cprojects/dotmap'
make.exe[1]: *** [.build-conf] Error 2
make.exe[1]: Leaving directory `/c/cprojects/dotmap'
make.exe": *** [.build-impl] Error 2
BUILD FAILED (exit value 2, total time: 17s)
What google dropped on magick++ undefined reference
wasn't helpful.
What do I need to do to fix this?
UPDATE
I've added to the linker: -lMagick++-6.Q16.dll -lMagickCore-6.Q16.dll -lMagickWand-6.Q16.dll
Now undefined reference is solved, build successful. But on run it says: error while loading shared libraries: ?: cannot open shared object file: No such file or directory