$OpenBSD: patch-hotspot_src_os_cpu_bsd_amd64_vm_bytes_bsd_amd64_inline_hpp,v 1.1.1.1 2007/05/08 17:06:18 kurt Exp $
--- hotspot/src/os_cpu/bsd_amd64/vm/bytes_bsd_amd64.inline.hpp.orig	Mon Apr 16 08:42:36 2007
+++ hotspot/src/os_cpu/bsd_amd64/vm/bytes_bsd_amd64.inline.hpp	Mon Apr 16 08:42:39 2007
@@ -28,19 +28,29 @@
 // Efficient swapping of data bytes from Java byte
 // ordering to native byte ordering and vice versa.
 
-#include <byteswap.h>
-
 inline u2 Bytes::swap_u2(u2 x) 
 {
-  return bswap_16(x);
+#ifdef __OpenBSD__
+  return swap16(x);
+#else
+  return __bswap16(x);
+#endif
 }
 
 inline u4 Bytes::swap_u4(u4 x) 
 {
-  return bswap_32(x);
+#ifdef __OpenBSD__
+  return swap32(x);
+#else
+  return __bswap32(x);
+#endif
 }
 
 inline u8 Bytes::swap_u8(u8 x) 
 {
-  return bswap_64(x);
+#ifdef __OpenBSD__
+  return swap64(x);
+#else
+  return __bswap64(x);
+#endif
 }
