Improve ossl_cmp_build_cert_chain(); publish it as X509_build_chain()