Fixed building with gcc 4.6.3. Fixes #3235.
Vendored libyaml 0.1.5 (again).
Added configure options for vendored libyaml.