Hi,

I tried compiling Adonthell on a Debian squeeze machine this weekend, and
ran into a problem with src/py-wrappers/adonthell/py_audio.i which includes
"audio/sound.h".

Unfortunately, this is the same name as under /usr/include/audio/sound.h,
which is part of libaudio-dev, the network audio system. and python starts
using libaudio headers in some parts and the build process uses adonthell's
headers in others.

This reveals a weak point in both adonthell's build system, and its library
includes, in my opinion.

Applications that build against adonthell, should include headers like this:
#include <adonthell/audio/sound.h> instead of just <audio/sound.h>.
And the headers should be installed under something like:

        /usr/include/adonthell-1.1/adonthell/audio/sound.h

so that applications can specify which version of adonthell they want to
compile against, by setting -I/usr/include/adonthell-1.1 in their compiler
flags.

My idea is to add a symlink called adonthell, under build/ that links
to src/.  The build/ directory is already in the -I include paths, so this
makes including <adonthell/audio/sound.h> possible.  Then change all the
applications, such as worldtest, to use <adonthell/...> and change the rest
of the code only where needed.  Most of the time, when including headers
in the same module, doing #include "sound.h" should be sufficient, but when
including from another module, perhaps using the full <adonthell/audio/sound.h>
is a good idea.

Thoughts?

- Chris


_______________________________________________
Adonthell-devel mailing list
Adonthell-devel@nongnu.org
https://lists.nongnu.org/mailman/listinfo/adonthell-devel

Reply via email to