Add the initial leo_in() implementation.

This commit adds a nearly complete leo_in() implementation, including
extensive comments for most added code.

Specifically, the following changes were made:
1. Add struct pattern to libleornian.h.

   This struct is used for creating a hierarchical pattern description
   engine.
2. Add patern_*alloc() and pattern_free() static functions.

   These functions are used by the pattern analysis routine for
   allocating and freeing struct pattern's.
3. Add pattern_learn().

   This function is the pattern analysis routine, used for finding and
   adapting patterns based on an input stream. Currently leo_in() calls
   this function so long as data is provided to the in() callback.
4. Add the struct pattern **init parameter to leo_in().

   This value is used by the caller for providing a pre-existing pattern
   hierarchy, and is continuously modified by pattern_learn() during
   pattern analysis.