rem: PsfontMMSpace *mmspace = amfm->mmspace();
add: EfontMMSpace *mmspace = amfm->mmspace();
context: main(int argc, char **argv){  MetricsFinder *finder = new CacheMetricsFinder;    PsresDatabase *psres = new PsresDatabase;  psres->add_psres_path(getenv("PSRESOURCEPATH"), 0, false);  PsresMetricsFinder *psres_finder = new PsresMetricsFinder(psres);  finder->add_finder(psres_finder);    Clp_Parser *clp =    Clp_NewParser(argc, argv, sizeof(options) / sizeof(options[0]), options);  program_name = Clp_ProgramName(clp);  errh = new FileErrorHandler(stderr);    char *output_name = "<stdout>";  FILE *output_file = 0;  int precision = 3;  double kern_precision = 2.0;  while (1) {    int opt = Clp_Next(clp);    switch (opt) {           case WEIGHT_OPT:      set_design("Weight", clp->val.d);      break;           case WIDTH_OPT:      set_design("Width", clp->val.d);      break;           case OPSIZE_OPT:      set_design("OpticalSize", clp->val.d);      break;           case STYLE_OPT:      set_design("Style", clp->val.d);      break;           case N1_OPT:     case N2_OPT:     case N3_OPT:     case N4_OPT:      set_design(opt - N1_OPT, clp->val.d);      break;     case PRECISION_OPT:      precision = clp->val.i;      break;           case KERN_PREC_OPT:      kern_precision = clp->val.d;      break;           case OUTPUT_OPT:      if (output_file) errh->fatal("output file already specified");      if (strcmp(clp->arg, "-") == 0) {	output_file = stdout;	output_name = "<stdout>";      } else {	output_file = fopen(clp->arg, "wb");	if (!output_file) errh->fatal("can't open `%s' for writing", clp->arg);      }      break;           case HELP_OPT:      usage();      exit(0);      break;           case VERSION_OPT:      printf("mmafm (LCDF mminstance) %s\n", VERSION);      printf("Copyright (C) 1997-2001 Eddie Kohler\n\This is free software; see the source for copying conditions.\n\There is NO warranty, not even for merchantability or fitness for a\n\particular purpose.\n");      exit(0);      break;           case Clp_NotOption:      read_file(clp->arg, finder);      break;           case Clp_Done:      goto done;           case Clp_BadOption:      usage_error(0);      break;          }  }   done:  if (!amfm) usage_error("missing font argument");    PsfontMMSpace *mmspace = amfm->mmspace();#if MMAFM_RUN_MMPFB  if (!mmspace->check_intermediate()) {    char *buf = new char[amfm->font_name().length() + 30];    sprintf(buf, "mmpfb -q --amcp-info '%s'", amfm->font_name().cc());        FILE *f = popen(buf, "r");    if (f) {      Filename fake("<mmpfb output>");      Slurper slurpy(fake, f);      AmfmReader::add_amcp_file(slurpy, amfm, errh);      pclose(f);    }        delete[] buf;  }#endif    Vector<double> design = mmspace->default_design_vector();  for (int i = 0; i < values.size(); i++)    if (ax_names[i])      mmspace->set_design(design, ax_names[i], values[i], errh);    else      mmspace->set_design(design, ax_nums[i], values[i], errh);    Vector<double> weight;  if (!mmspace->design_to_weight(design, weight, errh)) {    if (!mmspace->check_intermediate()) {      errh->message("(I can't interpolate font programs with intermediate masters on my own.");#if MMAFM_RUN_MMPFB      errh->message("I tried to run `mmpfb --amcp-info %s', but it didn't work.", amfm->font_name().cc());      errh->message("Maybe your PSRESOURCEPATH environment variable is not set?");#endif      errh->fatal("See the manual page for more information.)");    } else      errh->fatal("can't create weight vector");  }    // Need to check for case when all design coordinates are unspecified. The  // AMFM file contains a default WeightVector, but often NOT a default  // DesignVector; we don't want to generate a file with a FontName like  // `MyriadMM_-9.79797979e97_-9.79797979e97_' because the DesignVector  // components are unknown.  if (!KNOWN(design[0]))    errh->fatal("must specify %s's %s coordinate", amfm->font_name().cc(),		mmspace->axis_type(0).cc());    Metrics *m = amfm->interpolate(design, weight, errh);  if (m) {        // Add a comment identifying this as interpolated by mmafm    if (MetricsXt *xt = m->find_xt("AFM")) {      AfmMetricsXt *afm_xt = (AfmMetricsXt *)xt;      #if HAVE_CTIME      time_t cur_time = time(0);      char *time_str = ctime(&cur_time);      int time_len = strlen(time_str) - 1;      char *buf = new char[strlen(VERSION) + time_len + 100];      sprintf(buf, "Interpolated by mmafm-%s on %.*s.", VERSION,	      time_len, time_str);#else      char *buf = new char[strlen(VERSION) + 100];      sprintf(buf, "Interpolated by mmafm-%s.", VERSION);#endif            afm_xt->opening_comments.push_back(buf);      afm_xt->opening_comments.push_back("Mmafm is free software.  See <http://www.lcdf.org/type/>.");      delete[] buf;    }    // round numbers if necessary    if (precision >= 0)      apply_precision(m, precision);    if (kern_precision > 0)      apply_kern_precision(m, kern_precision);        // write the output file    if (!output_file) output_file = stdout;    AfmWriter::write(m, output_file);        return 0;  } else    return 1;}