dbg(2,"enter gui %p graphics %p\n",this_->gui,this_->gra);
if (!this_->gui && !(this_->flags & 2)) {
- dbg(0,"no gui\n");
+ dbg(0,"Warning: No GUI available.\n");
navit_destroy(this_);
return;
}
if (!this_->gra && !(this_->flags & 1)) {
- dbg(0,"no graphics\n");
+ dbg(0,"Warning: No graphics subsystem available.\n");
navit_destroy(this_);
return;
}
g_module_close(mod);
return 0;
} else {
+ dbg(1, "loaded module %s\n", pl->name);
pl->mod=mod;
pl->init=init;
}
if (count != 1 || file_exists(array[0])) {
for (i = 0 ; i < count ; i++) {
name=array[i];
- dbg(2,"name[%d]='%s'\n", i, name);
+ dbg(2,"found plugin module file [%d]: '%s'\n", i, name);
if (! (pls && (pl=g_hash_table_lookup(pls->hash, name)))) {
pl=plugin_new_from_path(name);
if (! pl) {
- dbg(0,"failed to create plugin '%s'\n", name);
+ dbg(0,"failed to create plugin from file '%s'\n", name);
continue;
}
if (pls) {
GList *l;
l=pls->list;
- while (l) {
- pl=l->data;
- if (! plugin_get_ondemand(pl)) {
- if (plugin_get_active(pl))
- if (!plugin_load(pl))
- plugin_set_active(pl, 0);
- if (plugin_get_active(pl))
- plugin_call_init(pl);
+ if (l){
+ while (l) {
+ pl=l->data;
+ if (! plugin_get_ondemand(pl)) {
+ if (plugin_get_active(pl))
+ if (!plugin_load(pl))
+ plugin_set_active(pl, 0);
+ if (plugin_get_active(pl))
+ plugin_call_init(pl);
+ }
+ l=g_list_next(l);
}
- l=g_list_next(l);
+ } else {
+ dbg(0, "Warning: No plugins found. Is Navit installed correctly?\n");
}
#endif
}