-void Component::Loader::modular()
-{
- if(comp.type!=PROGRAM)
- throw Exception("Only programs can be modular");
- comp.modular = true;
-}
-
-void Component::Loader::host(const string &n)
-{
- const ComponentList &comps = comp.pkg.get_components();
- for(ComponentList::const_iterator i=comps.begin(); i!=comps.end(); ++i)
- if(i->get_name()==n)
- {
- if(i->get_type()!=PROGRAM || !i->is_modular())
- throw Exception("Module host must be a modular program");
- comp.module_host = &*i;
- return;
- }
-
- throw KeyError("Unknown component", n);
-}
-
-void Component::Loader::install_headers(const string &p)
-{
- IO::print("%s: Note: install_headers is deprecated\n", get_source());
- if(comp.type==HEADERS)
- {
- comp.name = p;
- comp.install = true;
- }
- else
- inst_hdr = p;
-}
-