This is the mail archive of the cygwin@sourceware.cygnus.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]

strange relocations in dll => crash


[b18 on NT4.0SP3, cross on SGI Irix 6.2]


Hi,

I have a very strange problem when I try to make a relocatable dll.

I use the following procedure, all objects are compiled with debug (ie contains
.stab & .stabstr sections):

	ld $(LDFLAGS) --dll -e $(%entry) -o tmp.dll --base-file base $(%obj)
	dlltool --dllname $@ --base-file base --output-exp tmp.exp --def
dll.def
	ld $(LDFLAGS) --dll -e $(%entry) -o $@ tmp.exp $(%obj)


-1) Some relocations appear for sections .stab & .idata($3) ???

-2) After the 2nd link the export section (.edata) is inserted before the
import section (.idata). The vma's are changed but the relocations generated by
the first pass aren't updated => the relocations are applyed in the wrong
sections.

----> Workaround: add another pass ( dlltool ... & link )

	I think the problem comes from the first remark (relocations for .stab
& .idata) but I'm really not an expert, I tried to see with debugger what's
going on but the code of linker remains obscure for me.

Any kind of help will be welcome ...

Best regards.

-- 

 ==========================================================================
|                         Philippe GIACINTI                                |
|                                                                          |
| DALiM GmbH R&D                                email:  giac@dalim.de      |
| Daimler Strasse 2,                            tel:    +49.7851.9196-28   |
| D-77694 Kehl-Sundheim Germany                 fax:    +49.7851.73576	   |
|                                                                          |
 ==========================================================================
-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".


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