Fixed usage of ${buildroot} instead of %{buildroot} which breaks rpmbuild.
Fix bug, which sets the 'DMAX' value of metric to 0 independent of the requested value.