Add licensing stuff

OK, let's be done with it forever (hopefully).

Signed-off-by: Petr Tesarik <ptesarik@suse.cz>
Rename LICENSE to COPYING

This name used by GNU Autoconf.

Signed-off-by: Petr Tesarik <ptesarik@suse.cz>
Make a stub implementation

Write some API placeholders. Most importantly, this stub implementation
allows me to bootstrap autoconf/automake/libtool for the project.

Oh, well... here come the grand GNU utilities!

Signed-off-by: Petr Tesarik <ptesarik@suse.cz>
Add file-magic recognition to kdump_fdopen

Provide some infrastructure for handling multiple formats. Currently,
no format is implemented, still, but at least it is recognized.

Signed-off-by: Petr Tesarik <ptesarik@suse.cz>
Add kdump_format() to get the format description

Since kdump_ctx is an opaque type, a helper function is needed to access
the format field.

Signed-off-by: Petr Tesarik <ptesarik@suse.cz>
util: provide functions for struct new_utsname

This structure is needed to validate contents of some file formats.

Signed-off-by: Petr Tesarik <ptesarik@suse.cz>
Add endianity helper inline functions

These functions make it easy to read a value from the dump file,
ensuring correct endianity.

Signed-off-by: Petr Tesarik <ptesarik@suse.cz>
Add RLE decompression routine

RLE may be used for LKCD, but there is no library with the appropriate
function. Actually, this is not surprising, because the implementation
is trivial, so let's add one here.

Signed-off-by: Petr Tesarik <ptesarik@suse.cz>
Generic implementation of kdump_read()

Provide the interface between page-oriented raw access to dump file
and byte-oriented access by users.

Note that <unistd.h> is now needed to get the definition of ssize_t.

Signed-off-by: Petr Tesarik <ptesarik@suse.cz>
Support for LKCD dump file format

Adds support for reading LKCD dump files.

Signed-off-by: Petr Tesarik <ptesarik@suse.cz>
Support for diskdump core dump format

Add support for files produced by makedumpfile.

Signed-off-by: Petr Tesarik <ptesarik@suse.cz>