mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-07-17 01:06:08 +03:00
locale always requires libc
This commit is contained in:
@ -7,12 +7,13 @@ const log = std.log.scoped(.os);
|
|||||||
|
|
||||||
/// Ensure that the locale is set.
|
/// Ensure that the locale is set.
|
||||||
pub fn ensureLocale() void {
|
pub fn ensureLocale() void {
|
||||||
|
assert(builtin.link_libc);
|
||||||
|
|
||||||
// On macOS, pre-populate the LANG env var with system preferences.
|
// On macOS, pre-populate the LANG env var with system preferences.
|
||||||
// When launching the .app, LANG is not set so we must query it from the
|
// When launching the .app, LANG is not set so we must query it from the
|
||||||
// OS. When launching from the CLI, LANG is usually set by the parent
|
// OS. When launching from the CLI, LANG is usually set by the parent
|
||||||
// process.
|
// process.
|
||||||
if (comptime builtin.target.isDarwin()) {
|
if (comptime builtin.target.isDarwin()) {
|
||||||
assert(builtin.link_libc);
|
|
||||||
if (std.os.getenv("LANG") == null) {
|
if (std.os.getenv("LANG") == null) {
|
||||||
setLangFromCocoa();
|
setLangFromCocoa();
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user