			How to install AdaBill
			======================

0. Short description of the install-process
===========================================

I recommend reading the whole file, but if you know what you're doing,
this may be enough:

1. create database firma
2. psql firma < firma.sql
3. cd src
4. edit sql.ads: set dbuser, password
4. make install

1. Before you start
===================

Well, it's a little bit difficult at the moment.

First, make sure you have the following set up properly:

	Ada95	(gcc-3.1 or later, perhaps gnat-3.13p; gnat-3.14p won't work)
	GtkAda	(Adabill >=0.0.9 requires GtkAda-2.0 or later)

It is recommended to have the PostgreSQL-headerfiles and
libpq (compiled with PostgreSQL). You may need to change the location
of these files in pg2_interface.c and pg2-interface.ads.

If you have a suitable PostgreSQL-Installation you can remove the
file src/pg2_interface.o shipped with AdaBill. I pre-compiled it
in order to reduce the possible PostgreSQL-conflicts (e.g. missing
header-files). pg2_interface.o was created on x86-ELF-Linux with
glibc-2.2 and gcc 2.8.1 without any CPU-specific optimization. It should
work on 80386 or better.



2. The Build-Process
====================

If you've read the comments above you can try to compile AdaBill:

	cd src

IMPORTANT: Edit sql.ads and change the db-user from adi to your
account. Then, just type

	make

Afterwards,

	make install

does the rest for you.



3. Setting up PostgreSQL
========================

It is very easy to set up the requirements for PostgreSQL.

	1. Create a database (or use an existing one)

recommended example: CREATE DATABASE firma;

	2. Create the content via firma.sql

either use: psql < firma.sql firma	(or similar)

or from within psql: \i firma.sql


You may create corresponding users and -groups for accessing the
company's data. Think about the Web-Interface-user (or modify the
scripts to authenticate with user-provided login:passwords)
I'll change to this behavior in one of the next versions.

Copy adabill/latex/* to a suitable location, i.e. 
/usr/share/texmf/tex/latex/adabill/ (or /usr/local/lib/texmf, if working)
and run texhash afterwards.
Edit the files to your needs.

That's it. Good luck. Feel free to contact me if you have trouble.
And don't forget to read the other files.



Adrian Knoth <adi@thur.de>

2004-03-22	(22.03.2004)

