Index: hooks.c =================================================================== --- hooks.c (revision 34823) +++ hooks.c (revision 34824) @@ -88,7 +88,6 @@ /* Runs after initialization */ int hook_postinit() { - char *tmp; db_mkdir("/local"); db_mkdir("/local/pcb"); @@ -99,11 +98,7 @@ put("/local/pcb/want_static", sfalse); put("/local/pcb/dot_pcb_rnd", ".pcb-rnd"); put("/local/pcb/librnd_prefix", TO_STR(LIBRND_PREFIX)); - put("/local/pcb/librnd_template", tmp = str_concat("", TO_STR(LIBRND_PREFIX), "/", get("/local/libarchdir"), "/librnd/scconfig/template", NULL)); - free(tmp); - - /* if librnd is installed at some custom path, we'll need to have a -I on CFLAGS */ if ((strncasecmp(TO_STR(LIBRND_PREFIX), "/usr/include", 12) != 0) && (strncasecmp(TO_STR(LIBRND_PREFIX), "/usr/local/include", 18) != 0)) { put("/local/pcb/librnd_extra_inc", "-I" TO_STR(LIBRND_PREFIX) "/include"); @@ -116,6 +111,11 @@ /* Runs after all arguments are read and parsed */ int hook_postarg() { + char *tmp; + put("/local/pcb/librnd_template", tmp = str_concat("", TO_STR(LIBRND_PREFIX), "/", get("/local/libarchdir"), "/librnd/scconfig/template", NULL)); +printf("tmp='%s'\n", tmp); exit(1); + free(tmp); + import(TO_STR(LIBRND_PREFIX) "/share/librnd/plugin.state"); return rnd_hook_postarg(); }