Mailing-List: contact cygwin-help@sourceware.cygnus.com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe@sourceware.cygnus.com>
List-Archive: <http://sourceware.cygnus.com/ml/cygwin/>
List-Post: <mailto:cygwin@sourceware.cygnus.com>
List-Help: <mailto:cygwin-help@sourceware.cygnus.com>, <http://sourceware.cygnus.com/ml/#faqs>
Sender: cygwin-owner@sourceware.cygnus.com
Delivered-To: mailing list cygwin@sourceware.cygnus.com
Message-ID: <3946C3B2.84F9D76E@carlthompson.net>
Date: Tue, 13 Jun 2000 16:28:50 -0700
From: Carl Thompson <cet@carlthompson.net>
X-Mailer: Mozilla 4.73 [en] (X11; U; Linux 2.2.14-5.0 i686)
MIME-Version: 1.0
To: Bradley Smith <brad2010@hotmail.com>
Cc: Cygwin List <cygwin@sourceware.cygnus.com>
Subject: Re: Where can I get Cygwin 20.1b?
References: <20000613225357.25271.qmail@hotmail.com>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Bradley Smith wrote:
> 
> I'm trying to make a ".dll" so that I can run the JNI and interface
> some C++ code with some Java code...
> 
> Here is the site I found some code :
> http://www.xraylith.wisc.edu/~khan/software/gnu-win32/dllhelpers.html

With newer versions of GCC (and Cygwin) you can create DLLs much more easily
without the need for dllhelpers.  You would use something like

   gcc -Wl,--out-implib,libtest.import.a -shared -o test.dll test.o

This would create "test.dll" with from the object file "test.o" .  It will
also create an import library for the DLL (libtest.import.a).

(Of course, you still need to add the prefixes "__declspec(dllexport)" and
"__declspec(dllimport)" to your headers as needed.)

To use the new easy method, you need a newer version of GCC, not EGCS.  If
you are developing an application that uses the Cygwin DLL, the latest
version available from http://sourceware.cygnus.com/cygwin should work fine
for you.  If you need to create strictly Windows applications / DLLs without
any Unix compatibilty stuff, you can grab an updated version of b20.1 from
my site at http://www.carlthompson.net/cygwin.  I know it works to build
DLLs because I use it myself.

> ...

> thanks
> 
> -Brian

Hope this helps,
Carl Thompson

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

