classpath
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: configure failure


From: Christian Thalinger
Subject: Re: configure failure
Date: Mon, 07 Nov 2005 12:03:57 +0100

On Mon, 2005-11-07 at 11:15 +0100, Mark Wielaard wrote:
> for us. Could you try the attached patch and do
>   make distclean && ./autogen.sh && ./configure --enable-Werror
> and try if you can get any gui program working.

Yes, works fine for me.  But when we are at it (-Werror), i've some
64-bit patches.  Please review them, especially the second one.  I'm not
sure why a gpointer is passed to getThreadFromThreadID, when it's
actually an int?  Maybe that's the case in the first file too, but i'm
really lost in that code :-)

TWISTI


Index: native/jni/gtk-peer/gnu_java_awt_peer_gtk_GtkClipboard.c
===================================================================
RCS
file: 
/cvsroot/classpath/classpath/native/jni/gtk-peer/gnu_java_awt_peer_gtk_GtkClipboard.c,v
retrieving revision 1.16
diff -u -3 -p -r1.16 gnu_java_awt_peer_gtk_GtkClipboard.c
--- native/jni/gtk-peer/gnu_java_awt_peer_gtk_GtkClipboard.c    4 Sep
2005 00:03:58 -0000       1.16
+++ native/jni/gtk-peer/gnu_java_awt_peer_gtk_GtkClipboard.c    7 Nov
2005 10:53:22 -0000
@@ -53,7 +53,11 @@ jstring cp_gtk_imageTarget;
jstring cp_gtk_filesTarget;

/* Simple id to keep track of the selection we are currently managing.
*/
+#if SIZEOF_VOID_P == 8
+static long current_selection = 0;
+#else
static int current_selection = 0;
+#endif

/* Whether we "own" the clipboard. And may clear it. */
static int owner = 0;
@@ -261,7 +265,11 @@ static void
clipboard_clear_func (GtkClipboard *clipboard __attribute__((unused)),
                      gpointer user_data)
{
+#if SIZEOF_VOID_P == 8
+  if (owner && (long) user_data == current_selection)
+#else
   if (owner && (int) user_data == current_selection)
+#endif
     {
       JNIEnv *env = cp_gtk_gdk_env();
       owner = 0;
Index: native/jni/gtk-peer/gthread-jni.c
===================================================================
RCS
file: /cvsroot/classpath/classpath/native/jni/gtk-peer/gthread-jni.c,v
retrieving revision 1.20
diff -u -3 -p -r1.20 gthread-jni.c
--- native/jni/gtk-peer/gthread-jni.c   14 Jul 2005 22:07:02 -0000
1.20
+++ native/jni/gtk-peer/gthread-jni.c   7 Nov 2005 11:01:25 -0000
@@ -1258,7 +1258,7 @@ exitMonitor (JNIEnv * env, jobject mutex
static jobject
getThreadFromThreadID (JNIEnv * env, gpointer gThreadID)
{
-  jint threadNum = (jint) gThreadID;
+  jint threadNum = (jint) (jlong) gThreadID;
   jobject thread;

   if (threadNum < 0)
@@ -1305,7 +1305,7 @@ getThreadIDFromThread (JNIEnv * env, job
   SHOW_OLD_TROUBLE ();

done:
-  return (gpointer) threadNum;
+  return (gpointer) (jlong) threadNum;
}








reply via email to

[Prev in Thread] Current Thread [Next in Thread]