Reorganize to support multiple entry point tools and make tests work.

The original motivation here was to keep the source file containing main()
out of OBJ_FILES so that we can link the tests to OBJ_FILES and not
get a duplicate definition. However, a nice side-effect of this
reorganization is that it allows for generating multiple tools so that
later there can be other tools like a test runner, or a lexer-only tool.
Make the scanner actually support indentation-based blocks properly.

The prototype implementation in the previous commit was unable to handle
cases where more than one block is closed at once, or where the file ends
with an indented block still open.