I'm reluctant to go ahead and run the hunspell installer as I'm not sure I can reverse the install and its my only windows test platform. Might have to bite the bullet....
What is the hunspell installer?
In the
steps for Linux, which is the second part you follow after installing msys2 and it's dependencies, you would run make install. But I don't think that installs anything in Windows. Just in the virtual environment of msys2.
I did build 1.3.0 because that was the one supplied with THunspell and it had a direct download link.
I'm now building the latest "-master" release..... building... building... done.
Just tried the resulting libhunspell-1.6-0.dll with the code snippet I gave earlier and I get "success" too.
What were the exact steps you took?
I did:
-----
Download and run Msys2
$ pacman -S base-devel mingw-w64-x86_64-toolchain mingw-w64-x86_64-libtool mingw-w64-x86_64-boost
$ exit
in Windows extract
hunspell-master to your home directory of Msys2. For me that was D:\msys64\home\Rik
Run Msys2 again (you are already in your home directory, see ls -ltr)
$ cd hunspell-master
$ autoreconf -vfi
$ ./configure
$ make
$ exit
Now libhunspell-1.6-0.dll is created in D:\msys64\home\Rik\hunspell-master\src\hunspell\.libs
-----
Now put the libhunspell-1.6-0.dll in your program directory and the call to Hunspell_create() should not crash.
I had to copy libgcc_s_seh-1.dll, libstdc++-6.dll and libwinpthread-1.dll too because I didn't statically link them but that should be possible to do.
(My
example with dlls is temporarily on my dropbox for the moment. You can use the download button at the top right if you want it.)