gpython: Fix pymain to properly setup sys.path
Pymain was not adding e.g. directory of executed file to sys.path, and as the result if there were e.g. 2 files dir/hello.py # imports world dir/world.py running `gpython dir/hello.py` would fail to import world. The case for interactive console was also failing to setup sys.argv as empty, so it was containing ['/path/to/gpython']. It was also, contrary to standard python, unconditionally showing '>>>' prompt even when stdin was not a tty. Fix all that and add a test to cover pymain functionality.
Showing with 81 additions and 4 deletions