[omniORB] Again about OmniOrb and shared objects
Andrey Koubychev
email@vtc.ru
Fri, 25 Jan 2002 15:46:28 +0100
Hello omniorb authors and developers,
I'm trying to put some work with corba into .so file on linux.
However i expirience some problems. Ideally, my dll should be
used from apache module. I wrote this module and this dll helper
(which uses corba) and it worked perfecly on win32 system.
But when i ported it to linux i meet problems with threading
locking. Very often call from ORB_init never returns.
I wrote simple program to test it , and it never returns from
orb->destroy.
here is .so module :
....
static CORBA::ORB_var orb = NULL;
....
extern "C" void orbdestr (void) __attribute__ ((constructor));
extern "C" void orbinit (void) __attribute__ ((destructor));
extern "C" void orbinit (void) {
int params=0;
orb = CORBA::ORB_init(params,NULL, "omniORB3");
};
extern "C" void orbdestr (void) {
if (orb) orb->destroy();
};
extern "C" void mytest (void) {
.. here comes a piece of code from any echo example
}
test.c program loads this .so dynamicly , calls mytest and then
returns. But in orbdestr it falls in endless wait ....
Could you please any comments ?
I also would like to hear any comments on usage in
multithreaded(with pthreads and forks) environment under linux.
Thank you for attention.
--
Best regards,
Andrey mailto:email@vtc.ru