The current mtdev is not ABI stable, and the upcoming additions
to the kernel api will break ABI. This patch starts the process
of keeping binary compatibility with old programs, by moving the
abi-specific parts under a special flag, MTDEV_NO_LEGACY_API,
and makes sure the internal parts compiles with MTDEV_NO_LEGACY_API
set. This way, older programs will still work, old programs will
still compile, and new programs will be able to use the additions.

The test programs in the package are command-line utilities which can
be used to generate MT code mappings for header files, and debug
hardware problems, and should not be installed. With this patch, tests
are built unconditionally, but not installed.

The current MT slot protocol allows any tracking id outside the range
specified by the device to denote an unused slot. This is difficult to
handle in userspace, since the valid range is unknown. This patch
tightens the definition of a valid tracking id to always lie in the
range [0, MT_ID_MAX], and uses the value -1 to denote an unused slot.

Split the api into plumbing and porcelain layers and move the
plumbing part to its own optional header file.

The main usecase is to fetch events from the device, route them
through the converter and extract the processed events. To simplify
the API, replace the intermediate mtdev_pull() function by the
higher-level mtdev_get(). This function does all the required steps,
and has the same semantics as read().

The current semantics, that a non-empty conversion pipe means
the device is not idle, is not very useful. This patch changes
the semantics to simply checking if the fetch buffer is empty,
and if there are no events to fetch from the device.