changes to makefile to use ps_*.sh commands, and bug fixes to ps_* scripts now that they've been tested