Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing locales on Arch Linux guest #1492

Open
AshkanArabim opened this issue May 18, 2024 · 3 comments
Open

Missing locales on Arch Linux guest #1492

AshkanArabim opened this issue May 18, 2024 · 3 comments
Labels
1. Bug Something isn't working

Comments

@AshkanArabim
Copy link

Describe the bug
I have a clean installation of the Arch Linux guest (with an Arch Linux host) that I've installed using toolbox create gnome (I plan to use it for some Gnome development). When I enter the machine to install the fa_IR locale by uncommenting it from /etc/locale.gen and running sudo locale-gen, I get this message:

[ashkan@toolbox gnome-clocks-new]$ sudo locale-gen
Generating locales...
  en_US.UTF-8... done
  fa_IR.UTF-8...[error] cannot open locale definition file `fa_IR': No such file or directory

I assume this is related to the fact that fa_IR isn't listed when I run ls /usr/share/i18n/locales/. There are many locales missing here when I compare it to my host OS.

Steps how to reproduce the behaviour

  1. Get an Arch Linux host and install toolbox. (or manually create the Arch container in the next step using the --distro flag)
  2. Create a container: toolbox create <name> and enter it with toolbox enter <name>
  3. Uncomment the line with fa_IR in /etc/locale.gen and save.
  4. Run sudo locale-gen

Expected behaviour
For sudo locale-gen to successfully generate the Persian locale; with an output like this:

Generating locales...
  en_US.UTF-8... done
  fa_IR.UTF-8... done
Generation complete.

Actual behaviour
It fails to generate the Persian locale (fa_IR).

Screenshots
N/A

Output of toolbox --version (v0.0.90+)
toolbox version 0.0.99.5

Toolbx package info (rpm -q toolbox)

$ pacman -Qi toolbox
Name            : toolbox
Version         : 0.0.99.5-1
Description     : Unprivileged development environment
Architecture    : x86_64
URL             : https://github.com/containers/toolbox
Licenses        : APACHE
Groups          : None
Provides        : None
Depends On      : podman  bash  flatpak
Optional Deps   : None
Required By     : None
Optional For    : None
Conflicts With  : None
Replaces        : None
Installed Size  : 7.23 MiB
Packager        : Morten Linderud <foxboron@archlinux.org>
Build Date      : Fri 22 Dec 2023 15:09:25 MST
Install Date    : Fri 17 May 2024 09:02:27 MDT
Install Reason  : Explicitly installed
Install Script  : No
Validated By    : Signature

Output of podman version
e.g.,

Client:       Podman Engine
Version:      5.0.3
API Version:  5.0.3
Go Version:   go1.22.3
Git Commit:   d08315df35cb6e95f65bf3935f529295c6e54742-dirty
Built:        Mon May 13 04:25:15 2024
OS/Arch:      linux/amd64

Podman package info (rpm -q podman)

Name            : podman
Version         : 5.0.3-1
Description     : Tool and library for running OCI-based containers in pods
Architecture    : x86_64
URL             : https://github.com/containers/podman
Licenses        : Apache-2.0
Groups          : None
Provides        : None
Depends On      : catatonit  conmon  containers-common  crun  gcc-libs  glibc  iptables  device-mapper  libdevmapper.so=1.02-64  gpgme  libgpgme.so=11-64  libseccomp  libseccomp.so=2-64  passt
Optional Deps   : apparmor: for AppArmor support [installed]
                  btrfs-progs: support btrfs backend devices [installed]
                  cni-plugins: for an alternative container-network-stack implementation
                  fuse-overlayfs: for storage driver in rootless environment [installed]
                  slirp4netns: for alternative rootless network support [installed]
                  podman-compose: for docker-compose compatibility
                  podman-docker: for Docker-compatible CLI
Required By     : toolbox
Optional For    : None
Conflicts With  : None
Replaces        : None
Installed Size  : 76.95 MiB
Packager        : David Runge <dvzrv@archlinux.org>
Build Date      : Mon 13 May 2024 04:25:15 MDT
Install Date    : Mon 13 May 2024 21:27:31 MDT
Install Reason  : Explicitly installed
Install Script  : No
Validated By    : Signature

Info about your OS
Arch Linux

Additional context
N/A

@AshkanArabim AshkanArabim added the 1. Bug Something isn't working label May 18, 2024
@AshkanArabim
Copy link
Author

AshkanArabim commented May 19, 2024

A fix for this is to either copy the locale files you need from the host's /usr/share/i18n/locales or to download them from the GNU C library repo.

But I feel like stuff like this should have been included out of the box?

@Docmine17
Copy link

I fixed this by commenting '#' out a few lines of "NoExtract" locale in /etc/pacman.conf then reinstalling glibc and running locale-gen

@ullebe1
Copy link

ullebe1 commented Jun 5, 2024

I fixed this by commenting '#' out a few lines of "NoExtract" locale in /etc/pacman.conf then reinstalling glibc and running locale-gen

Same here, commenting out NoExtract = usr/share/locale/* usr/share/X11/locale/* usr/share/i18n/* seems to have fixed it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1. Bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants