mingwitkgdcm

Error while compiling ITK 4.10.0 on Windows


I have to improve a software using InsightToolKit, DGTal and Armadillo, therefore I need to install them. I'm new to projects using such big libraries but until here I managed to understand what I was doing.

So, I'm running under Windows 10 64bits and I use CMake-GUI to build my sources. Here's what I've done : Using MinGW, i've installed gcc and g++ and gfortran to set as compilers for respectively C, C++ and Fortran.

Now that I've set them as compilers in the GUI, I launch my configuration and a makefile is generated without problems (well at least no red messages in the textbox of CMake), sources built in a \bin folder.

I use then mingw32-make.exe, and around 50%, compilation stops with these errors (the log is a bit long so I pastebin-ed it here, but all are like this form :

ITK-4.10.0\Modules\ThirdParty\GDCM\src\gdcm\Source\Common\gdcmCAPICryptographicMessageSyntax.cxx: In member function 'virtual bool gdcm::CAPICryptographicMessageSyntax::ParseCertificateFile(const char*)':

or :

\gdcmCAPICryptographicMessageSyntax.cxx:62:54: error: 'CRYPT_STRING_BASE64_ANY' was not declared in this scope

I made some searches and i found no one having the same issue. I tried on another machine and i got the same result, building stops at this point. The only thing I've found is that this comes from GDCM, needed by ITK but shipped with it in the lasts versions. I don't know what to do with it now.

Does anyone have an idea?


Solution

  • Here is the solution:

    Use mingw64 instead of mingw32.

    Mingw64 is a tool more compatible with win64, developed by another group. It works fine.