# Runs with the target root as the current directory (not chrooted).
# Rebuild the locale archive from /etc/locale.gen: the archive format belongs to the
# installed glibc, and a fresh system gets the default locale(s).
post_install() {
    sh ./usr/bin/locale-gen --root "$PWD" || echo "warning: locale-gen failed; run it again after fixing /etc/locale.gen" >&2
}

post_upgrade() {
    post_install
}
