As reported downstream at https://bugzilla.redhat.com/show_bug.cgi?id=1468084 , when building with MySQL / MariaDB support, libsnmptrapd should be linked against the database client library, otherwise it winds up with unresolved symbols which prevent some scripts from running correctly. I'm attaching a patch which adds MYSQL_LIBS
to the linker command for the library.
Agree with this solution.