Overview
| Artifact ID: | ac39f1ecc221546ee2a388d4e1ea7e7034880e9b |
|---|---|
| Ticket: | 1961211fffffffffffffffffffffffffffffffff
TclpDlopen failing on MacOSX 10.4 and later |
| User & Date: | sebbarre on 2008-05-14 05:24:14 |
Changes
- icomment:
Logged In: YES user_id=214100 Originator: YES > No, RLTD_LOCAL does not mean that all static members are duplicated. OK, good to know. > there is a problem with run-time resolution of symbols in your libraries. I know Tcl/Tk is solid, but this C++ toolkit (VTK) is more than 10 years old. We have wrapped it using Tcl for pretty much the same amount time (as well as Python and Java), and have performed "package require" or calls to Tcl's "load" in hundreds of Tcl tests to exercise the toolkit every night, for years, on dozens of Unix platforms and Win32 platforms, using many, many compilers. It has always been divided into different shared libraries. Problems arose only recently when testing on MacOSX > 10.4 with Tcl/Tk 8.5, since it is now using dlopen (instead of NSModule). > It might be that library A and B are correct, but the problem is in > C which is used by both A and B. It's hard to tell from here. Please check my first message. I'm firing the shell, then loading A (libvtkCommonTCL). Then loading B (libvtkFilteringTCL). The symbol it is clearly complaining about (__Z14vtkTclInDeleteP10Tcl_Interp) *is* in A, not in a library that would be in a dependency of A. > I'm not trying to break currently working code. But some platforms, > like win32, don't support undefined symbols in dll's at all, so > if your libraries have a symbol resolution problem it will be > impossible to port your libraries to win32. This toolkit has been cross-platform from its origin. Regression testing shows we have no resolution problems on Win32 platforms, from Win 2000 to Vista, using MsDev6 to VisualStudio8. Therefore, I'm inclined to think there is no symbol resolution issue at the moment, though I might be wrong, but we do stress test VTK *a lot*, every night, and in a continuous manner during the day. I think there is probably a good reason why the default is RLTD_GLOBAL and not RLTD_LOCAL, on MacOSX, as opposed to some other OS... My question is, and I'm not certain you answered it: what would Tcl *break* by using RLTD_GLOBAL consistently? I also did some quick Googling: http://groups.google.com/group/comp.lang.perl.misc/msg/a2877cf7e0c656fe => this Perl user seemed to have the exact same problem while loading a Perl module. Another msg that seems to indicate that RLTD_LOCAL can not be used if you load two libs A and B, B depending on A (wherewas RLTD_GLOBAL would allow it to work, and not break other examples, unless I missed something) http://gcc.gnu.org/ml/gcc/2002-05/msg02034.html Thank you
- login: "sebbarre"
- mimetype: "text/plain"
- username: "sebbarre"