I think the underscore in the symbol table is the problem. After looking at the dev-archives again, it seem that specifying an entry point is not even required in the current version, dx will always look for a DXEntry function in any module that it loads.

The dev-archives pointed me to the file in the source that actually loads the module, loader.c. I took a look at that and, for my case, it seems like the module is opened, but the symbol DXEntry (without the underscore) is not found. So dx outputs the error message.

I am using gcc 3.1. and there does not seem to be a way to get the compiler not add the leading underscore on function names in the symbol table. -fno-leading-underscore as a cc option does not appear to work.

Based on the output of nm, all of the symbol names in dxexec have leading underscores too. So it seems that removing the underscores from the new module may not be the way to go. Unless I could remove it just from the DXEntry symbol.

Thanks,
Norm


Which version of gcc are you using? You can look at the symbol table of your loadable module with nm and determine what symbols are in there. When I first was writing modules for MacOS X, the compiler used libtool for the linking and the compiler inserted the underscore (_) on all function names--that's why DXEntry became _DXEntry as the load symbol. Maybe that has now changed.

David


--
.............................................................................
David L. Thompson                   Visualization and Imagery Solutions, Inc.
mailto:[EMAIL PROTECTED]    5515 Skyway Drive, Missoula, MT 59804
                                    Phone : (406)756-7472

Reply via email to