pkgsrc-Bugs archive

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

pkg/39359: graphics/MesaLib with "dri" fails for big-endian systems

>Number:         39359
>Category:       pkg
>Synopsis:       graphics/MesaLib with "dri" fails for big-endian systems
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Aug 15 20:15:00 +0000 2008
>Originator:     Kernigh
>Release:        NetBSD 4.0 with pkgsrc-2008Q2
System: NetBSD ghostborough.local 4.0 NetBSD 4.0 (GENERIC) #0: Sun Dec 16 
00:27:58 PST 2007 
Architecture: powerpc
Machine: macppc
Using pkgsrc-2008Q2, when I built the driver x11/xf86-video-ati, it brought
in graphics/MesaLib as a dependency. I had enabled the "dri" option. (My
NetBSD kernel has no DRM, so DRI does not work, but I enabled "dri" anyway.)

The build of graphics/MesaLib failed in two places under the
/usr/pkgsrc/graphics/MesaLib/work/Mesa-7.0.3/src/mesa/drivers/dri directory.
In dri/mach64/mach64_context.h there is a part that reads

#include <byteswap.h>
#define LE32_IN( x )            bswap_32( *(GLuint *)(x) )

My powerpc machine is big-endian, so the compiler entered the #else section
and tried to #include <byteswap.h>. The error was the missing "byteswap.h"
file. I do not seem to have a "byteswap.h" file in the Mesa sources or
anywhere on my computer.

When I bypassed that first error, I received a second error in
dri/sis/sis_context.h where it reads

#if defined(__i386__) || defined(__amd64__)
#define MMIO_WMB()      __asm __volatile("" : : : "memory")
#error platform needs WMB

Because my machine is not i386 nor amd64, the compiler stepped on the #error

$ cat /etc/mk.conf
$ cd /usr/pkgsrc/x11/xf86-video-ati
$ sudo make

with x11/xf86-video-ati building graphics/MesaLib as a dependency.

I only have the following work-around to bypass the mach64 and sis drivers.
When the build fails at the first error, then move the mach64 and sis
drivers away,

$ cd /usr/pkgsrc/graphics/MesaLib/work/Mesa-7.0.3/src/mesa/drivers/dri
$ sudo mv mach64-off
$ sudo mv sis-off

then go back to x11/xf86-video-ati and restart the build. The Makefile will
skip the mach64 and sis directories as it notices that they went missing.

Home | Main Index | Thread Index | Old Index