]> git.donarmstrong.com Git - lilypond.git/blobdiff - stepmake/stepmake/metafont-rules.make
Fix configure and compilation issues with CPPFLAGS
[lilypond.git] / stepmake / stepmake / metafont-rules.make
index 2030f00158b206ea697e3ca389fc5f434f351a9c..64bdecf6775fcc8df561ad3313ac573251aa677f 100644 (file)
@@ -13,8 +13,15 @@ $(outdir)/%.tfm $(outdir)/%.log: %.mf
        mv $(basename $(@F)).log $(basename $(@F)).tfm $(outdir)
        rm -f $(basename $(@F)).*gf  $(basename $(@F)).*pk
 
+# ugh . mf2pt1 is extremely broken, it pollutes CWD iso. creating a
+# temp dir.
 $(outdir)/%.pfb: %.mf $(outdir)/mf2pt1.mem
-       cd $(outdir) && MFINPUTS=.. $(PERL) ../$(buildscript-dir)/mf2pt1.pl $(MF2PT1_OPTIONS) $<
+       TMP=`mktemp -d $(outdir)/pfbtemp.XXXXXXXXX` \
+       && ( cd $$TMP \
+               && ln -s ../mf2pt1.mem . \
+               && MFINPUTS=$(top-src-dir)/mf:..:: $(PERL) $(top-src-dir)/buildscripts/mf2pt1.pl $(MF2PT1_OPTIONS) $< ) \
+       && mv $$TMP/*pfb $(outdir); \
+       rm -rf $$TMP
 
-$(outdir)/mf2pt1.mem:
-       cd $(outdir) && mpost -progname=mpost -ini ../mf2pt1 \\dump
+$(outdir)/mf2pt1.mem: mf2pt1.mp
+       cd $(outdir) && mpost -progname=mpost -ini $(top-src-dir)/mf/mf2pt1.mp \\dump