just remove all those lines and use distutils_install_for_testing(). It does all the installation into $T.
http://devmanual.gentoo.org/eclass-reference/distutils-r1.eclass/index.html