Subject: That old bugbear alpha_video.c
To: None <tech-x11@netbsd.org>
From: David Hopper <dhop@nwlink.com>
List: port-alpha
Date: 05/11/2006 21:41:29
Apologies for the cross-post, but X11 on Alpha is awfully esoteric,
it seems.
For the past week I've been hacking at compiling three codebases:
the in-tree xsrc (XFree86 4.5.0), the X.org modular 7.0 release
(haven't tried it from pkgsrc yet), and the brand shiny new XFree86
4.6.0 that was released Wednesday. They all three fail to compile on
NetBSD Alpha in various ways-- where in the past our in-tree copy of
XFree86 4.5.0 compiled fine on Alpha using 'make World' (see PR
29882), it now takes a number of gross manual hacks to get it to
produce a server binary (PR TBD). [Our in-tree 4.5.0 codebase still
wedges the multi-hose AlphaServer 1200, my main impetus to all this
madness...] I digress.
A number of brand-new NetBSD Alpha-specific fixes exist in hw/xfree86/
os-support/bsd/alpha_video.c for XFree86 4.6.0-- I have no idea on
whose machine they function, or if they have ever been tested, or are
simply theoretical code. Well, I'm testing. I get the following:
alpha_video.c:712: error: conflicting types for `xf86WriteMmio16'
../../../../../../programs/Xserver/hw/xfree86/common/compiler.h:1718:
error: previous declaration of `xf86WriteMmio16'
alpha_video.c:714: error: conflicting types for `xf86WriteMmio32'
../../../../../../programs/Xserver/hw/xfree86/common/compiler.h:1719:
error: previous declaration of `xf86WriteMmio32'
alpha_video.c:716: error: conflicting types for `xf86WriteMmioNB8'
../../../../../../programs/Xserver/hw/xfree86/common/compiler.h:1720:
error: previous declaration of `xf86WriteMmioNB8'
alpha_video.c:718: error: conflicting types for `xf86WriteMmioNB16'
../../../../../../programs/Xserver/hw/xfree86/common/compiler.h:1721:
error: previous declaration of `xf86WriteMmioNB16'
alpha_video.c:720: error: conflicting types for `xf86WriteMmioNB32'
../../../../../../programs/Xserver/hw/xfree86/common/compiler.h:1722:
error: previous declaration of `xf86WriteMmioNB32'
alpha_video.c:722: error: conflicting types for `xf86ReadMmio8'
../../../../../../programs/Xserver/hw/xfree86/common/compiler.h:1704:
error: previous declaration of `xf86ReadMmio8'
alpha_video.c:724: error: conflicting types for `xf86ReadMmio16'
../../../../../../programs/Xserver/hw/xfree86/common/compiler.h:1705:
error: previous declaration of `xf86ReadMmio16'
alpha_video.c:726: error: conflicting types for `xf86ReadMmio32'
../../../../../../programs/Xserver/hw/xfree86/common/compiler.h:1707:
error: previous declaration of `xf86ReadMmio32'
*** Error code 1
Stop.
make: stopped in /space/xfree86/build/xc/programs/Xserver/hw/xfree86/
os-support/bsd
The previous declarations from hw/xfree86/common/compiler.h:
extern void (*xf86WriteMmio8)(int, volatile void *, unsigned long);
extern void (*xf86WriteMmio16)(int, volatile void *, unsigned long);
extern void (*xf86WriteMmio32)(int, volatile void *, unsigned long);
extern void (*xf86WriteMmioNB8)(int, volatile void *, unsigned long);
extern void (*xf86WriteMmioNB16)(int, volatile void *, unsigned long);
extern void (*xf86WriteMmioNB32)(int, volatile void *, unsigned long);
The conflicting types from alpha_video.c:
void (*xf86WriteMmio8)(int Value, pointer Base, unsigned long Offset)
= writeDense8;
void (*xf86WriteMmio16)(int Value, pointer Base, unsigned long Offset)
= writeDense16;
void (*xf86WriteMmio32)(int Value, pointer Base, unsigned long Offset)
= writeDense32;
void (*xf86WriteMmioNB8)(int Value, pointer Base, unsigned long Offset)
= writeDenseNB8;
void (*xf86WriteMmioNB16)(int Value, pointer Base, unsigned long Offset)
= writeDenseNB16;
void (*xf86WriteMmioNB32)(int Value, pointer Base, unsigned long Offset)
= writeDenseNB32;
int (*xf86ReadMmio8)(pointer Base, unsigned long Offset)
= readDense8;
int (*xf86ReadMmio16)(pointer Base, unsigned long Offset)
= readDense16;
int (*xf86ReadMmio32)(pointer Base, unsigned long Offset)
= readDense32;
This presently is the *only* error keeping us from a 4.6.0 binary on
Alpha (the rest of the tree is absolutely clean of warnings). I
tried removing those previous declarations; that caused other problems.
Can anyone help me out of this rabbit hole?
Thanks,
Dave