[Ecls-list] Library init function
Julian Stecklina
der_julian at web.de
Fri May 12 07:17:18 UTC 2006
Hello,
if I create a library using c:build-static-library with a named init
function, the following is created:
void initialize_cl(cl_object cblock)
{
static cl_object Cblock;
if (!FIXNUMP(cblock)) {
Cblock = cblock;
cblock->cblock.data_text = compiler_data_text;
cblock->cblock.data_text_size = compiler_data_text_size;
#ifndef ECL_DYNAMIC_VV
cblock->cblock.data = VV;
#endif
cblock->cblock.data_size = VM;
return;
}
#if defined(ECL_DYNAMIC_VV) && defined(ECL_SHARED_DATA)
VV = Cblock->cblock.data;
#endif
{
cl_object current, next = Cblock;
current = read_VV(OBJNULL, init_XCHAT_SYSTEM); current->cblock.next = next; next = current;
Cblock->cblock.next = current;
}
}
What should be passed as cblock, if the library is initialized from C
code? Calling it with NULL obviously causes a SEGV...
Regards,
--
Julian Stecklina
"I object to doing things that computers can do." - Olin Shivers
More information about the ecl-devel
mailing list