--- pango/pango-utils.c.relocate	2008-09-30 10:23:42.000000000 -0400
+++ pango/pango-utils.c	2008-09-30 10:26:35.000000000 -0400
@@ -692,19 +692,23 @@
 G_CONST_RETURN char *
 pango_get_sysconf_subdirectory (void)
 {
-#ifdef G_OS_WIN32
-  static gchar *result = NULL;
+  static const gchar *result = NULL;
 
   if (result == NULL)
     {
+#ifdef G_OS_WIN32
       gchar *root = g_win32_get_package_installation_directory_of_module (pango_dll);
       result = g_build_filename (root, "etc\\pango", NULL);
       g_free (root);
-    }
-  return result;
 #else
-  return SYSCONFDIR "/pango";
+      const char *sysconfdir = g_getenv("PANGO_SYSCONFDIR");
+      if (sysconfdir != NULL)
+	result = g_build_filename(sysconfdir, "pango", NULL);
+      else
+	result = SYSCONFDIR "/pango";
 #endif
+    }
+  return result;
 }
 
 /**
@@ -721,19 +725,23 @@
 G_CONST_RETURN char *
 pango_get_lib_subdirectory (void)
 {
-#ifdef G_OS_WIN32
   static gchar *result = NULL;
 
   if (result == NULL)
     {
+#ifdef G_OS_WIN32
       gchar *root = g_win32_get_package_installation_directory_of_module (pango_dll);
       result = g_build_filename (root, "lib\\pango", NULL);
       g_free (root);
-    }
-  return result;
 #else
-  return LIBDIR "/pango";
+      const char *libdir = g_getenv("PANGO_LIBDIR");
+      if (libdir != NULL)
+	result = g_build_filename(libdir, "pango", NULL);
+      else
+	result = LIBDIR "/pango";
 #endif
+    }
+  return result;
 }
 
 
