Better compatibility with BSD

On systems lacking ```md5sum``` now automatically looks for ```md5```and finally ```openssl dgst -md5``` to calculate checksums.

On systems lacking ```wget``` the downloads are made with ```curl``` instead.