Update `spack setup` and `spack graph` to be consistent with recent refactoring (#2317)
* Update `spack setup` and `spack graph` to be consistent with c557e765 and 9347f869. Fixes #2316.
* Added another "fix" necessary to make `spack setup` work.
* Added another "fix" necessary to make `spack setup` work. (reverted from commit 7f0d3ecb38c97ec00491d7cd66b4266e3018b1ca)