I had the same problem, and this is what I did:
CTRL + Z
It then completed the test with the answer 'no' and continued the emerge. Not sure if this is an entirely safe thing to do or whether it's only sweeping the real problem under the carpet, but I'm damned if I'm going to waste another day compiling... The package was OpenSSH, by the way.
(Yep, I know this is an ancient thread. Just thought I'd help out other people who stumble across this page because it's the only meaningful result on Google!)