struct timeval on DragonFly. Use BSD_INSTALL_PROGRAM, removing the unportable -r flag at the same time. Fix build with newer OpenSSL versions by including openssl/sha.h explicitly.