Magellan Linux

Contents of /smage/branches/alx07x-stable/core/opengl-update/opengl-update-2.3.11-r2.smage2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 11257 - (show annotations) (download)
Tue Dec 19 12:04:57 2017 UTC (6 years, 4 months ago) by niro
File size: 1991 byte(s)
-release branches/alx07x-stable
1 # $Id$
2
3 PNAME="opengl-update"
4 PVER="2.3.11"
5 PBUILD="r2"
6
7 PCAT="x11-base"
8
9 DESCRIPTION="Updates your X11 OpenGL backend."
10 HOMEPAGE="http://www.magellan-linux.de/"
11
12 ALX_PKG_KEEP="usr/sbin"
13 sminclude mbuild mtools alx-split
14 msetfeature "!check"
15
16 DEPEND=">= virtual/glibc"
17
18 SRCFILE="${PNAME}-${PVER}.tar.bz2"
19 SRCDIR="${BUILDDIR}/${PNAME}-${PVER}"
20
21 # http://oss.sgi.com/projects/ogl-sample/ABI/glext.h
22 # http://oss.sgi.com/projects/ogl-sample/ABI/glxext.h
23 # or the newest with opengl-2.1 at:
24 # http://www.opengl.org/registry/api/glext.h
25 # http://www.opengl.org/registry/api/glxext.h
26 SRC_URI=( mirror://${PNAME}/${SRCFILE} )
27
28 preinstall()
29 {
30 if [[ ! -z $(magequery -n opengl-update-magellan) ]]
31 then
32 echo -e ${COLRED}
33 echo -e "Error: x11-base/opengl-update-magellan is installed!!"
34 echo -e "opengl-update-magellan was renamed to opengl-update."
35 echo -e "Please uninstall x11-base/opengl-update-magellan first!"
36 echo -e ${COLDEFAULT}
37 die "x11-base/opengl-update-magellan found!"
38 fi
39
40 # the location has changed to 03opengl
41 if [ -f ${MROOT}/etc/env.d/09opengl ]
42 then
43 mv ${MROOT}/etc/env.d/09opengl ${MROOT}/etc/env.d/03opengl
44 fi
45
46 if [ -e /usr/$(mlibdir)/opengl/xorg/lib/libMesaGL.so ]
47 then
48 echo "Removing libMesaGL.so from xorg profile."
49 rm -f ${MROOT}/usr/$(mlibdir)/opengl/xorg/lib/libMesaGL.so
50 fi
51
52 if [ -e ${MROOT}/usr/$(mlibdir)/libMesaGL.so ]
53 then
54 echo "Removing libMesaGL.so from /usr/lib."
55 rm -f ${MROOT}/usr/$(mlibdir)/libMesaGL.so
56 fi
57
58 local i
59 for i in ${MROOT}/usr/$(mlibdir)/libGL.so.* \
60 ${MROOT}/usr/$(mlibdir)/libGLcore.so.* \
61 ${MROOT}/usr/$(mlibdir)/libnvidia-tls* \
62 ${MROOT}/usr/$(mlibdir)/tls/libnvidia-tls*
63 do
64 [[ -e ${i} ]] && rm -f ${i}
65 done
66 }
67
68 postinstall()
69 {
70 local impl="$(${MROOT}/usr/sbin/opengl-update --get-implementation)"
71 if [[ -n ${impl} ]]
72 then
73 ${MROOT}/usr/sbin/opengl-update ${impl}
74 fi
75 impl="$(${MROOT}/usr/sbin/dri-update --get-implementation)"
76 if [[ -n ${impl} ]]
77 then
78 ${MROOT}/usr/sbin/dri-update ${impl}
79 fi
80 }