Refactor exceptions in build_file.py and build_file_parser.py to derive   from a common baseclass and eliminate throwing IOError. Catch errors from parse errors in the BUILD file and format   context around the exception.

Followon to https://rbcommons.com/s/twitter/r/929/

Refactor exceptions in build_file.py and build_file_parser.py to derive from a common baseclass and eliminate throwing IOError.

Revive error message that prints out alternatives to an incorrect build target.

Also, Catch exceptions from parse errors in the BUILD file and print some formatted context around the line of the file that failed.

Exception message: Error parsing /Users/zundel/Src/Pants/examples/src/java/com/pants/examples/hello/greet/BUILD:
    4: java_library(name = 'greet',
    5:   dependencies = [], # A more realistic example would depend on other libs,
    6:                      # but this "hello world" is pretty simple.
*   7:   sources = globs('*.java' && foo),
                                   ^ SyntaxError: invalid syntax (<string>, line 7)

    8:   provides = artifact(org='com.pants.examples',
    9:                     name='hello-greet',
   10:                     repo='build-support/ivy:public',),
   11: )

Testing Done:
ci passed at https://travis-ci.org/pantsbuild/pants/builds/33756154

Bugs closed: 537

Reviewed at https://rbcommons.com/s/twitter/r/954/