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

C.UTF-8 locale missing #2340

Closed
alecmev opened this issue Nov 27, 2017 · 12 comments
Closed

C.UTF-8 locale missing #2340

alecmev opened this issue Nov 27, 2017 · 12 comments

Comments

@alecmev
Copy link

alecmev commented Nov 27, 2017

  • electron-builder version: 19.46.9
  • electron-updater version: 2.16.1
  • Target: Linux (Arch)

I'm unable to use electron-builder on Arch Linux, since there's no C.UTF-8 locale on it. The last working version is 19.45.5, AFAIK ([email protected]). The commit that added C.UTF-8 as the default locale for Linux.

@phuze
Copy link

phuze commented Nov 28, 2017

There was a time when C.UTF-8 was a Debian specific locale, but that was included in RHEL in 2015. @jeremejevs What flavour of Linux are you using? Edit: Oh, Arch Linux. I completely overlooked that :)

@alecmev
Copy link
Author

alecmev commented Nov 28, 2017

@purplekrayons I'm using Arch. C.UTF-8 is nice, but it isn't in glibc yet (relevant thread), so there at least must be some sort of a fallback when it isn't available or something like that.

@phuze
Copy link

phuze commented Nov 28, 2017

As far as I know, there is no way to determine what locales are available using JavaScript (or TypeScript). It looks like that change was implemented to address a broader range of locale issues. You may be in a tricky spot from where im standing. It seems like there are no immediate plans to include C.UTF-8 in glibc. The common consensus appears to be to leave it up to the various distro's to include. For the time being I would just manually revert the change you linked to permit building in Arch Linux. Perhaps @develar can provide further insight and offer a better suggestion.

@develar
Copy link
Member

develar commented Nov 28, 2017

We need some locale for snapcraft, nsis, perl and some other tools.

Previously was en_US.UTF-8, but C.UTF-8 locale doesn't require any locale files. So, we don't need to use localegen, we can run electron-builder on alpine linux and coreos without any additional work.

My assumption was is that C.UTF-8 is supported on any Linux. I will add check for Arch Linux.

@alecmev
Copy link
Author

alecmev commented Nov 28, 2017

This isn't limited to Arch, e.g. NixOS doesn't have C.UTF-8 either: NixOS/nixpkgs#20192

@develar
Copy link
Member

develar commented Nov 28, 2017

@jeremejevs Please send me output of env command to [email protected] (or share here if not private).

@alecmev
Copy link
Author

alecmev commented Nov 28, 2017

@develar Sure:

LANG=en_US.UTF-8

Carefully sanitized 😄 What are you looking for? I can mail you the whole output, but there's nothing else of relevance there.

@develar
Copy link
Member

develar commented Nov 28, 2017

@jeremejevs LC_CTYPE and LC_ALL?

@alecmev
Copy link
Author

alecmev commented Nov 28, 2017

@develar They aren't in my env.

Here's the output of locale though:

LANG=en_US.UTF-8
LC_CTYPE="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
... same for everything ...
LC_ALL=

And of locale -a:

C
en_US.utf8
POSIX

@veggiedefender
Copy link

veggiedefender commented Nov 29, 2017

Another project had this issue in 2015: commercialhaskell/stack#856

Here's the pretty complicated logic they added in the commit that fixed it:

commercialhaskell/stack@478ca71

@develar
Copy link
Member

develar commented Nov 29, 2017

@veggiedefender Thanks for info. Our fix is simple :)

@develar
Copy link
Member

develar commented Nov 29, 2017

Please try prerelease 19.47.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants