Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT sources DOT redhat DOT com Delivered-To: mailing list cygwin AT sources DOT redhat DOT com Message-ID: <39732229.5E4E1D33@ece.gatech.edu> Date: Mon, 17 Jul 2000 11:11:37 -0400 From: Charles Wilson X-Mailer: Mozilla 4.73 [en] (Windows NT 5.0; U) X-Accept-Language: en MIME-Version: 1.0 To: Fabio Tamburini CC: cygwin AT sources DOT redhat DOT com Subject: Re: How to build a DLL References: <3972D35F DOT 16FC8C7B AT cilta DOT unibo DOT it> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Fabio Tamburini wrote: > > Hi > I am a novice of cygwin and I am wondering if it is possible to compile > a lib???.a archive into > a DLL library using the cygwin environment. > How can I do that? Is there a tutorial on it? > > Thanks... > > Please answer directly using my email. > Please search the mail archives; this question has been asked many times in the past. Also, see Mumit Khan's web page (there's a link to it on the Cygwin web page/'related links'). Short version: mkdir foo cd foo cp lib????.a . ar x lib????.a gcc -shared -Wl,--enable-auto-image-base *.o -o lib????.dll -Wl,--out-implib=lib????.dll.a This creates a dll and an import lib. BTW, gcc *actually* delegates this job to the linker ld.exe, and the in official version (binutils-20000625) these features are broken. You can get a patched version of ld.exe at http://cygutils.netpedia.net/V1.1/linker/ld.exe.tar.gz --Chuck -- Want to unsubscribe from this list? Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com