Debian Fixes

A few fixes for some bugs that I noticed, mostly specific to debian.