 $Id: INSTALL 47 2007-06-13 10:17:28Z dezperado $

Summary:

====== BUILDING FROM SVN
====== BUILDING FROM A COMPRESSED ARCHIVE
====== INSTALLATION
====== INSTALLATION BUG REPORTING
====== FRAMEBUFFER PROBLEMS
====== DEPENDENCIES
====== DEPENDENCIES : example on Gentoo
====== TODO

====== BUILDING FROM SVN

If you happen to have downloaed fim from the svn archive, 
run the ./autogen.sh script.
However, this require you to have the automake, autoconf, and 
aclocal programs. If you don't have these, the ./autogen.sh 
script won't work.

The ./autogen.sh script will create a ./configure script, which
will generate a Makefile file, which finally will permit you to 
build the fim executable and install it.

====== BUILDING FROM A COMPRESSED ARCHIVE

To build fim, you should first unpack the .tgz archive.
Say you have just downloaded fim.tgz from the Internet.
So:

tar xvzf fim.tgz
cd fim/
./configure --help=short
./configure
make

Typing ./configure will run the configure script, which will test
your machine for potential problems regarding the build and 
installation of Fim.

The configure script will build the Makefile file, which is essential to build 
fim.
If the configure script terminates with an error, please contact the author of
fim giving him the generated config.log file and any useful information  to 
spot the problem.

Please see the BUGS file for bugs reporting.

====== INSTALLATION

To build Fim, type 'make' in its source directory, once expanded the archive
and having run the ./configure script before.

Then use 'make install' as root :

# su 
Password:
# make install
checking for libdir name ... lib
install -d /usr/local/bin
install -s fim /usr/local/bin
install ./src/fimgs.sh /usr/local/bin/fimgs
install -d /usr/local/share/man/man1
install -m 644 doc/fim.man /usr/local/share/man/man1/fim.1
install -d /usr/local/share/doc/fim
install -m 644 doc/FIM.TXT /usr/local/share/doc/fim/
install -m 644 doc/FIM.html /usr/local/share/doc/fim/

or

# su -c 'make install'
Password:
checking for libdir name ... lib
install -d /usr/local/bin
install -s fim /usr/local/bin
...

to install the fim executable, the fim wrapper script (fimgs), the fim man page,
and documentation in the dedicated directories in /usr/local.

====== INSTALLATION BUG REPORTING

If something goes wrong, please email me the output of 'make report', or the .tgz
file resulting from the following statement execution:

 ( make;make report ) | gzip  > fim.`date +%Y%m%d%H%M`.log.gz

Have fun!
p.s.: please see the BUGS file for bug reporting!

====== FRAMEBUFFER PROBLEMS

p.s.: if you do not even know if you have the framebuffer or it is correctly configured,
there is a section of the doc/FIM.TXT file dedicated to this, and the same information in
the man page.

Consider reading it!

====== DEPENDENCIES

p.p.s.: consider that to build Fim, you need the following programs installed:

 flex	(the lexer generator)
 bison	(the parser generator)
 gcc	(the C compiler)
 g++	(the C++ compiler)

and some libraries, like libjpg, libpng, libgif, libtiff, libreadline.

All of these programs are probably already on your system, and if not, your system will
 probably give a way to install them (apt-get on debian, emerge on gentoo.. ).

====== DEPENDENCIES : example on Gentoo

On a Gentoo system, you should resolve dependencies running as root:

# emerge media-libs/libpng media-libs/jpeg media-libs/tiff media-libs/giflib sys-libs/readline

And install the essential developer tools flex and bison:

# emerge sys-devel/flex sys-devel/bison

====== TODO

A gift in form of a well written gentoo/debian/other distribution dependency file
would be much appreciated.

Suggestions are welcome, too!
