$OpenBSD: patch-jdk_src_share_native_com_sun_java_util_jar_pack_main_cpp,v 1.4 2009/10/07 01:53:54 kurt Exp $
--- jdk/src/share/native/com/sun/java/util/jar/pack/main.cpp.orig	Thu Sep 17 03:52:25 2009
+++ jdk/src/share/native/com/sun/java/util/jar/pack/main.cpp	Sun Sep 27 09:58:28 2009
@@ -22,6 +22,9 @@
  * CA 95054 USA or visit www.sun.com if you need additional information or
  * have any questions.
  */
+#ifdef _ALLBSD_SOURCE
+#include <stdint.h>
+#endif
 #include <sys/types.h>
 
 #include <stdio.h>
@@ -35,7 +38,7 @@
 
 #if defined(unix) && !defined(PRODUCT)
 #include "pthread.h"
-#define THREAD_SELF ((int)pthread_self())
+#define THREAD_SELF ((intptr_t) pthread_self())
 #endif
 
 #include "defines.h"
@@ -58,9 +61,9 @@ int main(int argc, char **argv) {
 // Single-threaded, implementation, not reentrant.
 // Includes a weak error check against MT access.
 #ifndef THREAD_SELF
-#define THREAD_SELF (0)
+#define THREAD_SELF ((intptr_t) 0)
 #endif
-NOT_PRODUCT(static int uThread = -1;)
+NOT_PRODUCT(static intptr_t uThread = -1;)
 
 unpacker* unpacker::non_mt_current = null;
 unpacker* unpacker::current() {
@@ -69,7 +72,7 @@ unpacker* unpacker::current() {
 }
 static void set_current_unpacker(unpacker* u) {
   unpacker::non_mt_current = u;
-  assert(((uThread = (u == null) ? -1 : THREAD_SELF),
+  assert(((uThread = (u == null) ? ((intptr_t) -1) : THREAD_SELF),
           true));
 }
 
