libraw_open_wfile not found on Windows with Mysys2

Hello.

I am trying to compile my software to Windows with the Mysys2 package manager. Everything is going right but one function.
Indeed, I was using libraw_open_file for my whole app but on Windows it crashes. So I tried to use libraw_open_wfile as defined in the documentation. But I have the following message:

warning: implicit declaration of function 'ibraw_open_wfile'; did you mean 'ibraw_open_file' ?

I went throug the include file and I saw these lines:

#if defined(_WIN32) && !defined(__MINGW32__) && defined(_MSC_VER) && (_MSC_VER > 1310)
DllDef int libraw_open_wfile(libraw_data_t*, const wchar_t *);
DllDef int libraw_open_wfile_ex(libraw_data_t*, const wchar_t *, INT64 max_buff_sz);
#endif

So, it should be ok ?
Please could you tell me how to proceed ?

Forums: 

Sorry, have not used Mysys2,

Sorry, have not used Mysys2, so not know what preprocessor variables are defined

-- Alex Tutubalin @LibRaw LLC

OK.

OK.
In fact with MySys2 it is mingw and there is no _MSC_VER macro definition neither ...
So it definitely can't work.

Is there any reasons why MINGW is not wanted for the windows version of the function ?
For example with libtif I've faced to the same issue but the windows function is ok with mingw:

extern TIFF* TIFFOpen(const char*, const char*);
# ifdef __WIN32__
extern TIFF* TIFFOpenW(const wchar_t*, const char*);
# endif /* __WIN32__ */

Cheers,
Cyril

I'm not sure that all MinGW

I'm not sure that all MinGW versions supports std::filebuf->open(wchar_t*);

You may try to enable this in your LibRaw copy

-- Alex Tutubalin @LibRaw LLC