[crossfire] Win32 client compilation
Kurt Fitzner
kurt.fitzner at gmail.com
Tue Apr 2 15:06:01 CDT 2013
Hello,
It looks like, since the last time I was involved with CF, a lot of work
was done getting the gtk2 client to compile more nicely in Windows under
mingw. There are a few issues that remain, however. I've listed them
below.
- MINGW macro is deprecated. It is now __MINGW32__. Patch follows.
- The configure script uses pkg-config to check for gtk+, but then the
gtk-v2/src/Makefile.in doesn't use the resultant GTK2_CFLAGS variable.
This breaks builds on mingw because include files aren't in the standard
unixy places. I think just adding @GTK_CFLAGS@ to AM_CFLAGS in
Makefile.am should fix it, but I don't have the right version of
autoconf to find out for sure. Changing this should have no effect on
Unix other than making the build system work in more circumstances.
- The configure script checks for libglade don't check to make sure
pkg-config reports that it works. This means where libglade is
installed, but a dependency for it (like libxml) isn't installed, the
configure script works as normal but then the build breaks because
LIBGLADE_CFLAGS isn't set. Don't know how to fix this other than to say
that the test for gtk+ does it the right way so the libglade check
should duplicate the way gtk+ is tested for.
I have it compiling with SDL and OpenGL support, which the Windows
binary that is available now lacks. Still testing to make sure they
work right.
I seem to remember there being at least simple sound support in Windows
on the older clients. Am I misremembering, or was that code ripped out?
I'll post step-by-step instructions on setting up the mingw environment
as soon as I clean it up.
Kurt.
--- /home/Kurt/tmp/crossfire-client-1.70.0/gtk-v2/src/config.c
2012-03-18 03:17:47 -0300
+++ gtk-v2/src/config.c 2013-04-02 09:16:35 -0300
@@ -41,11 +41,11 @@
#include "image.h"
#include "gtk2proto.h"
#include <dirent.h>
-#ifdef MINGW
+#ifdef __MINGW32__
int alphasort(const struct dirent **a, const struct dirent **b)
{
return strcoll((*a)->d_name, (*b)->d_name);
}
More information about the crossfire
mailing list