The reason CLDFLAGS is required is because the dmeventd plugins do not respect LDFLAGS. See "%.so" (around line 449) in make.tmpl.in. I think it would be okay to patch the Make template to also take LDFLAGS into account. Not sure what CLDFLAGS is used for, but it seems redundant to have the same contents in both. Can you try that?