Bug 8039

Summary: [patch] byteswap on GNU/kFreeBSD
Product: xorg Reporter: petr.salinger
Component: Server/Ext/GLXAssignee: Xorg Project Team <xorg-team>
Status: RESOLVED FIXED QA Contact: Xorg Project Team <xorg-team>
Severity: normal    
Priority: high Keywords: patch
Version: 7.1 (2006.05)   
Hardware: Other   
OS: other   
Whiteboard:
i915 platform: i915 features:

Description petr.salinger 2006-08-28 01:22:42 UTC
Hi,

GNU/kFreeBSD needs small tweak for including byteswap header.
It uses glibc as main C library, it should include the same file as Linux does.

Thanks in advance.

Petr

--- GL/glx/indirect_dispatch_swap.c~
+++ GL/glx/indirect_dispatch_swap.c
@@ -28,7 +28,7 @@
 #include <X11/Xmd.h>
 #include <GL/gl.h>
 #include <GL/glxproto.h>
-#ifdef __linux__
+#if defined (__linux__) || defined (__GLIBC__)
 #include <byteswap.h>
 #elif defined(__OpenBSD__)
 #include <sys/endian.h>

--- GL/glx/indirect_util.c~
+++ GL/glx/indirect_util.c
@@ -28,7 +28,7 @@
 #include <X11/Xmd.h>
 #include <GL/gl.h>
 #include <GL/glxproto.h>
-#ifdef __linux__
+#if defined (__linux__) || defined (__GLIBC__)
 #include <byteswap.h>
 #elif defined(__OpenBSD__)
 #include <sys/endian.h>
Comment 1 Daniel Stone 2007-02-27 01:33:22 UTC
Sorry about the phenomenal bug spam, guys.  Adding xorg-team@ to the QA contact so bugs don't get lost in future.
Comment 2 George - 2007-03-10 02:47:48 UTC
Should be fixed in HEAD. Reopen if it persists.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.