[46420] trunk/dports/x11/mesa/Portfile
jeremyhu at macports.org
jeremyhu at macports.org
Wed Feb 4 10:47:25 PST 2009
Revision: 46420
http://trac.macports.org/changeset/46420
Author: jeremyhu at macports.org
Date: 2009-02-04 10:47:24 -0800 (Wed, 04 Feb 2009)
Log Message:
-----------
mesa: Added support for libGL doing HW rendering enabled by default on Leopard and later (I haven't tested it on Tiger, so Tiger's using the old SW renderer by default).
Modified Paths:
--------------
trunk/dports/x11/mesa/Portfile
Modified: trunk/dports/x11/mesa/Portfile
===================================================================
--- trunk/dports/x11/mesa/Portfile 2009-02-04 18:33:01 UTC (rev 46419)
+++ trunk/dports/x11/mesa/Portfile 2009-02-04 18:47:24 UTC (rev 46420)
@@ -4,22 +4,30 @@
name mesa
version 7.2
-revision 1
+revision 2
+set ASGLX_version 48
categories x11 graphics
-maintainers jeremyhu andrea.damore
+maintainers jeremyhu andrea.damore openmaintainer
description Mesa 3D Graphics Library
long_description Mesa is an open-source implementation of the OpenGL specification, a system for rendering interactive 3D graphics.
homepage http://mesa3d.sourceforge.net/
-distfiles MesaLib-${version}.tar.bz2
+distfiles MesaLib-${version}.tar.bz2:mesa \
+ AppleSGLX-${ASGLX_version}.tar.bz2:xq
worksrcdir Mesa-${version}
-platforms darwin
+platforms macosx darwin
use_bzip2 yes
-master_sites sourceforge:mesa3d
+master_sites sourceforge:mesa3d:mesa \
+ http://xquartz.macosforge.org/downloads/src/:xq
-checksums md5 04d379292e023df0b0266825cb0dbde5 \
- sha1 a6dce814cc56a562890ab79cf4e205f62459a29c \
- rmd160 1e7c2cc6aa27ebaf7e726ac2086c10a5155d0832
+checksums MesaLib-7.2.tar.bz2 \
+ md5 04d379292e023df0b0266825cb0dbde5 \
+ sha1 a6dce814cc56a562890ab79cf4e205f62459a29c \
+ rmd160 1e7c2cc6aa27ebaf7e726ac2086c10a5155d0832 \
+ AppleSGLX-48.tar.bz2 \
+ md5 30e172ba7f4afd08131c3d79319297b7 \
+ sha1 5acd07db348a37348022761321616ec2d431553b \
+ rmd160 d629460f877aa0a748f7b60925ee13a9343a93cf
patch.pre_args -p1
patchfiles \
@@ -48,6 +56,10 @@
build.args-append RC_ARCHS="${universal_archs}"
}
+if {${os.major} >= 9 && ! [variant_isset system_x11]} {
+ default_variants +hw_render
+}
+
if {! [variant_isset system_x11]} {
post-extract {
if {! [file exists "${worksrcpath}/configs/current"]} {
@@ -55,13 +67,23 @@
}
}
+ # This next hunk supports building -system_x11 mesa on a system that is otherwise +system_x11
if {! [file exists ${prefix}/lib/libX11.dylib]} {
build.args-append X11_DIR=${x11prefix}
destroot.args-append X11_DIR=${x11prefix}
}
}
-variant system_x11 description {Install a stub package to use the system X11 libraries rather than MacPorts} {
+variant hw_render conflicts system_x11 description {Install a libGL.dylib that} {
+ post-build {
+ system "cd ${worksrcpath}/../AppleSGLX-${ASGLX_version} && ${build.cmd} ${build.args}"
+ }
+ post-destroot {
+ system "cd ${worksrcpath}/../AppleSGLX-${ASGLX_version} && ${destroot.cmd} ${destroot.target} ${destroot.destdir} ${destroot.args}"
+ }
+}
+
+variant system_x11 conflicts hw_render description {Install a stub package to use the system X11 libraries rather than MacPorts} {
build.args-append X11_DIR=${x11prefix}
destroot.args-append X11_DIR=${x11prefix}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20090204/563c5a8a/attachment.html>
More information about the macports-changes
mailing list