Fix error reporting in case locale-gen fails on non-Ubuntu systems.