The version of elektra is handeled with the kdb.\+h macros K\+D\+B\+\_\+\+V\+E\+R\+S\+I\+O\+N which is a string and K\+D\+B\+\_\+\+V\+E\+R\+S\+I\+O\+N\+\_\+\+M\+A\+J\+O\+R, K\+D\+B\+\_\+\+V\+E\+R\+S\+I\+O\+N\+\_\+\+M\+I\+N\+O\+R and K\+D\+B\+\_\+\+V\+E\+R\+S\+I\+O\+N\+\_\+\+M\+I\+C\+R\+O which are numbers. They represent the public announced version information.

The same information can be retrieved at runtime using system/elektra/version/constants/\+K\+D\+B\+\_\+\+V\+E\+R\+S\+I\+O\+N system/elektra/version/constants/\+K\+D\+B\+\_\+\+V\+E\+R\+S\+I\+O\+N\+\_\+\+M\+A\+J\+O\+R system/elektra/version/constants/\+K\+D\+B\+\_\+\+V\+E\+R\+S\+I\+O\+N\+\_\+\+M\+I\+C\+R\+O system/elektra/version/constants/\+K\+D\+B\+\_\+\+V\+E\+R\+S\+I\+O\+N\+\_\+\+M\+I\+N\+O\+R

K\+D\+B\+\_\+\+V\+E\+R\+S\+I\+O\+N

This is the A\+P\+I to programs using elektra. Its interface is defined in src/include/kdb.\+h. Both applications and plugins use this A\+P\+I.

Additionally there is also a very small A\+P\+I to plugins. It consists of only 5 functions and is described in src/plugins/doc/doc.\+c.

\subsection*{Compatibility}

This document describes under which circumstances A\+P\+I and A\+B\+I incompatiblities may occur. As developer from elektra your mission is to avoid that. The tool icheck against the interfaces mentioned above may help you too.

In 0.\+8.$\ast$ the A\+P\+I and A\+B\+I must be always forward-\/compatible, but not backwards-\/compatible. That means that a program written and compiled against 0.\+8.\+0 compiles and links against 0.\+8.\+1. But because it is not necessarily backendwards-\/compatible a program written for 0.\+8.\+1 may not link or compile against elektra 0.\+8.\+0 (but it may do when you use the compatible subset, maybe with \#ifdefs).

Following points are allowed\+: When you add a new function you break A\+B\+I and A\+P\+I backward-\/ compatibility, but not forward, so you are allowed to do so.

In the signature you are only allowed to add const to any parameter. You are {\itshape not} allowed to use subtypes to the objects, in C means you are not allowed to call any functions of an object which appear new. C does {\itshape not} typecheck that, it's your responsibility.

What C also does not check are the pre and postconditions. That means you are not allowed to demand more client code (e.\+g. first accept a N\+U\+L\+L pointer and in the next version you crash on it) and you are not allowed to return values that the previous version did not return. It is a complex topic, so better don't underestimate it, but generally said the methods should behave on the same data the same way.

References\+: \href{http://tldp.org/HOWTO/Program-Library-HOWTO/shared-libraries.html}{\tt http\+://tldp.\+org/\+H\+O\+W\+T\+O/\+Program-\/\+Library-\/\+H\+O\+W\+T\+O/shared-\/libraries.\+html} \href{http://packages.debian.org/de/sid/icheck}{\tt http\+://packages.\+debian.\+org/de/sid/icheck}

\subsection*{Increment}

This document describes how to increment the K\+D\+B\+\_\+\+V\+E\+R\+S\+I\+O\+N. K\+D\+B\+\_\+\+V\+E\+R\+S\+I\+O\+N consists of a triplet integer current\+:revision\+:age.

Revision is something which will always incremented when there is a new bugfix release.

current and age will be incremented by one when you release a compatible but changed A\+P\+I. Revision is set back to zero then.

Note\+: All 3 Versioning infos are handled separately!

\href{http://www.gnu.org/software/libtool/manual/libtool.html#Versioning}{\tt http\+://www.\+gnu.\+org/software/libtool/manual/libtool.\+html\#\+Versioning}

T\+O\+D\+O write about S\+O\+\_\+\+V\+E\+R\+S\+I\+O\+N 