Yes just don't install theme in the same directory, and don't runn them at the same time.
Or you could change the port one one set, but in my mind this would be a real pain example:
http://localhost:8080, you would also have to change the settings in the mysql mod of apache, and maybe in php.ini.
I would say if you really had to install both, use one at a time.