From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10883 invoked by alias); 27 Jun 2006 03:20:28 -0000 Received: (qmail 10719 invoked by uid 48); 27 Jun 2006 03:20:19 -0000 Date: Tue, 27 Jun 2006 04:09:00 -0000 Message-ID: <20060627032019.10718.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug java/28153] Under Windows Xp the generated JNI headers need to have a '_' prepended for each function. In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "tromey at gcc dot gnu dot org" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2006-06/txt/msg02381.txt.bz2 List-Id: ------- Comment #5 from tromey at gcc dot gnu dot org 2006-06-27 03:20 ------- Yeah, jni.cc handles the lookup side of things. The declaration side of things in user JNI code should be handled by jni_md.h. It has a bunch of win32-specific code which boils down to: #define JNIIMPORT __declspec(dllimport) #define JNIEXPORT __declspec(dllexport) #define JNICALL __stdcall It might be handy to see a small preprocessed source file. Perhaps you're picking up the wrong jni.h, jni_md.h, or perhaps the logic in jni_md.h is broken somehow. Oops, I just looked at your version... jni_md.h is not in 3.4. In 3.4 the same logic appears, only it is in jni.h. It is possible that we fixed some bugs in this area since 3.4. I don't remember. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28153