[Gtkradiant] Compiling libxml2 for Radiant

Nerius Landys nlandys at gmail.com
Thu Jan 27 01:50:43 CST 2011

Hello all (and especially divVerent).

I'm in the process of compiling libxml2 for Radiant, and I ran into some
problems (I sort of managed to solve them).  I'm wondering if anyone has
anything to say about the problems I've had and how I've solved them.

So I'm using the libxml2-2.7.x.tar.gz files found here:
I'm using MinGW/MSYS and the classic configure, make, and "make install"
procedure.  I did try the "cscript configure.js" etc. procedure described in
win32/Readme.txt, but that did not seem to work at all, regardless of
various permutations of settings (like cmd.exe Command Prompt vs MSYS, and
msvc vs mingw-gcc compiler).

So, sticking with configure / make.  Now, first I tried
libxml2-2.7.8.tar.gz.  Unfortunately, with this one and anything down to
libxml2-2.7.4.tar.gz, I get an error like this one at the end of the
configure step:

config.status: creating python/setup.py
config.status: creating config.h
config.status: executing depfiles commands
config.status: executing libtool commands
/bin/rm: cannot lstat `libtoolT': No such file or directory
Done configuring

nlandys at hugo ~/libxml2-2.7.8
$ libtool --version
libtool (GNU libtool) 2.2.10
Written by Gordon Matzigkeit <gord at gnu.ai.mit.edu>, 1996

Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO

nlandys at hugo ~/libxml2-2.7.8

So I decided to use libxml2-2.7.3.tar.gz because it is the latest version
that does not give me that error.

Now there were 2 things I noticed when compiling libxml2, after the
configure succeeded.

First, there is some compile error with the threads code in libxml2, and it
seems to be related to pthreads.  I'm surprised that it's using the pthread
code instead of using native Windows threads.  Instead of mucking with this
(as I didn't see any clear solution in the configure help), I decided to
disable threads.

The second thing is iconv.  My new Gtk+ libraries don't include iconv, so
there currently isn't a dependency on iconv.  By default libxml2 uses
iconv.  I decided to disable this as well.  I want to minimize dependency
hell, and try to keep things as modular as possible.

So, my final configure line turned out to look like this (I'm not entirely
sure what the "AR=/usr/bin/ar" is for, but I used that when compiling

nlandys at hugo ~/libxml2-2.7.3
$ env CC='gcc -march=pentium4' AR=/usr/bin/ar \
./configure \
--prefix=/home/nlandys/libxml2-install \
--build=i386-pc-mingw32 \
--disable-static \
--enable-ipv6=no \
--without-iconv \
--without-threads \
--without-zlib \
--without-python \

I disabled zlib, python, and readline because from reading the configure
help it seems that these are external dependencies as well.

Anyhow, all compiled well with the above configure line.

Do you see any problems with lack of thread and iconv support in libxml2 for
Radiant?  Is this something I need to worry about?

- Rambetter
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://zerowing.idsoftware.com/pipermail/gtkradiant/attachments/20110126/bbcd3708/attachment.htm 

More information about the Gtkradiant mailing list