Commit 10ce7021 authored by Michael Natterer's avatar Michael Natterer 😴

Issue #2867 - iso-codes location is not relocatable on all platforms

gimplanguagestore-parser.c (parse_iso_codes): instead of
special-casing Windows and OS X, use ENABLE_RELOCATABLE_RESOURCES and
find the package relative to ${gimp_installation_directory}, so
relocating it works on all platforms (also flatpack, snap, whatever),
given the --enable-relocatable-bundle configure switch is used.
parent 545ef022
......@@ -336,11 +336,12 @@ parse_iso_codes (GHashTable *base_lang_list,
xml_parser = gimp_xml_parser_new (&markup_parser, &parser);
#if defined (G_OS_WIN32) || defined (PLATFORM_OSX)
file = gimp_data_directory_file ("..", "..",
"xml", "iso-codes", "iso_639.xml", NULL);
file = gimp_installation_directory_file ("share", "xml", "iso-codes",
"iso_639.xml", NULL);
file = g_file_new_for_path (ISO_CODES_LOCATION G_DIR_SEPARATOR_S "iso_639.xml");
file = g_file_new_for_path (ISO_CODES_LOCATION G_DIR_SEPARATOR_S
success = gimp_xml_parser_parse_gfile (xml_parser, file, error);
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment