32 char *env = getenv(
"TEXMFCNF");
37 gchar *texmfcnf = NULL;
38 TCHAR path[_MAX_PATH];
40 if (SearchPath(NULL,
"mktexpk",
".exe", _MAX_PATH, path, NULL))
42 gchar *sdir, *sdir_parent, *sdir_grandparent;
43 const gchar *texmfcnf_fmt =
"{%s,%s,%s}{,{/share,}/texmf{-local,}/web2c}";
45 sdir = g_path_get_dirname(path);
46 sdir_parent = g_path_get_dirname(sdir);
47 sdir_grandparent = g_path_get_dirname(sdir_parent);
49 texmfcnf = g_strdup_printf(texmfcnf_fmt,
50 sdir, sdir_parent, sdir_grandparent);
54 g_free(sdir_grandparent);