Fill out the read API, fix a ton of bugs

Switch license from Apache to MIT; Apache license contains a bunch of
stuff I don't particularly care about for this lib.

Update README.md.

Add cmp_version function to return the version of the library.

const the data of the write_raw functions and the writer prototype; this
is both for safety and it allows writing string literals as raw data.

Change ctx_object_t.data to ctx_object_t.as; the struct definition makes
less sense, but in the code it's much clearer.

Add cmp_read_raw_length function to separate out reading the size of
upcoming raw data in the stream and reading the raw data itself; allows
for sensible checking and allocation.

Augment cmp_read_raw to use its "size_t *length" parameter as a
max_length; it then writes the actual length of the raw data to that
parameter.

Add functions for explicitly reading fixednums.

cmp_write_int should be cmp_write_sint; be explicit.