C++ RTTI/dynamic_cast across shared module boundaries?
C++ RTTI/dynamic_cast across shared module boundaries?
- Subject: C++ RTTI/dynamic_cast across shared module boundaries?
- From: Zachary Pincus <email@hidden>
- Date: Fri, 17 Feb 2006 08:01:25 -0600
Hi folks,
I've been trying for a while to get c++ RTTI and dynamic casting to
work across the boundaries of several "bundle" shared modules. I've
spent a day looking at man pages and online, to no avail.
In my case, instances of particular classes can be created in various
modules, but need to work (and dynamically cast properly) when passed
to other modules. (Before you ask: it's an image processing library,
where different image filter types are defined in different modules,
but they all need to be able to send and receive the same image types.)
I've linked the modules as follows:
/usr/bin/c++ -bundle -o [output].so [object files] -L[link paths] -l
[link libs]
Now, how do I need to set up my environment to get RTTI and
dynamic_cast working across several such modules?
Right now, the module loader is Python, which I think uses dlopen to
load the modules. I've set the dlopen flags (in python,
sys.setdlopenflags()) to 0x9, which is RTLD_LAZY|RTLD_GLOBAL (as they
are defined in /usr/include/dlfcn.h), but that really doesn't help.
(Other permutations on the dlopen flags don't help.)
Is there anything else I need to do? Is there anything else I can
try? Is this a hopeless project?
Zach Pincus
Program in Biomedical Informatics and Department of Biochemistry
Stanford University School of Medicine
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden