1#	$NetBSD: Makefile,v 1.2 2012/11/18 08:24:02 apb Exp $
2
3DRIVER=		xf86-video-xgi
4DRIVER_NAME=	xgi_drv
5
6SRCS=		init.c vb_ext.c vb_i2c.c vb_setmode.c xgi_accel.c
7#SRC+=		vb_init.c
8SRCS+=		xgi_cursor.c  xgi_dac.c xgi_dga.c xgi_driver.c xgi_opt.c
9SRCS+=		xgi_setup.c  xgi_vb.c xgi_vga.c xgi_video.c xgi_videohw.c
10
11MAN=		xgi.4
12
13CPPFLAGS+=	-I${DESTDIR}${X11INCDIR}/X11
14CPPFLAGS+=	-I${DESTDIR}${X11INCDIR}/X11/dri
15CPPFLAGS+=	-I${DESTDIR}${X11INCDIR}/libdrm
16# for now, I'd like to see this thing work first
17CPPFLAGS+=	-DHAVE_UNISTD_H -Wno-deprecated-declarations
18
19# vb_struct.h contains this declaration:
20#
21#	typedef struct _XGI_CRT1TableStruct
22#	{
23#	  UCHAR CR[15];
24#	} XGI_CRT1TableStruct;
25#
26# but code in init.c and vb_setmode.c reads elements beyond the end of
27# the array and writes the result into hardware registers.  It's not
28# clear how to fix this, so just disable the -Warray-bounds warning to
29# allow the build to complete.
30#
31COPTS.init.c=          -Wno-array-bounds
32COPTS.vb_setmode.c=    -Wno-array-bounds
33
34.include "../Makefile.xf86-driver"
35