Instead of using a define and conditional building of sha1.c parts, move the PBKDF2 implementation into a separate file.