summaryrefslogtreecommitdiff
path: root/extra/mesa/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'extra/mesa/PKGBUILD')
-rw-r--r--extra/mesa/PKGBUILD318
1 files changed, 84 insertions, 234 deletions
diff --git a/extra/mesa/PKGBUILD b/extra/mesa/PKGBUILD
index e7c0a4029..51a0e0fe4 100644
--- a/extra/mesa/PKGBUILD
+++ b/extra/mesa/PKGBUILD
@@ -1,46 +1,29 @@
-# $Id: PKGBUILD 175899 2013-01-23 16:58:37Z andyrtr $
+# $Id: PKGBUILD 178616 2013-02-25 20:44:59Z andyrtr $
# Maintainer: Jan de Groot <jgc@archlinux.org>
# Maintainer: Andreas Radke <andyrtr@archlinux.org>
pkgbase=mesa
-pkgname=('libglapi' 'libgl' 'mesa' 'osmesa' 'libgbm' 'libgles' 'libegl' 'khrplatform-devel' 'ati-dri' 'intel-dri' 'svga-dri' 'nouveau-dri')
-
-#_git=true
-#_gitdate=20121006
-_git=false
-
-if [ "${_git}" = "true" ]; then
- pkgver=8.99.git_$_gitdate
- else
- pkgver=9.0.2
-fi
-pkgrel=1
+pkgname=('ati-dri' 'intel-dri' 'nouveau-dri' 'svga-dri' 'mesa' 'mesa-libgl')
+pkgver=9.1
+pkgrel=2
arch=('i686' 'x86_64')
-makedepends=('glproto>=1.4.16' 'libdrm>=2.4.39' 'libxxf86vm>=1.1.2' 'libxdamage>=1.1.3' 'expat>=2.1.0' 'libx11>=1.5.0' 'libxt>=1.1.3'
- 'gcc-libs>=4.7.1-6' 'dri2proto>=2.8' 'python2' 'libxml2' 'imake' 'llvm-amdgpu-snapshot' 'systemd' 'libvdpau>=0.5')
+makedepends=('python2' 'libxml2' 'libx11' 'glproto' 'libdrm' 'dri2proto' 'libxxf86vm' 'libxdamage'
+ 'libvdpau' 'wayland' 'llvm-amdgpu-snapshot')
url="http://mesa3d.sourceforge.net"
license=('custom')
options=('!libtool')
-source=(LICENSE llvm32.patch)
-if [ "${_git}" = "true" ]; then
- # mesa git shot from 9.0 branch - see for state: http://cgit.freedesktop.org/mesa/mesa/log/?h=9.0
- #source=(${source[@]} 'ftp://ftp.archlinux.org/other/mesa/mesa-41d14eaf193c6b1eb87fe1998808a887f1c6c698.tar.gz')
- source=(${source[@]} "MesaLib-git${_gitdate}.zip"::"http://cgit.freedesktop.org/mesa/mesa/snapshot/mesa-7851d398def2df3f6836a500d67123eed50f3943.tar.gz")
- else
- source=(${source[@]} "ftp://ftp.freedesktop.org/pub/mesa/${pkgver}/MesaLib-${pkgver}.tar.bz2"
- #source=(${source[@]} "ftp://ftp.freedesktop.org/pub/mesa/8.0/MesaLib-8.0-rc2.tar.bz2"
-)
-fi
-md5sums=('5c65a0fe315dd347e09b1f2826a1df5a'
- '5fe9ad0c5beed19bc98d8c34aaad4ade'
- 'dc45d1192203e418163e0017640e1cfc')
+source=(ftp://ftp.freedesktop.org/pub/mesa/${pkgver}/MesaLib-${pkgver}.tar.bz2
+ #ftp://ftp.freedesktop.org/pub/mesa/9.1/MesaLib-9.1-rc2.tar.bz2 # for RC testing
+ LICENSE)
+md5sums=('d3891e02215422e120271d976ff1947e'
+ '5c65a0fe315dd347e09b1f2826a1df5a')
build() {
cd ${srcdir}/?esa-*
-
- patch -Np1 -i ${srcdir}/llvm32.patch
- COMMONOPTS="--prefix=/usr \
+ autoreconf -vfi # our automake is far too new for their build system :)
+
+ ./configure --prefix=/usr \
--sysconfdir=/etc \
--with-dri-driverdir=/usr/lib/xorg/modules/dri \
--with-gallium-drivers=r300,r600,radeonsi,nouveau,svga,swrast \
@@ -48,7 +31,7 @@ build() {
--enable-gallium-llvm \
--enable-egl \
--enable-gallium-egl \
- --with-egl-platforms=x11,drm \
+ --with-egl-platforms=x11,drm,wayland \
--enable-shared-glapi \
--enable-gbm \
--enable-glx-tls \
@@ -59,240 +42,107 @@ build() {
--enable-gles2 \
--enable-texture-float \
--enable-xa \
- --enable-vdpau "
-
-# not default:
-# --enable-gallium-egl enable optional EGL state tracker (not required for
-# EGL support in Gallium with OpenGL and OpenGL ES)
-# [default=disable]
-# --enable-xa enable build of the XA X Acceleration API [default=no]
-
-
-if [ "${_git}" = "true" ]; then
- ./autogen.sh \
- $COMMONOPTS
- else
- autoreconf -vfi
- ./configure \
- $COMMONOPTS
-fi
-
- # fix a build break with new llvm
- sed -i "s:-Werror=implicit-function-declaration::" src/gallium/drivers/r600/Makefile
+ --enable-vdpau \
+ # --help
+ # --with-llvm-shared-libs \ # enabling this would force us to move llvm-amdgpu-snapshot from community to extra, delay it until llvm 3.3 / Mesa 9.2/10.0
make
-}
-
-package_libglapi() {
- depends=('glibc')
- pkgdesc="free implementation of the GL API -- shared library. The Mesa GL API module is responsible for dispatching all the gl* functions"
-
- make -C ${srcdir}/?esa-*/src/mapi/shared-glapi DESTDIR="${pkgdir}" install
-
- install -m755 -d "${pkgdir}/usr/share/licenses/libglapi"
- install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/libglapi/"
-}
-
-package_libgl() {
- depends=('libdrm>=2.4.39' 'libxxf86vm>=1.1.2' 'libxdamage>=1.1.3' 'expat>=2.1.0' 'libglapi' 'gcc-libs')
- pkgdesc="Mesa 3-D graphics library and DRI software rasterizer"
-
- # fix linking because of splitted package
- make -C ${srcdir}/?esa-*/src/mapi/shared-glapi DESTDIR="${pkgdir}" install
-
- # libGL & libdricore
- make -C ${srcdir}/?esa-*/src/glx DESTDIR="${pkgdir}" install
- make -C ${srcdir}/?esa-*/src/mesa/libdricore DESTDIR="${pkgdir}" install
-
- # fix linking because of splitted package - cleanup
- make -C ${srcdir}/?esa-*/src/mapi/shared-glapi DESTDIR="${pkgdir}" uninstall
-
-
- make -C ${srcdir}/?esa-*/src/gallium/targets/dri-swrast DESTDIR="${pkgdir}" install
-
- # See FS#26284
- install -m755 -d "${pkgdir}/usr/lib/xorg/modules/extensions"
- ln -s libglx.xorg "${pkgdir}/usr/lib/xorg/modules/extensions/libglx.so"
-
- install -m755 -d "${pkgdir}/usr/share/licenses/libgl"
- install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/libgl/"
-}
-
-package_mesa() {
- # check also gl.pc
- depends=('libgl' 'libx11>=1.5.0' 'libxext>=1.3.1' 'libxdamage' 'libxfixes' 'libxcb' 'libxxf86vm')
- optdepends=('opengl-man-pages: for the OpenGL API man pages')
- pkgdesc="Mesa 3-D graphics libraries and include files"
-
- make -C ${srcdir}/?esa-*/src/mesa DESTDIR="${pkgdir}" install-glHEADERS
- make -C ${srcdir}/?esa-*/src/mesa/drivers/dri DESTDIR="${pkgdir}" install-driincludeHEADERS
- make -C ${srcdir}/?esa-*/src/mesa DESTDIR="${pkgdir}" install-pkgconfigDATA
- make -C ${srcdir}/?esa-*/src/mesa/drivers/dri DESTDIR="${pkgdir}" install-pkgconfigDATA
- make -C ${srcdir}/?esa-*/src/mesa/drivers/dri/common DESTDIR="${pkgdir}" install-sysconfDATA
-
- make -C ${srcdir}/?esa-*/src/gallium/targets/xa-vmwgfx DESTDIR="${pkgdir}" install
-
- install -m755 -d "${pkgdir}/usr/share/licenses/mesa"
- install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/mesa/"
-}
-
-package_osmesa() {
- depends=('libglapi' 'gcc-libs')
- optdepends=('opengl-man-pages: for the OpenGL API man pages')
- pkgdesc="Mesa 3D off-screen rendering library"
-
- # fix linking because of splitted package
- make -C ${srcdir}/?esa-*/src/mapi/shared-glapi DESTDIR="${pkgdir}" install
-
- make -C ${srcdir}/?esa-*/src/mesa/drivers/osmesa DESTDIR="${pkgdir}" install
-
- # fix linking because of splitted package - cleanup
- make -C ${srcdir}/?esa-*/src/mapi/shared-glapi DESTDIR="${pkgdir}" uninstall
-
- install -m755 -d "${pkgdir}/usr/share/licenses/osmesa"
- install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/osmesa/"
-}
-
-package_libgbm() {
- depends=('systemd' 'libglapi' 'libdrm')
- pkgdesc="Mesa gbm library"
-
- # fix linking because of splitted package
- make -C ${srcdir}/?esa-*/src/mapi/shared-glapi DESTDIR="${pkgdir}" install
-
- make -C ${srcdir}/?esa-*/src/gbm DESTDIR="${pkgdir}" install
-
- # fix linking because of splitted package - cleanup
- make -C ${srcdir}/?esa-*/src/mapi/shared-glapi DESTDIR="${pkgdir}" uninstall
-
- install -m755 -d "${pkgdir}/usr/share/licenses/libgbm"
- install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/libgbm/"
-}
-
-package_libgles() {
- depends=('libglapi' 'libdrm' 'khrplatform-devel')
- pkgdesc="Mesa GLES libraries and headers"
-
- # fix linking because of splitted package
- make -C ${srcdir}/?esa-*/src/mapi/shared-glapi DESTDIR="${pkgdir}" install
-
- make -C ${srcdir}/?esa-*/src/mapi/es1api DESTDIR="${pkgdir}" install
- make -C ${srcdir}/?esa-*/src/mapi/es2api DESTDIR="${pkgdir}" install
-
- # fix linking because of splitted package - cleanup
- make -C ${srcdir}/?esa-*/src/mapi/shared-glapi DESTDIR="${pkgdir}" uninstall
-
- install -m755 -d "${pkgdir}/usr/share/licenses/libgles"
- install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/libgles/"
-}
-
-package_libegl() {
- # check also egl.pc
- depends=('libx11' 'libxext' 'libxdamage' 'libxfixes' 'libxxf86vm' 'libxcb' 'libgbm' 'khrplatform-devel')
- pkgdesc="Mesa EGL libraries and headers"
-
- make -C ${srcdir}/?esa-*/src/gallium/targets/egl-static DESTDIR="${pkgdir}" install
- install -m755 -d "${pkgdir}/usr/share/doc/libegl"
- install -m644 ${srcdir}/?esa-*/docs/egl.html "${pkgdir}/usr/share/doc/libegl/"
-
- # fix linking because of splitted package
- make -C ${srcdir}/?esa-*/src/mapi/shared-glapi DESTDIR="${pkgdir}" install
- make -C ${srcdir}/?esa-*/src/gbm DESTDIR="${pkgdir}" install
-
- make -C ${srcdir}/?esa-*/src/egl DESTDIR="${pkgdir}" install
-
- # fix linking because of splitted package - cleanup
- make -C ${srcdir}/?esa-*/src/gbm DESTDIR="${pkgdir}" uninstall
- make -C ${srcdir}/?esa-*/src/mapi/shared-glapi DESTDIR="${pkgdir}" uninstall
-
- install -m755 -d "${pkgdir}/usr/share/licenses/libegl"
- install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/libegl/"
-
- # fix file conflicts
- rm -rf ${pkgdir}/usr/include/KHR
-}
-
-package_khrplatform-devel() {
- pkgdesc="Khronos platform development package"
-
- install -m755 -d "${pkgdir}/usr/include/KHR"
- install -m644 ${srcdir}/?esa-*/include/KHR/khrplatform.h "${pkgdir}/usr/include/KHR/"
-
- install -m755 -d "${pkgdir}/usr/share/licenses/khrplatform-devel"
- install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/khrplatform-devel/"
+ # fake installation
+ mkdir $srcdir/fakeinstall
+ make DESTDIR=${srcdir}/fakeinstall install
}
package_ati-dri() {
- depends=("libgl=${pkgver}")
- pkgdesc="Mesa DRI radeon/r200 + Gallium3D r300,r600 drivers for AMD/ATI Radeon"
+ pkgdesc="Mesa drivers for AMD/ATI Radeon"
+ depends=("mesa-libgl=${pkgver}")
conflicts=('xf86-video-ati<6.9.0-6')
- # fix linking because of splitted package
- make -C ${srcdir}/?esa-*/src/mesa/libdricore DESTDIR="${pkgdir}" install
-
- # classic mesa drivers for radeon,r200
- make -C ${srcdir}/?esa-*/src/mesa/drivers/dri/radeon DESTDIR="${pkgdir}" install
- make -C ${srcdir}/?esa-*/src/mesa/drivers/dri/r200 DESTDIR="${pkgdir}" install
- # gallium3D driver for r300,r600,radeonsi
- make -C ${srcdir}/?esa-*/src/gallium/targets/dri-r300 DESTDIR="${pkgdir}" install
- make -C ${srcdir}/?esa-*/src/gallium/targets/dri-r600 DESTDIR="${pkgdir}" install
- make -C ${srcdir}/?esa-*/src/gallium/targets/dri-radeonsi DESTDIR="${pkgdir}" install
- # vdpau driver
- make -C ${srcdir}/?esa-*/src/gallium/targets/vdpau-r300 DESTDIR="${pkgdir}" install
- make -C ${srcdir}/?esa-*/src/gallium/targets/vdpau-r600 DESTDIR="${pkgdir}" install
- make -C ${srcdir}/?esa-*/src/gallium/targets/vdpau-radeonsi DESTDIR="${pkgdir}" install
-
- # fix linking because of splitted package - cleanup
- make -C ${srcdir}/?esa-*/src/mesa/libdricore DESTDIR="${pkgdir}" uninstall
+ install -m755 -d ${pkgdir}/usr/lib/vdpau/
+ mv -v ${srcdir}/fakeinstall/usr/lib/vdpau/libvdpau_{r300,r600,radeonsi}.* ${pkgdir}/usr/lib/vdpau/
+ install -m755 -d ${pkgdir}/usr/lib/xorg/modules/dri
+ mv -v ${srcdir}/fakeinstall/usr/lib/xorg/modules/dri/{r200,r300,r600,radeon,radeonsi}_dri.so ${pkgdir}/usr/lib/xorg/modules/dri/
+
+ install -m755 -d ${pkgdir}/usr/lib/gallium-pipe
+ mv -v ${srcdir}/fakeinstall/usr/lib/gallium-pipe/pipe_{r300,r600,radeonsi}* ${pkgdir}/usr/lib/gallium-pipe/
+
install -m755 -d "${pkgdir}/usr/share/licenses/ati-dri"
install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/ati-dri/"
}
package_intel-dri() {
- depends=("libgl=${pkgver}")
- pkgdesc="Mesa DRI drivers for Intel"
+ pkgdesc="Mesa drivers for Intel"
+ depends=("mesa-libgl=${pkgver}")
- # fix linking because of splitted package
- make -C ${srcdir}/?esa-*/src/mesa/libdricore DESTDIR="${pkgdir}" install
+ install -m755 -d ${pkgdir}/usr/lib/xorg/modules/dri
+ mv -v ${srcdir}/fakeinstall/usr/lib/xorg/modules/dri/{i915,i965}_dri.so ${pkgdir}/usr/lib/xorg/modules/dri/
- make -C ${srcdir}/?esa-*/src/mesa/drivers/dri/i915 DESTDIR="${pkgdir}" install
- make -C ${srcdir}/?esa-*/src/mesa/drivers/dri/i965 DESTDIR="${pkgdir}" install
-
- # fix linking because of splitted package - cleanup
- make -C ${srcdir}/?esa-*/src/mesa/libdricore DESTDIR="${pkgdir}" uninstall
-
install -m755 -d "${pkgdir}/usr/share/licenses/intel-dri"
install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/intel-dri/"
}
package_nouveau-dri() {
- depends=("libgl=${pkgver}")
- pkgdesc="Mesa classic DRI + Gallium3D drivers for Nouveau"
+ pkgdesc="Mesa drivers for Nouveau"
+ depends=("mesa-libgl=${pkgver}")
- # fix linking because of splitted package
- make -C ${srcdir}/?esa-*/src/mesa/libdricore DESTDIR="${pkgdir}" install
+ install -m755 -d ${pkgdir}/usr/lib/vdpau/
+ mv -v ${srcdir}/fakeinstall/usr/lib/vdpau/libvdpau_nouveau.* ${pkgdir}/usr/lib/vdpau/
- # classic mesa driver for nv10 , nv20 nouveau_vieux_dri.so
- make -C ${srcdir}/?esa-*/src/mesa/drivers/dri/nouveau DESTDIR="${pkgdir}" install
- # gallium3D driver for nv30 - nv40 - nv50 nouveau_dri.so
- make -C ${srcdir}/?esa-*/src/gallium/targets/dri-nouveau DESTDIR="${pkgdir}" install
- # vdpau driver
- make -C ${srcdir}/?esa-*/src/gallium/targets/vdpau-nouveau DESTDIR="${pkgdir}" install
+ install -m755 -d ${pkgdir}/usr/lib/xorg/modules/dri
+ mv -v ${srcdir}/fakeinstall/usr/lib/xorg/modules/dri/nouveau_{dri,vieux_dri}.so ${pkgdir}/usr/lib/xorg/modules/dri/
- # fix linking because of splitted package - cleanup
- make -C ${srcdir}/?esa-*/src/mesa/libdricore DESTDIR="${pkgdir}" uninstall
+ install -m755 -d ${pkgdir}/usr/lib/gallium-pipe
+ mv -v ${srcdir}/fakeinstall/usr/lib/gallium-pipe/pipe_nouveau* ${pkgdir}/usr/lib/gallium-pipe/
install -m755 -d "${pkgdir}/usr/share/licenses/nouveau-dri"
install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/nouveau-dri/"
}
package_svga-dri() {
- depends=('gcc-libs' 'libdrm' 'expat')
pkgdesc="Gallium3D VMware guest GL driver"
+ depends=('gcc-libs' 'libdrm' 'expat' 'libffi')
+
+ install -m755 -d ${pkgdir}/usr/lib/xorg/modules/dri
+ mv -v ${srcdir}/fakeinstall/usr/lib/xorg/modules/dri/vmwgfx_dri.so ${pkgdir}/usr/lib/xorg/modules/dri/
- make -C ${srcdir}/?esa-*/src/gallium/targets/dri-vmwgfx DESTDIR="${pkgdir}" install
+ install -m755 -d ${pkgdir}/usr/lib/gallium-pipe
+ mv -v ${srcdir}/fakeinstall/usr/lib/gallium-pipe/pipe_vmwgfx* ${pkgdir}/usr/lib/gallium-pipe/
install -m755 -d "${pkgdir}/usr/share/licenses/svga-dri"
install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/svga-dri/"
}
+
+package_mesa() {
+ pkgdesc="an open-source implementation of the OpenGL specification"
+ depends=('libdrm' 'libvdpau' 'wayland' 'libxxf86vm' 'libxdamage' 'systemd')
+ optdepends=('opengl-man-pages: for the OpenGL API man pages')
+ provides=('libglapi' 'osmesa' 'libgbm' 'libgles' 'libegl' 'khrplatform-devel')
+ conflicts=('libglapi' 'osmesa' 'libgbm' 'libgles' 'libegl' 'khrplatform-devel')
+ replaces=('libglapi' 'osmesa' 'libgbm' 'libgles' 'libegl' 'khrplatform-devel')
+
+ mv -v ${srcdir}/fakeinstall/* ${pkgdir}
+ # rename libgl.so to not conflict with blobs - may break gl.pc ?
+ mv ${pkgdir}/usr/lib/libGL.so.1.2.0 ${pkgdir}/usr/lib/mesa-libGL.so.1.2.0
+ rm ${pkgdir}/usr/lib/libGL.so{,.1}
+
+ install -m755 -d "${pkgdir}/usr/share/licenses/mesa"
+ install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/mesa/"
+}
+
+package_mesa-libgl() {
+ pkgdesc="Mesa 3-D graphics library"
+ depends=("mesa=${pkgver}")
+ provides=("libgl=${pkgver}")
+ replaces=('libgl')
+
+ # See FS#26284
+ install -m755 -d "${pkgdir}/usr/lib/xorg/modules/extensions"
+ ln -s libglx.xorg "${pkgdir}/usr/lib/xorg/modules/extensions/libglx.so"
+
+ ln -s mesa-libGL.so.1.2.0 ${pkgdir}/usr/lib/libGL.so
+ ln -s mesa-libGL.so.1.2.0 ${pkgdir}/usr/lib/libGL.so.1
+ ln -s mesa-libGL.so.1.2.0 ${pkgdir}/usr/lib/libGL.so.1.2.0
+
+ install -m755 -d "${pkgdir}/usr/share/licenses/mesa-libgl"
+ install -m644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/mesa-libgl/"
+}