Most of the documentation can be found in the FreeDict HOWTO at

	http://freedict.org/howto

The following lines may get you started on some requirements:

The "blessed" conversion process from .tei to DICT database format
is now based on XSLT stylesheets, an XSLT processor and dictfmt.
It is still possible to use xmltei2xmldict.pl though, but the DICT
compatibility may suffer.

xmltei2xmldict.pl requires:

- nsgmls from SP 1.3.4 from http://www.jclark.com/jade/
  or OpenSP from http://openjade.sourceforge.net/
- ESISParser.pm from libxml-perl-0.07, available via
	(su)
	perl -MCPAN -e shell
	install K/KM/KMACLEOD/libxml-perl-0.07.tar.gz
- TEI P4 DTDs, available from http://www.tei-c.org/Guidelines2/index.html
- make SGML_CATALOG_FILES point to the right location(s), e.g.
	export SGML_CATALOG_FILES="/usr/share/doc/packages/sp/\
html-xml/xml.soc:/var/lib/sgml/CATALOG.tei_4xml:/var/lib/sgml/\
CATALOG.iso_ent"
- Sablotron library and Perl module:
  http://www.gingerall.com/charlie/ga/xml/p_sab.xml


In order to build source release files (freedict-*-*-*.src.tar.bz2,
containing *-*.tei), run:

 cd tools
 mkdir -p ../../release/src
 make dist

In order to build binary release files (freedict-*-*-*.tar.bz2,
containing *-*.dict.dz and *-*.index), run:

 cd tools
 mkdir -p ../../release/dict-tbz2
 make release-dict-tbz2

In order to create eng-deu.{dict,index} from
freedict-eng-deu-0.3.src.tar.bz2, run:

 tar jxf freedict-eng-deu-0.3.src.tar.bz2
 cd eng-deu
 FREEDICTDIR=path/to/freedict make

where path/to/freedict should contain tools/Makefile.common.


Creating the Postgresql databases for Ergane Import
---------------------------------------------------

Unfortunately this is not automated, because it requires permissions
that the account for building FreeDict doesn't have.

> su
> sudo -u postgres createuser $USER
   superuser right - no
   create db right - yes
   create roles right - no
> exit
> createdb


Dependencies as Debian packages
-------------------------------

If you use Debian, you will need these packages (and some more):

   * perl
   * dictfmt
   * dbview
   * flex
   * svn
   * mdbtools
   * patch
   * postgresql or postgresql-8.1
   * tei (inofficial packet from FreeDict debian repository)
   * txt2pho (inofficial packet from FreeDict debian repository, non-free)
   * mbrdico (inofficial packet from FreeDict debian repository)

Also, teiaddphonetics requires XML::LibXML::Reader, which is not even
in libxml-libxml-perl in unstable, so you need to do as root:

	cpan XML::LibXML

hope this helps get you started :)

Michael Bunk, February 2007

