Bug 267672

Summary: databases/mysql80-client: Fails to build with LibreSSL: my_kdf.cc:104:30: error: use of undeclared identifier 'EVP_PKEY_HKDF'
Product: Ports & Packages Reporter: Dave Hayes <dave>
Component: Individual Port(s)Assignee: Jochen Neumeister <joneum>
Status: Closed FIXED    
Severity: Affects Some People CC: brnrd, joneum
Priority: --- Keywords: needs-qa
Version: LatestFlags: bugzilla: maintainer-feedback? (joneum)
koobs: maintainer-feedback? (brnrd)
koobs: merge-quarterly?
Hardware: Any   
OS: Any   

Description Dave Hayes 2022-11-09 23:11:45 UTC
Building off of the latest ports head (as of 11/9/22), this failure looks like a simple LibreSSL fix:

cd /wrkdirs/usr/ports/databases/mysql80-client/work/.build/mysys && /usr/local/libexec/ccache/c++ -DHAVE_CONFIG_H -DLZ4_DISABLE_DEPRECATE_WARNINGS -DRAPIDJSON_NO_SIZETYPEDEFINE -DRAPIDJSON_SCHEMA_USE_INTERNALREGEX=0 -DRAPIDJSON_SCHEMA_USE_STDREGEX=1 -D_USE_MATH_DEFINES -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/wrkdirs/usr/ports/databases/mysql80-client/work/.build -I/wrkdirs/usr/ports/databases/mysql80-client/work/.build/include -I/wrkdirs/usr/ports/databases/mysql80-client/work/mysql-8.0.31 -I/wrkdirs/usr/ports/databases/mysql80-client/work/mysql-8.0.31/include -isystem /wrkdirs/usr/ports/databases/mysql80-client/work/mysql-8.0.31/extra/rapidjson/include -isystem /wrkdirs/usr/ports/databases/mysql80-client/work/.build/extra/zlib/zlib-1.2.12 -isystem /wrkdirs/usr/ports/databases/mysql80-client/work/mysql-8.0.31/extra/zlib/zlib-1.2.12 -isystem /usr/local/include/editline -std=c++17 -fno-omit-frame-pointer -ftls-model=initial-exec -O2 -pipe  -fPIC -DNDEBUG -malign-double -fstack-protector-strong -DLDAP_DEPRECATED -isystem /usr/local/include -fno-strict-aliasing   -isystem /usr/local/include -std=c++17 -Wall -Wextra -Wformat-security -Wvla -Wundef -Wmissing-format-attribute -Woverloaded-virtual -Wcast-qual -Wno-null-conversion -Wno-unused-private-field -Wconditional-uninitialized -Wdeprecated -Wextra-semi -Wheader-hygiene -Wnon-virtual-dtor -Wundefined-reinterpret-cast -Winconsistent-missing-destructor-override -Winconsistent-missing-override -Wshadow-field -ffunction-sections -fdata-sections -O2 -pipe  -fPIC -DNDEBUG -malign-double -fstack-protector-strong -DLDAP_DEPRECATED -isystem /usr/local/include -fno-strict-aliasing   -isystem /usr/local/include -std=c++17  -DNDEBUG -fPIC -Wshadow-uncaptured-local -MD -MT mysys/CMakeFiles/mysys_objlib.dir/kqueue_timers.cc.o -MF CMakeFiles/mysys_objlib.dir/kqueue_timers.cc.o.d -o CMakeFiles/mysys_objlib.dir/kqueue_timers.cc.o -c /wrkdirs/usr/ports/databases/mysql80-client/work/mysql-8.0.31/mysys/kqueue_timers.cc
--- mysys/CMakeFiles/mysys_objlib.dir/my_kdf.cc.o ---
/wrkdirs/usr/ports/databases/mysql80-client/work/mysql-8.0.31/mysys/my_kdf.cc:104:30: error: use of undeclared identifier 'EVP_PKEY_HKDF'
  pctx = EVP_PKEY_CTX_new_id(EVP_PKEY_HKDF, NULL);
                             ^
1 error generated.
*** [mysys/CMakeFiles/mysys_objlib.dir/my_kdf.cc.o] Error code 1
Comment 1 commit-hook freebsd_committer freebsd_triage 2022-12-13 17:46:40 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=613e9baa1d1bebe6d4b6ed2a57d2e696c256cc65

commit 613e9baa1d1bebe6d4b6ed2a57d2e696c256cc65
Author:     Felix Palmen <zirias@FreeBSD.org>
AuthorDate: 2022-12-11 13:50:47 +0000
Commit:     Felix Palmen <zirias@FreeBSD.org>
CommitDate: 2022-12-13 17:45:30 +0000

    databases/mysql80-server: Fix build with libressl

    PR:                     267672
    Approved by:            joneum (maintainer), tcberner (mentor)
    Differential Revision:  https://reviews.freebsd.org/D37673

 .../files/patch-mysys_my__kdf.cc (new)               | 20 ++++++++++++++++++++
 ...ter_src_harness_src_tls__server__context.cc (new) | 12 ++++++++++++
 2 files changed, 32 insertions(+)