delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/1997/08/07/12:09:07.1

From: giac AT dalim DOT de ("Philippe GIACINTI")
Subject: Re: dll building : segmentation faults
7 Aug 1997 12:09:07 -0700 :
Approved: cygnus DOT gnu-win32 AT cygnus DOT com
Distribution: cygnus
Message-ID: <9708071517.ZM982.cygnus.gnu-win32@pion.kehl.dalim.de>
References: <19970806130447 DOT 28713 AT bsilx1 DOT iitb DOT fhg DOT de>
Mime-Version: 1.0
In-Reply-To: "Andreas Jellinghaus (bei rf)" <jelling@iitb.fhg.de>
"dll building : segmentation faults" (Aug 6, 1:04pm)
X-Face: ^cJc2\tiS@#Ja AT 7laz+N]T)kL{-Kay)Oz"?}p[wuY#}}dO"enP!QVO{,}&4P2V[hEfJD]9&
E1ou~|tY/|9d&7c,7yf>7n: Zj8FD(LtPXWHzy^OJIDi/~O~R]3x/5}"7P;|,*%f:3Z!>h8Ff/&)g?/
}$RXQ
X-Mailer: Z-Mail (3.2.3 08feb96 MediaMail)
Original-To: aj AT dungeon DOT inka DOT de
Original-Cc: gnu-win32 AT cygnus DOT com
Original-Sender: owner-gnu-win32 AT cygnus DOT com

Hi,

1) The fixup asm(".section .idata$3 ...") is here to terminate the Import
Directory Table in which each element is 5x32 bits long and which should be
terminated with a NULL element.
So I think the correct fixup should be
	asm(".section .idata$3\n" ".long 0,0,0,0,0"); only 5 zeros ...

2) May be can you try to put the fixup at end of your file, I had problems
which were solved that way ... ( don't ask me why )

#include <windows.h>
/* asm(".section .idata$3\n" ".long 0,0,0,0,0,0,0,0"); not here */
WINAPI dll_entry(int a,int b,int c) { return 1; }
void dummy() { return ; }
/* put it here */
asm(".section .idata$3\n" ".long 0,0,0,0,0");

3) I had also some troubles with strange relocations that I have solved in
adding a third link pass ...


Hope this helps,

Best regards.

-- 

 ==========================================================================
|                         Philippe GIACINTI                                |
|                                                                          |
| DALiM GmbH R&D                                email:  giac AT dalim DOT 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 AT cygnus DOT com" with one line of text: "help".

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019