Writing modules

GNUsound provides a fairly flexible and powerful modular infrastructure. Modules are used for example to extend the file formats that GNUsound can read and write, to provide editing and selection tools and to provide audio processing plugins.

Module build environment

Currently, building a module requires access to the GNUsound source tree, to locate the necessary headers and to get the installation paths.

The best thing to do is to write a configure script which allows the user to specify the location of the GNUsound source code. This configure script should also create a file .MODULE_NAME.cflags containing the compiler and linker flags for the module. The module code itself should be placed in MODULE_NAME.c. Then you can use the GNUsound module Makefile to do the actual make: make -f path-to-GNUsound-source/modules/Makefile''.

The GNUsound module Makefile also provides suitable install and clean targets.

So, from the user's point of view, installing a module requires unpacking of the GNUsound source tree, running ./configure and make install. Then he should unpack the module source, run the module's ./configure script with the path of the GNUsound source code, and do a make followed by make install.

When the API is more stable, this procedure will be replaced by a -devel package which provides the necessary headers, m4 autoconf macros and pkg-config info.