07-11-2005 01:01 PM
void *libhandle;int (*edge_func)();libhandle = dlopen("/home/elliot/opencv_code/edge_code/edge.so", RTLD_LAZY);edge_func = dlsym(libhandle, "main");(*edge_func)();dlclose(libhandle);return 0;
/* Insert code here */void *libhandle;int (*edge_func)();libhandle = dlopen("/home/elliot/opencv_code/edge_code/edge.so", RTLD_LAZY);edge_func = dlsym(libhandle, "main");(*edge_func)();dlclose(libhandle);return noErr;
07-11-2005 02:04 PM
07-11-2005 02:05 PM
07-12-2005 07:43 AM
07-12-2005 01:39 PM
07-12-2005 02:31 PM
07-13-2005 12:39 PM
07-13-2005 12:46 PM
makes sense. That explains why LabVIEW shuts down when I called edge.so since edge.so is a shared library file of edge.c whose main function calls certain OpenCV functions.
The description you provided regarding LabVIEW shutting down without an error or any other indication of a problem is exactly how LabVIEW responds on Windows when a required dll is not found. I'm not clear on how LabVIEW loads everything it needs, but it seems that if a dll which is called dynamically from within a dll that is called directly from a LabVIEW vi is unavailable, that is the behavior that I see. LabVIEW seems to check for the existence of "top-level" dll's when it loads a vi that calls something, but it doesn't check for the existence of everthing that is required to run a given function.