Autodetect openssl cms for libressl compatibility

Since cms support is now determined by autoconf, it will work as
expected if openssl ever drops cms support or libressl ever adds it.