2 kpath.cc -- glue kpathsea to lily. Need some ugly kludges for gcc 2.96
4 source file of the GNU LilyPond music typesetter
6 (c) 2000--2001 Han-Wen Nienhuys <hanwen@cs.uu.nl>
14 #define popen REALLYUGLYKLUDGE
15 #define pclose ANOTHERREALLYUGLYKLUDGE
17 #if HAVE_KPATHSEA_KPATHSEA_H
19 #include <kpathsea/kpathsea.h>
20 #include <kpathsea/tex-file.h>
25 #include "lily-version.hh"
29 ly_find_afm (char const * name)
31 #if (KPATHSEA && HAVE_KPSE_FIND_FILE)
32 return kpse_find_file (name, kpse_afm_format, true);
38 ly_find_tfm (char const * name)
40 #if (KPATHSEA && HAVE_KPSE_FIND_FILE)
41 return kpse_find_file (name, kpse_tfm_format, true);
48 ly_init_kpath (char *av0)
50 #if KPATHSEA && HAVE_KPATHSEA_KPATHSEA_H
54 kpse_set_program_name (av0, NULL);
55 kpse_maketex_option ("tfm", TRUE);
57 String my_tfm = "$VARTEXFONTS/tfm/lilypond/";
58 my_tfm += version_str () + "/";
60 char * mypath = kpse_expand (my_tfm.ch_C ());
61 String prog = "mktextfm --destdir ";
64 kpse_format_info[kpse_tfm_format].program = strdup (prog.ch_C ());
65 kpse_format_info[kpse_tfm_format].client_path = mypath;