It seems that newest mariadb change this script and add some PAM related setups. As Slackware doesn't have PAM at all we probably should patch this part of script and rebuild package.
As quick and dirty fix you can delete/hash those lines from mysql_install_db:
Code:
if test $? -ne 0
then
echo "Cannot change ownership of the '$pamtooldir/auth_pam_tool_dir' directory"
echo " to the '$user' user. Check that you have the necessary permissions and try again."
exit 1
fi
In my copy it begins at 471 line.