Page 1 of 1

magick++ demo does not link

Posted: 2013-12-22T05:21:06-07:00
by tartalaran
downloaded fresh ImageMagick-6.8.7-10-Q16-x64-dll.exe. Installed with headers and libs on Windows 7 64bit. Opened Magick++_Demo in VS2012. Project "button" compiles, but linker fails:

Code: Select all

1>------ Build started: Project: button, Configuration: Release Win32 ------
1>  button.cpp
1>  MagickCore lib DLL import interface
1>  MagickCore module DLL export interface
1>  MagickWand lib DLL import interface
1>  MagickWand module DLL export interface
1>  Magick++ lib DLL import
1>button.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall Magick::Color::Color(char const *)" (__imp_??0Color@Magick@@QAE@PBD@Z) referenced in function _main
1>button.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall Magick::Color::Color(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)" (__imp_??0Color@Magick@@QAE@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z) referenced in function _main
1>button.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: virtual __thiscall Magick::Color::~Color(void)" (__imp_??1Color@Magick@@UAE@XZ) referenced in function _main
1>button.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall Magick::Geometry::Geometry(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)" (__imp_??0Geometry@Magick@@QAE@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z) referenced in function _main
1>button.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall Magick::Geometry::Geometry(char const *)" (__imp_??0Geometry@Magick@@QAE@PBD@Z) referenced in function _main
1>button.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall Magick::Geometry::~Geometry(void)" (__imp_??1Geometry@Magick@@QAE@XZ) referenced in function _main
1>button.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) void __cdecl Magick::InitializeMagick(char const *)" (__imp_?InitializeMagick@Magick@@YAXPBD@Z) referenced in function _main
...
What's wrong?

Re: magick++ demo does not link

Posted: 2013-12-22T10:27:49-07:00
by dlemstra
The demo does not link because the project files still target x86 instead of x64. Changing the target platform to x64 in the configuration manager should resolve the linking problem. We are working on changing this to make sure both the x86 and the x64 version of the demo will work.