[crossfire] Update client GLib dependency

Kevin Zheng kevinz5000 at gmail.com
Wed May 7 20:25:59 CDT 2014


Hi there,

The GTKv2 client sources are split up into two parts, one for "common"
code that can be shared across different clients, and a "gtk-v2" part
that implements the GTK+ client itself.

GLib is a very useful library that provides portable data structures,
lexical scanners, threads, mutexes, timers, hook functions, and sockets.
Currently it is only used in the GTKv2 client because it is a dependency
of GTK+. I propose that GLib should be a dependency for the entire client.

1. There are lots of cool things that GLib will let us have that we
don't have now. Dynamically allocated strings, advanced data types, and
even a config file parser are all available from GLib.

2. GLib will make things more portable. I've been able to get the client
building on Windows again, but it's still very messy, particularly due
to excessive conditional compilation. GLib implements its own portable
sockets that can be used on multiple platforms.

3. GLib will make things less broken. Connecting to a server is a mess,
and sometimes freezes the client given the right circumstances.
Threading, callbacks, and parsing are messy, too.

4. GLib is already a dependency. Besides, on my system, the library and
all development files takes only 17 MB. Most people already have it
installed, because it is a dependency for Gtk, Qt, and more.

5. Even if somebody decides to write another client using SDL, OpenGL,
or maybe even Tcl, GLib can still be used and will still provide all of
its happy shiny benefits.

6. You probably don't care, since you're using the must shinier and
prettier and portable JXClient. So you should let me do whatever
satisfies my evil wishes.

Thanks,
Kevin Zheng


More information about the crossfire mailing list