[Tux4kids-tuxtype-dev] Libxml2 in Tux4kids

David Bruce davidstuartbruce at gmail.com
Mon Jun 21 11:26:05 UTC 2010


Hi Michal,

2010/6/21 Michał Świtakowski <tux4kids at switakowski.com>:
> Hi,
>
> We decided with Vikas to use XML for lesson files generated by tux4kids-admin
> and read by TM and TT. To make parsing those files easier Vikas uses libxml2
> library which will be introduced in tux4kids. I wonder if we should make it possible
> to compile our games without support for tux4kids-admin and consequently without libxml2.
> I think about SCHOOL_MODE macro and set of
>
> #ifdef SCHOOL_MODE
> ...
> #endif
>
> conditions in the code. SCHOOL_MODE could be enabled/disabled by autotools
> with configure script if I'm right. Do you think we should do it that way?

Yes, we can certainly support optional use of libraries at configure
time in configure.ac - we do that already with several things
(SDL_Pango, SDL_net, librsvg2, and also libt4k_common) with flags like
"--without-sdlpango".  By default, autotools gives us preprocessor
macros such as "HAVE_SDL_PANGO" to allow C code to behave
appropriately, but we can use whatever macros we want in case
"SCHOOL_MODE" turns out to be not quite identical with "HAVE_XML2".

David



More information about the Tux4kids-tuxtype-dev mailing list