Tuesday, November 6, 2007

OpenSmash: SVN r3

Well, revision 3 has finally been committed. I've been a busy beaver with music for my classes, but I decided to crack down and get MinGW working. MinGW, for those not in the know, is a Win32-target GCC with an entire runtime and w32api capable of generating native Windows binaries. It's cool shit. You can build a cross-compiler from Linux that targets Windows.

So, after about six hours of fussing, I got Irrlicht, OpenAL, and libvorbisfile DLLs built and compiled in my cross environment. With a bit more work, I finished #ifdeffing OpenSmash, mostly in the joystick code, and finished the safety checks for compiling on Win32. It built, but didn't link.

Link errors came from Irrlicht. Apparently, between 1.3.1 and 1.4b, Irrlicht changed the API for a certain inherited class, from
virtual bool irr::IEventReceiver::OnEvent(irr::SEvent event);
to
virtual bool irr::IEventReceiver::OnEvent(const irr::SEvent& event);
Which was obviously a problem. To solve this, the source code now follows the latter, and Irrlicht 1.4b (or their latest Subversion) is required to build on both Linux and Win32.

I also started on the DirectInput part of the joysticks. Right now, DirectInput8 is initialized and shut down at the correct time. However, it doesn't do anything more. Also, it doesn't run right in Wine. It doesn't exit when I tell it to; it just spins for a bit and then dies with an error. I'm putting it down to the mangled DLLs I'm using, and hopefully it runs better on a real Win32 system.

Summary:
  • Include guards for <dinput.h>, <windows.h>, <linux.h>
  • Updated required Irrlicht version to 1.4b
  • Added initial Windows 32-bit support
  • Added "mingw32" build target to Kdevelop project
See you later. Tomorrow, after class, I tackle the second part of OpenAniDB: Fleshing out the GUI skeletons.
~ C.

No comments: