Use AC_SEARCH_LIBS to search for a library containing math functions

Even though the previous mechanism worked, this should be more
correct.
Support streamed wav files with a 0 bytes data chunk
Allow opening stdin when "-" is specified
Allow reading wav files with a 0 bytes RIFF chunk

This is required in order to read streamed wav files produced by
the libavformat wav muxer.
Use skip instead of fseek

fseek(SEEK_CUR) doesn't work for nonseekable streams (such
as pipes).

Only do this for skipping past small chunks; don't use it for
skipping past the actual data for non-streamed input.
Support reading sox style piped wav files

Sox writes the RIFF header size as a very large number, instead
of as 0 as in libavformat.
Add support for waveformatex files

This is used for multichannel wave files.
Extend GetInvInt to support values up to 54

For sample rates >= 64 kHz with short blocks, the largest sfb
width is 36, which after grouping can be multiplied with 3,
ending up as 108. GetInvInt needs to be able to support
the largest grouped sfb width, divided by two (3 * 36 / 2 = 54).

This fixes VBR encoding with sample rates >= 64 kHz.
Extend the GetInvInt table to 80 elements

This is a bug fix patch from Fraunhofer, amending/replacing/extending
the previous commit which only extended the table to 55 elements.
(In my previous fix, 55 seemed to be enough for the issue at hand at
least. A few of the coefficients had slightly different rounding than
what Fraunhofer had used though).

This will show up in AOSP in the next code drop as well.
Merge pull request #1 from mstorsjo/master

Syncing with upstream