In the ebuild exim links and compiles against mysql when using ldap. Some mistake in parameters I think.
Grant, I defer to you, since you are more familiar with exim
I've never used exim, so I'm kicking it over to Jared.
Fix0red the sed commands in the if use mta-ldap section to NOT leave the -I/usr/include/mysql and -lmysqlclient and -lpq. Don't need these unless mta-mysql is in use. Made sure 3.34, 3.36, and 4.04 were all fixed.