delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2001/07/22/00:27:07

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sources DOT redhat DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sources DOT redhat DOT com>
List-Help: <mailto:cygwin-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT sources DOT redhat DOT com
Delivered-To: mailing list cygwin AT sources DOT redhat DOT com
Message-ID: <006701c1126f$1a311a60$ce823bd5@dmitry>
From: "Dmitry Timoshkov" <dmitry AT baikal DOT ru>
To: "Christopher Hicks" <chicks AT chicks DOT net>
Cc: <cygwin AT cygwin DOT com>
References: <Pine DOT LNX DOT 4 DOT 33 DOT 0107211431070 DOT 25320-100000 AT yakko DOT chicks DOT net>
Subject: Re: Fixed making DLL, but can't get rid of @n weirdness
Date: Sun, 22 Jul 2001 13:27:06 +0800
MIME-Version: 1.0
X-Priority: 3
X-MSMail-Priority: Normal
X-Mailer: Microsoft Outlook Express 5.50.4133.2400
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400

------=_NextPart_000_005E_01C112B2.00997460
Content-Type: text/plain;
	charset="koi8-r"
Content-Transfer-Encoding: 7bit

"Christopher Hicks" <chicks AT chicks DOT net> wrote:

> I found much better documentation at
> http://www.neuro.gatech.edu/users/cwilson/cygutils/V1.1/dll-stuff/index.html
> so I've finally been able to create a DLL!
>
> But regardless of what options I've tried to provide to dlltool and
> dllwrap it's still adding @/n/ to the symbols.

[skipped]

I'm using the following command lines to build DLLs under Cygwin:

dllwrap -o $(LIBRARY).dll $(OBJS) $(LIBS) -k --def $(LIBRARY).def -Wl,--kill-at,--enable-stdcall-fixup
dlltool --kill-at --input-def $(LIBRARY).def --output-lib lib$(LIBRARY).a

Notes:
1. You have to have decorated (with @) exported names in the .def file.
2. Apply the attached patch to dlltool.c from the binutils provided by Cygwin
and rebuild dlltool.

Good luck.
--
Dmitry.

------=_NextPart_000_005E_01C112B2.00997460
Content-Type: application/octet-stream;
	name="dlltool.c.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
	filename="dlltool.c.diff"

--- dlltool.c	Fri May 18 11:23:52 2001
+++ dlltool.c	Fri May 18 11:24:56 2001
@@ -1865,7 +1865,7 @@
 	if (!exp->noname || show_allnames)
 	  {
 	    fprintf (f, "n%d:	%s	\"%s\"\n",
-		     exp->ordinal, ASM_TEXT, exp->name);
+		     exp->ordinal, ASM_TEXT, xlate (exp->name));
 	    if (exp->forward != 0)
 	      fprintf (f, "f%d:	%s	\"%s\"\n",
 		       exp->forward, ASM_TEXT, exp->internal_name);


------=_NextPart_000_005E_01C112B2.00997460
Content-Type: text/plain; charset=us-ascii

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/
------=_NextPart_000_005E_01C112B2.00997460--

- Raw text -


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