On Thu, 21 Aug 2003, David Thompson wrote: > So you no longer need to set the -e flag to set the entry point?
No. When you build libraries that will be open with the "dlopen" function, the entry point set with the -e flag will not be used. You also do not need to set an entry point to DXEntry, because DXEntry in the loader.c file (in the section with "dl" functions) is explicitely called. On AIX, you had to set the entry point with the -e flag, because the section of the loader.c file for AIX used the "load" function. The load function called the entry point of the library, which had to be set to "DXEntry". The result was that using this approach the "DXEntry" did not have to be explicitely called. If your module needs some initialization, you use the -binitfini:my_entry_function flag to say which function of the library should be called from within the "dlopen" function. > Does the file dxexec.exp work as a -bE file if you change the first > line to #!. I guess what I'm asking is can you fix dxexec.exp to > work for both import and export? It doesn't work. I thought of this too. If I change "#!" to "#!." in the lib/dxexec.exp, OpenDX doesn't build. We really need the import file to begin with "#!.". > What does the -G option do? This option is equivalent to these flags together: "-berok", "-brtl", "-bnortllib", "-bsymbolic", "-bnoautoexp" and "-bM:SRE". Of these flags we only need "-berok" to ignore the dxexec undefined symbols, and "-bM:SER" for reentrant library. The IBM docs say to use this -G flag. If you want to build a C++ library, you need to use "-qmkshrobj" if you are on a POWER-based computer, and "-G -qmkshrobj" if you are on an Italium-based compuer (I did not test the Italium computer, because I don't have access to one). I tried "-G -qmkshrobj" on POWER-based, and it worked, so it's best to tell that you build C++ libraries on AIX with "-G -qmkshrobj". Best, Irek
