The same way you installed it on the old one.
You should have two installs with a Creative Suite installation. Either use the original media you used to install CS5 on the first computer or download your CS5 version here:
Warning: CS5 will not install or work correctly on the current operating systems for Mac or Windows. CS5 is considered end-of-life and will never be updated.