Branch: Tag:

2000-03-26

2000-03-26 20:54:43 by Fredrik Hübinette (Hubbe) <hubbe@hubbe.net>

dump 50 modules at a time

Rev: bin/install.pike:1.48
Rev: src/dumpmaster.pike:1.3
Rev: src/dumpmodule.pike:1.8

1:   #define UNDEFINED (([])[0])    + string fakeroot; +    void handle_error(mixed err)   {    werror("%O\n",err);   } -  +  + string read_file(string s) + { +  if(fakeroot) +  s=fakeroot+combine_path(getcwd(),s); +  +  return _static_modules.files()->Fd(s,"r")->read(); + } +    program compile_file(string file)   { -  return compile(cpp(_static_modules.files()->Fd(file,"r")->read(),file)); +  return compile(cpp(read_file(file),file));   }      class Codec
19:   }   void _main(string *argv, string *env)   { +  foreach(argv[1..sizeof(argv)-2], string f) +  sscanf(f,"--fakeroot=%s",fakeroot); +     program p=compile_file(argv[-1]);    string s=encode_value(p, Codec());    _static_modules.files()->Fd(argv[-1] + ".o","wct")->write(s);