Add rpath to binary executable on macOS (#258)

* removing superfluous slash from paths

* Add a necessary rpath to the imhex binary

* add a little error handling to dlopen

* fall back on en-US if no language specified in prefs

* PR changes as per @WerWolv
This commit is contained in:
Foster Brereton
2021-06-18 11:09:36 -07:00
committed by GitHub
parent b4b2c41b34
commit ac53b4bcab
4 changed files with 21 additions and 11 deletions

View File

@@ -100,8 +100,12 @@ namespace hex {
{
auto language = ContentRegistry::Settings::getSetting("hex.builtin.setting.interface", "hex.builtin.setting.interface.language");
if (language.is_string())
if (language.is_string()) {
LangEntry::loadLanguage(static_cast<std::string>(language));
} else {
// If no language is specified, fall back to English.
LangEntry::loadLanguage("en-US");
}
}
{
@@ -787,4 +791,4 @@ namespace hex {
ImGui::DestroyContext();
}
}
}