Exif shared library for Atari (MiNT/MagiC)
=================================================

This is an attempt to make LibExif available as a shared libary for Atari.

The goal here was to make it as easy as possible to switch from linking a
static version, to use the shared version instead. Remember though that
neither the OS nor the compilers in use have direct support for that,
and that the application needs to support it.


How to use it:
==============

for GCC:
Install the header files from the include directory to /usr/include (or
to your cross installation directory), the libraries to /usr/lib, and
the executables from /mint/slb to a directory where Slbopen can find them
(usually also /mint/slb, or c:/gemsys/slb)

In your application:
- Define -DEXIF_SLB before including exif_data.h, or include slb/exif.h instead
  (both should have the same effect)
- add a call to slb_exif_open() before using any function from libexif. Optionally,
  you can pass in a library search path that is passed along to Slbopen().
- for completeness, you can also add a call to slb_exif_close() before your
  application terminates.
- link to libexif.slb.a instead of the normal libexif.a
- use any function from LibExif as usual. No need to pass any extra parameters.

For Pure-C:
Currently not finished.

That's all!

Note that slb_exif_open() contains fallback code for systems lacking Slbopen(),
so this should work even on SingleTOS.



Files in the archive:
=====================

usr/include/libexif/*.h
    Slightly modified versions from the files of the libexif distribution,
    intended to be usable for both static and shared linking.
usr/include/slb/exif.h
    Include file for using the shared library, with declarations of the above
    mentioned functions.
usr/lib/libexif.a
    Static version of the library
usr/lib/libexif.slb.a
    Import library for using the shared library instead
usr/lib/m68020-60/libexif.a
    Static version of the library, compiled for 68020 or better
usr/lib/m68020-60/libexif.slb.a
    Import library for using the shared library instead,
    compiled for 68020 or better
usr/lib/m5475/libexif.a
    Static version of the library, compiled for coldfire
usr/lib/m5475/libexif.slb.a
    Import library for using the shared library instead,
    compiled for coldfire
usr/bin/*
    
    The command tool exif from the original distribution,
    recompiled for using the shared library instead.

mint/slb
    The shared library itself. Use the one appropiate for your system.


Exported functions:
===================

#0: long exif_slb_control(long fn, void *arg)
    - used internally by slb_exif_open() to check that
      the correct version of the library was loaded

everything else:
    - all functions publicitly available from exif_*.h.
      Consult that header file(s), or the documentation
      in the original archive on how to use them.


Known bugs:
===========

- Although the handle of the shared library and its corresponding exec
  function are available to the application, the exec function
  should not be directly called. Always use the import functions
  (they cover all available functions, anyway).

- When using the library with Pure-C, you may have to change some variables
  from plain "int" to "exif_int_t". This is because the library was
  compiled by gcc, and sizeof(int) differs between the two.
