mirror of
https://github.com/godotengine/godot.git
synced 2025-10-19 16:03:29 +00:00
[Linux/BSD] Add dynamically loaded library version checks.
This commit is contained in:
parent
161d028ae8
commit
bed46f723c
9 changed files with 160 additions and 11 deletions
|
@ -1102,6 +1102,16 @@ OS_LinuxBSD::OS_LinuxBSD() {
|
|||
#else
|
||||
font_config_initialized = true;
|
||||
#endif
|
||||
if (font_config_initialized) {
|
||||
bool ver_ok = false;
|
||||
int version = FcGetVersion();
|
||||
ver_ok = ((version / 100 / 100) == 2 && (version / 100 % 100) >= 11) || ((version / 100 / 100) > 2); // 2.11.0
|
||||
print_verbose(vformat("FontConfig %d.%d.%d detected.", version / 100 / 100, version / 100 % 100, version % 100));
|
||||
if (!ver_ok) {
|
||||
font_config_initialized = false;
|
||||
}
|
||||
}
|
||||
|
||||
if (font_config_initialized) {
|
||||
config = FcInitLoadConfigAndFonts();
|
||||
if (!config) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue