# $Id$ PNAME="opengl-update-magellan" PVER="2.2.11" PBUILD="r1" PCATEGORIE="x11-base" STATE="unstable" DESCRIPTION="Updates your X11 OpenGL backend." HOMEPAGE="http://www.magellan-linux.de/" sminclude mbuild mtools DEPEND=">= virtual/glibc" SRCFILE="${PNAME}-${PVER}.tar.bz2" SRCDIR="${BUILDDIR}/${PNAME}-${PVER}" # http://oss.sgi.com/projects/ogl-sample/ABI/glext.h # http://oss.sgi.com/projects/ogl-sample/ABI/glxext.h # or the newest with opengl-2.1 at: # http://www.opengl.org/registry/api/glext.h # http://www.opengl.org/registry/api/glxext.h SRC_URI=( mirror://${PNAME}/${SRCFILE} ) src_compile() { cd ${SRCDIR} mmake || die } preinstall() { # the location has changed to 03opengl [ -f ${MROOT}/etc/env.d/09opengl ] && \ mv ${MROOT}/etc/env.d/09opengl ${MROOT}/etc/env.d/03opengl if [ -e /usr/$(mlibdir)/opengl/xorg/lib/libMesaGL.so ] then echo "Removing libMesaGL.so from xorg profile." rm -f ${MROOT}/usr/$(mlibdir)/opengl/xorg/lib/libMesaGL.so fi if [ -e ${MROOT}/usr/$(mlibdir)/libMesaGL.so ] then echo "Removing libMesaGL.so from /usr/lib." rm -f ${MROOT}/usr/$(mlibdir)/libMesaGL.so fi local i for i in ${MROOT}/usr/$(mlibdir)/libGL.so.* \ ${MROOT}/usr/$(mlibdir)/libGLcore.so.* \ ${MROOT}/usr/$(mlibdir)/libnvidia-tls* \ ${MROOT}/usr/$(mlibdir)/tls/libnvidia-tls* do [[ -e ${i} ]] && rm -f ${i} done } postinstall() { local impl="$(${MROOT}/usr/sbin/opengl-update --get-implementation)" if [[ -n ${impl} ]] then ${MROOT}/usr/sbin/opengl-update ${impl} fi }