[RFC] refactor includes + improve testing infrastructure

This will allows testing of more files and allow PR #904 to proceed.

Implements a tiny part of issue #918 in the process as well.
Also, as mentioned in the comments below, this would inhibit compiling on windows: [windows is LLP64](http://stackoverflow.com/questions/384502/what-is-the-bit-size-of-long-on-64-bit-windows). So I'm not really sure why the "Make sure long_u is big enough to hold a pointer." is there.