Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Date: Fri, 1 Aug 2003 23:11:36 -0400 From: Christopher Faylor To: cygwin AT cygwin DOT com Subject: Re: loading DLLs created with cygwin into Sun JDK Message-ID: <20030802031136.GA12126@redhat.com> Reply-To: cygwin AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com References: <3F2B292B DOT 3020600 AT santafe DOT edu> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3F2B292B.3020600@santafe.edu> User-Agent: Mutt/1.4.1i On Fri, Aug 01, 2003 at 08:59:55PM -0600, Marcus G. Daniels wrote: >Alan Thompson write: > >>OK - now you have me confused.... >>If you're not loading DLL's into Java for use with JNI, what are you doing? >>Also, note that those techniques work for both plain JNI (i.e. java calls >>into C/C++) as well as the invocation API (where a C/C++ program creates >>an JVM). > >Again, "those techniques" specify use of -mno-cygwin, which worked fine for >me in my posted example. The crash happens as the DLL is loaded, not when >methods are called. > >Have you actually tried _not_ using -mno-cygwin? > >Also, using 'javah' or not to generate the headers (and making sure >JNIEXPORT and >JNICALL are in the header and implementation declarations, and using >and using -Wl,--add-stdcall-alias makes no difference. For this simple >test case, you need to have JNIEXPORT/JNICALL and the >-Wl,--add-stdcall-alias, or neither to get the test case to work. I haven't been reading this closely since my eyes immediately crust over when I see things like JDK or Java (requiring painful application of a cold chisel for crust removal) but if you are trying to use cygwin dlls in a non-cygwin process, that won't work. It used to work in the past, if you called the right initialization functions in the cygwin dll, but it has been broken for a while and no one has shown any interest in fixing the problem. -- Please use the resources at cygwin.com rather than sending personal email. Special for spam email harvesters: send email to aaaspam AT sourceware DOT org and be permanently blocked from mailing lists at sources.redhat.com -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/