More 'use vars' cleanup

Move more package/global vars into our big block o'globals.  Hopefully
we can refactor these out soon (though I guess I should still think
about plugin compatibility...)