add -lm on UNIX systems

This fixes a Debian packaging issue.