Fix RPM and Debian packaging problems