debian: package scripts improved to recover post-install failure. Regressions were introduced in d52fbee2c4d9, 5929d8292057.