commit: ac8830e5ca56ab4ba2a047220e5462024b32444d Author: Thomas Deutschmann <whissi <AT> gentoo <DOT> org> AuthorDate: Thu Dec 3 20:47:25 2020 +0000 Commit: Thomas Deutschmann <whissi <AT> gentoo <DOT> org> CommitDate: Thu Dec 3 20:48:16 2020 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ac8830e5
dev-lang/php: fix building against libressl Fixes ext/openssl/openssl.c:6501:8: error: ‘EVP_CIPH_OCB_MODE’ undeclared (first use in this function) when building against >=dev-libs/libressl-3.3. Closes: https://bugs.gentoo.org/757123 Package-Manager: Portage-3.0.10, Repoman-3.0.2 Signed-off-by: Thomas Deutschmann <whissi <AT> gentoo.org> dev-lang/php/files/php-7.4.13-issue80368.patch | 17 +++++++++++++++++ dev-lang/php/php-7.4.13.ebuild | 5 ++++- 2 files changed, 21 insertions(+), 1 deletion(-) diff --git a/dev-lang/php/files/php-7.4.13-issue80368.patch b/dev-lang/php/files/php-7.4.13-issue80368.patch new file mode 100644 index 00000000000..adad8f864ec --- /dev/null +++ b/dev-lang/php/files/php-7.4.13-issue80368.patch @@ -0,0 +1,17 @@ +https://github.com/php/php-src/commit/0f579fd7c8171cb0f7ecc8db912933df450f3861 +https://github.com/php/php-src/commit/ecee3f1209a7c0ac9f99c7f640b2f5df56656e58 + +--- a/ext/openssl/openssl.c ++++ b/ext/openssl/openssl.c +@@ -6496,7 +6496,9 @@ static void php_openssl_load_cipher_mode(struct php_openssl_cipher_mode *mode, c + int cipher_mode = EVP_CIPHER_mode(cipher_type); + memset(mode, 0, sizeof(struct php_openssl_cipher_mode)); + switch (cipher_mode) { +-#if PHP_OPENSSL_API_VERSION >= 0x10100 ++#ifdef EVP_CIPH_OCB_MODE ++ /* Since OpenSSL 1.1, all AEAD ciphers use a common framework. We check for ++ * EVP_CIPH_OCB_MODE, because LibreSSL does not support it. */ + case EVP_CIPH_GCM_MODE: + case EVP_CIPH_OCB_MODE: + case EVP_CIPH_CCM_MODE: + diff --git a/dev-lang/php/php-7.4.13.ebuild b/dev-lang/php/php-7.4.13.ebuild index 3ac0d8c9ace..97ccf43d8c7 100644 --- a/dev-lang/php/php-7.4.13.ebuild +++ b/dev-lang/php/php-7.4.13.ebuild @@ -150,7 +150,10 @@ BDEPEND="virtual/pkgconfig" PHP_MV="$(ver_cut 1)" -PATCHES=( "${FILESDIR}/php-iodbc-header-location.patch" ) +PATCHES=( + "${FILESDIR}"/php-iodbc-header-location.patch + "${FILESDIR}"/${P}-issue80368.patch +) php_install_ini() { local phpsapi="${1}"
