****************************
Information for Distributors
****************************

The information given here is intended for people distributing pygsl as
well as for people who are not afraid to run code generation tools in
case pygsl generates trouble.

Preferable array module
-----------------------

The only array module supported is numpy.

Wrapper generated modules
-------------------------

The following modules are generated by the SWIG wrappers:

*  _block
*  _callback
*  gslwrap
*  hankel
*  _poly

In case on of these modules shows a compilation error, just delete the
corresponding file in the swig\_src directory (e.g.
swig\_src/poly\_wrap.c if for the poly module.). Set the variable
``USE_SWIG`` to ``1`` in the ``setup.py`` file. Run the build process
again. Now setup.py should call swig and rebuild the module wrappers.

Dedicated wrappers
------------------

Some modules come with their own wrapping tools which are implemented in
python.

The const module
~~~~~~~~~~~~~~~~

Change into the src directory. Define the shell variable
``PYGSL_GSLCVS`` variable, so that it either points to the GSL CVS
repository or to the include directory of your GSL installation
(typically /usr/include on a linux installation). Then type
``python ../tools/constants_tool.py`` This will generate the files
``const_m_array.c``, ``const_num_array.c``, ``const_cgsm_array.c``
and  ``const_mksa_array.c``.

The special function module
~~~~~~~~~~~~~~~~~~~~~~~~~~~

PyGSL comes with one implementations for the special functions, which
is currently found intesting.sf module. 


Generating the wrapper has not been automatized yet. First swig is used
to parse the header files and dump them into xml and then a specialized
wrapper reads this tree and writes the wrappers.

First generate the wrapper by executing in the shell

.. code-block:: bash

    python setup.py gsl_wrappers

Then run the build process. Set ``BUILD_TESTING = 1`` in the setup.py
file. If required update the time stamp of the file
``testing/src/sf/sfmodule_testing.c``. This will build the module
``_ufuncs``.

The functions not wrapped automatically are defined in the file 
``sf.i``
