This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
Patch: FYI: gjavah JNI header fix
- From: Tom Tromey <tromey at redhat dot com>
- To: GCJ-patches <java-patches at gcc dot gnu dot org>
- Cc: GNU Classpath Patches <classpath-patches at gnu dot org>
- Date: 06 Feb 2007 11:12:03 -0700
- Subject: Patch: FYI: gjavah JNI header fix
- Reply-to: tromey at redhat dot com
I'm checking this in to Classpath, gcc svn trunk, and the RH 4.1
branch.
This fixes a buglet in gjavah. gjavah should create a JNI header even
if the class has no native methods. This is PR 30707.
Tom
Index: ChangeLog
from Tom Tromey <tromey@redhat.com>
PR libgcj/30707:
* tools/gnu/classpath/tools/javah/JniIncludePrinter.java
(printClass): Always print a header.
Index: tools/gnu/classpath/tools/javah/JniIncludePrinter.java
===================================================================
--- tools/gnu/classpath/tools/javah/JniIncludePrinter.java (revision 121660)
+++ tools/gnu/classpath/tools/javah/JniIncludePrinter.java (working copy)
@@ -1,5 +1,5 @@
/* JniIncludePrinter.java - Generate a JNI header file
- Copyright (C) 2006 Free Software Foundation, Inc.
+ Copyright (C) 2006, 2007 Free Software Foundation, Inc.
This file is part of GNU Classpath.
@@ -109,8 +109,6 @@
public void printClass(ClassWrapper klass) throws IOException
{
- if (! klass.hasNativeMethod())
- return;
String xname = JniHelper.mangle(klass.name);
JniPrintStream out
= (JniPrintStream) getPrintStream(klass.name.replace('/', '_') + ".h",