This is the mail archive of the cygwin@sources.redhat.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: binutils prerelease available for testing (feedback needed)


Danny Smith wrote:
> 
> >From: Charles Wilson <cwilson@ece.gatech.edu>
> >To: Danny Smith <danny_r_smith@hotmail.com>, cygwin@sources.redhat.com
> >Subject: Re: binutils prerelease available for testing (feedback needed)
> >Date: Fri, 21 Jul 2000 00:57:46 -0400
> >
> >Okay, it's confirmed -- I've just built cvs 20000721 + Mark E's patch.
> >Same behavior as before, no worse (no better).
> >
> >--Chuck
> > > CASE 3: 'USE_GLOBAL_ARRAYS' #define'd (dll exports png_libpng_ver as a
> > > DATA item)
> > > I can link using the import lib. Executable stackdumps.
> > >
> > > Danny, when you ran your tests, did your DLL export any DATA items?
> > >
> Yes, all my test cases (except Fortran) exported DATA.  The C++ code
> exported classes and instances of these class. Some of the classes had
> static data members that were exported. Dlls were built using
> __declspec(dllexport) in code.    All imports were marked in client code
> using __declspec(dllimport) attribute.
> 

!!!!! these are the correct rules. I was following them as well. I'm
flabbergasted.

Danny -- can you do me a favor? Build three versions of an executable,
linking to the static lib, directly to the dll (verify using 'ld
--verbose' that your build is NOT finding the dll or static lib or
hunting in some unexpected directory), and using the import library.

Then, pick a 'DATA' symbol in the dll, and do:

nm prog_stat.exe | grep 'my_symbol'
nm prog_dll.exe | grep 'my_symbol'
nm prog_imp.exe | grep 'my_symbol'

I believe my problem is that my 'prog_imp.exe' contains only a 'I
__imp__my_symbol' and no 'T _my_symbol', whereas my prog_dll.exe
contains both. I'd like to know what your prog_imp.exe contains...

Thanks,
Chuck

Note: to get the 'correct' ld command line, I've used 'gcc --verbose' as
my initial link command, then used the collect2.exe line that gcc
reported as my 'real' link command.

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]