'Set up the compile and runtime environments for a package.'

def setup_environment(self, spack_env, run_env):

    spack_env.set('GRAPHVIZ_ROOT', self.spec['graphviz'].prefix)
    spack_env.set('INSTALL_ROOT', self.prefix)
    run_env.prepend_path('LD_LIBRARY_PATH', join_path(self.prefix.lib64, '{0}'.format(self.spec['qt'].version.up_to(3))))
    run_env.prepend_path('CPATH', self.prefix.include.QtGraph)
