Compiling and Packaging
-----------------------
Elektra is such a simple software, that you'll probably wont need it to
recompile from source. Use the binary RPM from the main repository. It should
work for any RPM based distribution.

If you still wants to compile it, avoid using the tarball. It is an obsolete
method of compiling. Use the source RPM instead.

Download it from the main repository as elektra-*.src.rpm and rebuild the RPMs:

  $ rpm --rebuild elektra-*.src.rpm

This will generate RPMs in your packages directory ready to be installed.

It was reported that the Makefiles will only work with gmake, which makes
absolutelly no difference for Linux, but is a crucial information when
building on BSD.



Note for Packagers
------------------
Elektra is divided in 2 packages: "elektra" and "elektra-devel".

The "elektra" package sugested files:
   /bin/kdb
   /etc/profile.d/elektraenv.sh
   /lib/libkdb.so
   /lib/libregistry.so   (backwards compatibility: will be removed in future)
   /usr/share/doc/elektra
   /usr/share/doc/elektra/fstab-convert
   /usr/share/doc/elektra/hosts-convert
   /usr/share/doc/elektra/hwconfKudzu-convert
   /usr/share/doc/elektra/inittab-convert
   /usr/share/doc/elektra/network-convert
   /usr/share/doc/elektra/users-convert
   /usr/share/doc/elektra/xfree-convert
   /usr/share/man/man1/kdb.1.gz
   /usr/share/man/man5/elektra.5.gz
   /usr/share/man/man7/elektra.7.gz
   /usr/share/sgml/elektra-0.1.0
   /usr/share/sgml/elektra-0.1.0/catalog
   /usr/share/sgml/elektra-0.1.0/elektra.dtd


The "elektra-devel" package sugested files:
   /usr/include/kdb.h
   /usr/lib/libkdb.a
   /usr/share/doc/elektra-devel
   /usr/share/doc/elektra-devel/elektra-api/*  (Doxygen API documentation)
   /usr/share/doc/elektra-devel/example.c
   /usr/share/doc/elektra-devel/kdb.c
   /usr/share/man/man3/kdb*.3.gz       (Manpages for the kdb*() methods)
   /usr/share/man/man3/key*.3.gz       (Manpages for the key*() methods)
   /usr/share/man/man3/ks*.3.gz        (Manpages for the ks*() methods)

   
   
Usually you should build it like this:

   bash$ gmake all
   bash$ gmake DESTDIR=/some/fake/system/root install

For more info, please use the elektra.spec file as a reference.



License
-------
Since version 0.4.1, Elektra must be distributed under a BSD license.
Before that, Elektra was LGPL.



About Man Pages
---------------
Some man pages are generated from a DocBook XML using XSLTs from the
docbook-style-xsl package (on Fedora), and the xsltproc as the XSLT engine.
So rg.1.xml docbook source is converted to the rg.1 man page, for example.

This caused several problems when compiling them in other distros, because of
the lack of these tools.

Since version 0.2.7, the compiled man pages are included in the tarball. So
unless you 'make clean' globally, you'll be able to 'make; make install'
globaly even without these tools.




Makefile
--------
You can issue the following subcomands to make:

- make or make all
  Make everything, from compiling code to creating man pages.

- make install
  Installs everything under / or under what is defined in DESTDIR.
  Possible use: make DESTDIR=/some/parent/folder install

- make clean
  Clean everything that is not the original pure code.

- make commit
  To commit changes to the Subversion repository.

- make vtag
  Creates a version tag in the Subversion repository.

- make dist
  Generates the tarball in parent directory, using VERSION file.

- make rpm
  Makes tarball, compiles and generate Elektra RPMs

- make deb
  Makes tarball, compiles and generate Elektra Debian .debs


Under the doc/ folder, you can make:

- make or make all or make man
  Create the man files and doxygen

- make doxygen
  Create doxygen API documentation and API man files

- make man
  Create man files, doxygen and xsltproc

- make clean
  Removes everything that was generated

- make install
  Installs everything using ${DESTDIR} as root directory

- make html
  To create the HTML files for the elektra.sf.net website

- make pub
  Publish all documentation to elektra.sf.net

- make pubh
  Publish only HTML files. No doxygen, no images.

- make pubi
  Publish only image files

