libcrypto.so.1 is needed by imap-2000-9
libssl.so.1 is needed by imap-2000-9
Well then the problem is that imap cannot find these libraries. I am quite sure that these files are part of the openssl package.
You may need to pass flags to your configure script to help it find these libraries. Type in ...
so you can see what the exact syntax needed will be. it might be something like ...
but you will have to check it out to be sure.