diff options
author | John Ralls <jralls@ceridwen.us> | 2012-11-03 11:46:59 -0700 |
---|---|---|
committer | John Ralls <jralls@ceridwen.us> | 2012-12-08 12:40:15 -0800 |
commit | 69b07369009d3337b1ec2c97e397a2ece9bbab6c (patch) | |
tree | ac3fdb85444d1a3a43fa9847ab66e443cd8575eb /pango/modules.c | |
parent | f03a630db5b346eb28284442e655b0e9ff1c5298 (diff) | |
download | pango-69b07369009d3337b1ec2c97e397a2ece9bbab6c.tar.gz |
Fix relative module paths
So that the created absolute path is where the modules are installed
instead of where the modules file is installed (i.e.,
lib/pango/1.8.0/modules instead of etc/pango).
Diffstat (limited to 'pango/modules.c')
-rw-r--r-- | pango/modules.c | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/pango/modules.c b/pango/modules.c index 644cc9cb..c5a19f25 100644 --- a/pango/modules.c +++ b/pango/modules.c @@ -450,11 +450,17 @@ process_module_file (FILE *module_file, const gchar *module_file_dir) switch (i) { case 0: - if (!g_path_is_absolute (tmp_buf->str)) { - const gchar *abs_file_name = g_build_filename (module_file_dir, tmp_buf->str, NULL); - g_string_assign (tmp_buf, abs_file_name); - g_free ((gpointer) abs_file_name); - } + if (!g_path_is_absolute (tmp_buf->str)) + { + const gchar *lib_dir = pango_get_lib_subdirectory (); + const gchar *abs_file_name = g_build_filename (lib_dir, + MODULE_VERSION, + "modules", + tmp_buf->str, + NULL); + g_string_assign (tmp_buf, abs_file_name); + g_free ((gpointer) abs_file_name); + } pair->module = find_or_create_module (tmp_buf->str); break; case 1: |