PDA

View Full Version : Compiling QT program with Wiiyourself error help



mumbles
16th January 2013, 10:03
Hey Team,

I am trying to write a program that interfaces with the Wii balance board using the wiiyourself library (http://wiiyourself.gl.tter.org/). When I include the files into my project as it states in the readme, it throws up tonnes of compile error messages, mainly :

error: cannot convert 'const char*' to 'const TCHAR* {aka const wchar_t*}' in initialization

There is about 100 of these errors in the wiimote.cpp which came from the wiiyourself library.

Some of the other errors include:

error: '_vsnprintf' was not declared in this scope
error: cannot convert 'const char*' to 'LPCWSTR {aka const wchar_t*}' for argument '1' to 'HINSTANCE__* LoadLibraryW(LPCWSTR)'
etc etc

Can this library be compiled with MINGW, if so what am I missing? (I have written my program and chosen other libraries based on MINGW so don't want to change if possible).

Thanks in advance.

ChrisW67
16th January 2013, 23:02
Can this library be compiled with MINGW
Well, the ReadMe.txt file implies it can, and the demo source comes with scripts to build using MinGW.

The library source is expecting wide strings because the UNICODE define is present (I guess). Somewhere to look.

Nothing to do with Qt of course.