aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjmz <jmz@FreeBSD.org>2001-10-26 04:37:00 +0800
committerjmz <jmz@FreeBSD.org>2001-10-26 04:37:00 +0800
commitd166d806ee9104d27e9990fb5e75e133b51ffb9a (patch)
tree4c9d522ac364feee3ece0331ccc9e425601c8d13
parentfffe1e5eab08261eba94aa8fd39c72e65b76b185 (diff)
downloadfreebsd-ports-gnome-d166d806ee9104d27e9990fb5e75e133b51ffb9a.tar.gz
freebsd-ports-gnome-d166d806ee9104d27e9990fb5e75e133b51ffb9a.tar.zst
freebsd-ports-gnome-d166d806ee9104d27e9990fb5e75e133b51ffb9a.zip
Re-enable the WITH_MATROX_GXX_DRIVER option.
Submitted by: lioux
-rw-r--r--x11/XFree86-4/Makefile61
-rw-r--r--x11/XFree86-4/distinfo2
-rw-r--r--x11/XFree86-4/pkg-plist1
3 files changed, 38 insertions, 26 deletions
diff --git a/x11/XFree86-4/Makefile b/x11/XFree86-4/Makefile
index d84dd4bfd376..629444b77262 100644
--- a/x11/XFree86-4/Makefile
+++ b/x11/XFree86-4/Makefile
@@ -7,7 +7,7 @@
PORTNAME= XFree86
PORTVERSION= 4.1.0
-PORTREVISION= 8
+PORTREVISION= 9
CATEGORIES= x11
MASTER_SITES= ${MASTER_SITE_XFREE}
MASTER_SITE_SUBDIR= 4.1.0
@@ -64,10 +64,10 @@ pre-fetch:
.elif defined(USA_RESIDENT)
.if ${USA_RESIDENT} == NO
pre-fetch:
-#.ifndef WITH_MATROX_GXX_DRIVER
-# @${ECHO} Define WITH_MATROX_GXX_DRIVER if you want to enable Matrox driver for
-# @${ECHO} G200, G400 and G450 graphic adapters
-#.endif
+.ifndef WITH_MATROX_GXX_DRIVER
+ @${ECHO} Define WITH_MATROX_GXX_DRIVER if you want to enable Matrox driver for
+ @${ECHO} G200, G400, G450 and G550 graphic adapters
+.endif
MASTER_SITES+= ftp://psych.psy.uq.oz.au/pub/X11R5/ \
ftp://ftp.internat.freebsd.org/pub/FreeBSD/X11-Crypto/ \
ftp://ftp3.za.freebsd.org/pub/FreeBSD/X11-Crypto/
@@ -77,10 +77,10 @@ IGNOREFILES= Wraphelp.c
pre-fetch:
@${ECHO}
@${ECHO} Assuming that you have fetched a USA-Legal Wraphelp.c.
-#.ifndef WITH_MATROX_GXX_DRIVER
-# @${ECHO} Define WITH_MATROX_GXX_DRIVER if you want to enable Matrox driver for
-# @${ECHO} G200, G400 and G450 graphic adapters
-#.endif
+.ifndef WITH_MATROX_GXX_DRIVER
+ @${ECHO} Define WITH_MATROX_GXX_DRIVER if you want to enable Matrox driver for
+ @${ECHO} G200, G400, G450 and G550 graphic adapters
+.endif
.endif # ${USA_RESIDENT}
.endif
@@ -91,11 +91,17 @@ pre-fetch:
BROKEN= "can't be compiled on this system (missing headers)"
.endif
-#.if defined(WITH_MATROX_GXX_DRIVER)
-#MGA_DRIVER_VERSION= 1_2_0beta
-#MASTER_SITES+= ftp://ftp.matrox.com/pub/mga/archive/linux/2001/beta_${MGA_DRIVER_VERSION:S/beta//}/
-#DISTFILES+= mga-${MGA_DRIVER_VERSION}.tgz
-#.endif # WITH_MATROX_GXX_DRIVER
+.if defined(WITH_MATROX_GXX_DRIVER)
+MGA_DRIVER_VERSION= 133_143
+MGA_DRIVER_DIR= 1.4.3
+MASTER_SITES+= ftp://ftp.matrox.com/pub/mga/archive/linux/2001/beta_${MGA_DRIVER_VERSION}/
+DISTFILES+= mga-${MGA_DRIVER_VERSION}-source.tgz
+
+PLIST_SUB+= MATROX_GXX=""
+.else
+PLIST_SUB+= MATROX_GXX="@comment "
+.endif # WITH_MATROX_GXX_DRIVER
+
.if ${OSVERSION} > 500012
post-patch:
@@ -104,17 +110,22 @@ post-patch:
${SED} -e 52d -e 54d < ${WRKSRC}/include/Xarch.h.orig > \
${WRKSRC}/include/Xarch.h; fi
.endif # ${OSVERSION} > 500012
-#.if defined(WITH_MATROX_GXX_DRIVER)
-#.if !target(post-patch)
-#post-patch:
-#.endif # !target(post-patch)
-# @${MV} ${WRKSRC}/programs/Xserver/hw/xfree86/drivers/mga \
-# ${WRKSRC}/programs/Xserver/hw/xfree86/drivers/mga.old
-# @${TAR} -xzf ${DISTDIR}/${DIST_SUBDIR}/mga-${MGA_DRIVER_VERSION}.tgz \
-# -C ${WRKSRC}/programs/Xserver/hw/xfree86/drivers
-# @${CP} ${WRKSRC}/config/cf/xf86site.def ${WRKSRC}/config/cf/host.def
-# @${ECHO} "#define HaveMatroxHal YES" >> ${WRKSRC}/config/cf/host.def
-#.endif # WITH_MATROX_GXX_DRIVER
+.if defined(WITH_MATROX_GXX_DRIVER)
+.if !target(post-patch)
+post-patch:
+.endif # !target(post-patch)
+ @${MV} ${WRKSRC}/programs/Xserver/hw/xfree86/drivers/mga \
+ ${WRKSRC}/programs/Xserver/hw/xfree86/drivers/mga.old
+ @${TAR} -xzf ${DISTDIR}/${DIST_SUBDIR}/mga-${MGA_DRIVER_VERSION}-source.tgz \
+ -C ${WRKDIR}
+ @${MV} ${WRKDIR}/mgasource/mga-${MGA_DRIVER_DIR}/mga \
+ ${WRKSRC}/programs/Xserver/hw/xfree86/drivers
+ @${CP} ${WRKSRC}/config/cf/xf86site.def ${WRKSRC}/config/cf/host.def
+ @${ECHO} "#define HaveMatroxHal YES" >> ${WRKSRC}/config/cf/host.def
+ @${PERL} -pi.orig -ne 's!(#define PCI_CHIP_MGAG400\s+0x0525)!\1\n#define PCI_CHIP_MGAG550 0x2527\n!; \
+ s!({PCI_CHIP_MGAG400,\s+"MGA G400 AGP",0},)!\1\n{PCI_CHIP_MGAG550, "MGA G550 AGP", 0},\n!' \
+ ${WRKSRC}/programs/Xserver/hw/xfree86/common/xf86PciInfo.h
+.endif # WITH_MATROX_GXX_DRIVER
pre-install:
${MKDIR} ${PREFIX}
diff --git a/x11/XFree86-4/distinfo b/x11/XFree86-4/distinfo
index 0395d8cca2f6..4afd750ec074 100644
--- a/x11/XFree86-4/distinfo
+++ b/x11/XFree86-4/distinfo
@@ -1,4 +1,4 @@
MD5 (xc/X410src-1.tgz) = 2d4709f7106a1d65c175be445a3d3c32
MD5 (xc/X410src-2.tgz) = beaffed1cbdb700e5fed6a5490a7f222
-MD5 (xc/mga-1_2_0beta.tgz) = ef6e33551a2fad0a58d41c1bca2325f4
+MD5 (xc/mga-133_143-source.tgz) = 849bf57f23f1684fea970459f919d1f2
MD5 (xc/Wraphelp.c) = IGNORE
diff --git a/x11/XFree86-4/pkg-plist b/x11/XFree86-4/pkg-plist
index dea046f5dfec..b06bd99bdbb7 100644
--- a/x11/XFree86-4/pkg-plist
+++ b/x11/XFree86-4/pkg-plist
@@ -6481,6 +6481,7 @@ lib/modules/drivers/i128_drv.o
lib/modules/drivers/i740_drv.o
lib/modules/drivers/i810_drv.o
lib/modules/drivers/mga_drv.o
+%%MATROX_GXX%%lib/modules/drivers/mga_hal_drv.o
lib/modules/drivers/neomagic_drv.o
lib/modules/drivers/nv_drv.o
lib/modules/drivers/r128_drv.o