Commit de6c3348 authored by kwm's avatar kwm
Browse files

Update Mesa port to 10.6.6 and add Clover.

Add beignet 1.1.0.
Add clinfo, clblas, clfft and clrng.

The major change is that all Mesa ports are now configured the same way.
This fixes several problems and enables new features.  The details
are described in this blog post:
http://blogs.freebsdish.org/graphics/2015/03/18/unifying-mesa-ports-configure/

The second important change is the OpenCL support.  Mesa's
implementation, Clover, is enabled as well as Beignet.  Clover
targets all Gallium drivers, only Radeon GPUs in our case.  Beignet
is for Intel GPUs starting with Ivy Bridge.  Thanks to Johannes
Dieterich, O. Hartman, and Koop Mast for their work on OpenCL!  As a
bonus, there are several OpenCL-based math ports added (clblas,
clfft and clrng). For more information and known issues, please see
https://wiki.freebsd.org/Graphics/OpenCL

The third change is the removal of Mesa 9.1.7 which was installed on
FreeBSD 9.3-RELEASE.  There is now only one version of Mesa in the Ports
tree (10.6.6) for all supported versions of FreeBSD.

Other, smaller changes:

* Include libosmesa into the Mesa framework; this changes libOSMesa
  shlib version.

* bsd.mesalib.mk was renamed and split up in two files namely
  Makefile.common and Makefile.targets.  So ports can overwrite variables
  set by Makefile.common and are used by Makefile.targets.

* Some text in the pkg-descr files was wrong, clean it up.  While here,
  update the WWW to the main mesa3d.org upstream page.

* devel/clinfo was added, a glxinfo like program but for OpenCL.

Non-x86 hardware reports are very welcome since we changed the framework
quite a bit.

Obtained from:	Graphics team development repo.
parent 668ef943
...@@ -252,6 +252,7 @@ ...@@ -252,6 +252,7 @@
SUBDIR += cld2 SUBDIR += cld2
SUBDIR += clewn SUBDIR += clewn
SUBDIR += clig SUBDIR += clig
SUBDIR += clinfo
SUBDIR += clisp-hyperspec SUBDIR += clisp-hyperspec
SUBDIR += clojure-cider SUBDIR += clojure-cider
SUBDIR += cloudabi-binutils SUBDIR += cloudabi-binutils
......
# Created by: Koop Mast <kwm@FreeBSD.org>
# $FreeBSD$
PORTNAME= clinfo
PORTVERSION= 2.0.15.04.28
CATEGORIES= devel
MAINTAINER= kwm@FreeBSD.org
COMMENT= OpenCL info program like glxinfo is for libGL
BUILD_DEPENDS= ${LOCALBASE}/include/CL/opencl.h:${PORTSDIR}/devel/opencl
LIB_DEPENDS= libOpenCL.so:${PORTSDIR}/devel/ocl-icd
USE_GITHUB= yes
GH_ACCOUNT= Oblomov
GH_TAGNAME= b953d226b7
USES= gmake
NO_CONFIGURE= yes
ALL_TARGET= #
PLIST_FILES= bin/clinfo \
man/man1/clinfo.1.gz
post-patch:
@${REINPLACE_CMD} -e 's|-Wall|-Wall -I${LOCALBASE}/include|g; \
s|-lOpenCL|-lOpenCL -L${LOCALBASE}/lib|g' \
${WRKSRC}/Makefile
do-install:
@${INSTALL_PROGRAM} ${WRKSRC}/clinfo ${STAGEDIR}${PREFIX}/bin/
@${INSTALL_MAN} ${WRKSRC}/man/clinfo.1 ${STAGEDIR}${PREFIX}/man/man1/
.include <bsd.port.mk>
SHA256 (Oblomov-clinfo-2.0.15.04.28-b953d226b7_GH0.tar.gz) = 547cd53e656a787bffaab7308a4ac5f6bbd9dab23aaf723a820b86ff3f8122d4
SIZE (Oblomov-clinfo-2.0.15.04.28-b953d226b7_GH0.tar.gz) = 25230
A simple OpenCL application that enumerates all possible platform and
device properties. Inspired by AMD's program of the same name, it is
coded in pure C99 and it tries to output all possible information,
including that provided by platform-specific extensions, and not to
crash on platform-unsupported properties (e.g. 1.2 properties on 1.1
platforms).
WWW: https://github.com/Oblomov/clinfo
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
PORTNAME= dri PORTNAME= dri
PORTVERSION= ${MESAVERSION} PORTVERSION= ${MESAVERSION}
PORTREVISION= ${DRIREVISION} PORTREVISION= 0
PORTEPOCH= 2 PORTEPOCH= 2
CATEGORIES= graphics CATEGORIES= graphics
...@@ -18,12 +18,6 @@ USE_XORG= glproto x11 xext xxf86vm xdamage xfixes dri2proto \ ...@@ -18,12 +18,6 @@ USE_XORG= glproto x11 xext xxf86vm xdamage xfixes dri2proto \
OPTIONS_DEFINE= TEXTURE OPTIONS_DEFINE= TEXTURE
OPTIONS_DEFAULT=TEXTURE OPTIONS_DEFAULT=TEXTURE
OPTIONS_DEFINE_i386= GALLIUM
OPTIONS_DEFAULT_i386= GALLIUM
OPTIONS_DEFINE_amd64= GALLIUM
OPTIONS_DEFAULT_amd64= GALLIUM
GALLIUM_DESC= Gallium (llvm backed) dri drivers
TEXTURE_DESC= Enable texture-float support (patent encumbered) TEXTURE_DESC= Enable texture-float support (patent encumbered)
VDPAU_DESC= VDPAU (GPU video acceleration) support (needs Gallium) VDPAU_DESC= VDPAU (GPU video acceleration) support (needs Gallium)
...@@ -31,20 +25,13 @@ PKGHELP= ${.CURDIR}/pkg-help ...@@ -31,20 +25,13 @@ PKGHELP= ${.CURDIR}/pkg-help
.include <bsd.port.options.mk> .include <bsd.port.options.mk>
# gcc from base can't handle some code in mesa 9.1+
# We only care for 9.x and 8.x. clang in 10.x is new enough.
# This is for 0b0000 binary which gcc 4.3+ understands and is in the i965 driver.
. if (${OSVERSION} >= 901500 && ${OSVERSION} < 1000000)
CC=clang
CXX=clang++
CPP=clang-cpp
. elif ${OSVERSION} < 901500
USE_GCC=yes
. endif
ALL_DRI_DRIVERS=I915 I965 R200 RADEON SWRAST ALL_DRI_DRIVERS=I915 I965 R200 RADEON SWRAST
.include "${.CURDIR}/../../graphics/libGL/bsd.mesalib.mk" .include "${.CURDIR}/../../graphics/libGL/Makefile.common"
#src/mesa/libmesagallium.la
#MESA_BUILD_WRKSRC= src/util src/gallium
#MESA_INSTALL_WRKSRC= src/gallium
PLIST_SUB+= VERSION=${MESADISTVERSION} PLIST_SUB+= VERSION=${MESADISTVERSION}
...@@ -52,29 +39,6 @@ PLIST_SUB+= VERSION=${MESADISTVERSION} ...@@ -52,29 +39,6 @@ PLIST_SUB+= VERSION=${MESADISTVERSION}
DRI_DRIVERS= ${ALL_DRI_DRIVERS} DRI_DRIVERS= ${ALL_DRI_DRIVERS}
.endif .endif
.if defined(WITH_NEW_MESA)
DRIREVISION= 0
PLIST= ${.CURDIR}/pkg-plist
.else
DRIREVISION= 6
PLIST= ${.CURDIR}/pkg-plist-old
.endif
.if ${PORT_OPTIONS:MGALLIUM}
BUILD_DEPENDS+= llvm${MESA_LLVM_VER}>=0:${PORTSDIR}/devel/llvm${MESA_LLVM_VER}
RUN_DEPENDS+= llvm${MESA_LLVM_VER}>=0:${PORTSDIR}/devel/llvm${MESA_LLVM_VER}
CONFIGURE_ENV+= LLVM_CONFIG=${LOCALBASE}/bin/llvm-config${MESA_LLVM_VER}
CONFIGURE_ARGS+=--enable-gallium-llvm \
--enable-xvmc \
--with-gallium-drivers=r300,r600,radeonsi,svga,swrast
PLIST_SUB+= GALLIUM=""
.else
CONFIGURE_ARGS+=--enable-gallium-llvm=no --without-gallium-drivers \
--disable-gallium-egl
PLIST_SUB+= GALLIUM="@comment "
.endif
.if ${PORT_OPTIONS:MTEXTURE} .if ${PORT_OPTIONS:MTEXTURE}
CONFIGURE_ARGS+=--enable-texture-float CONFIGURE_ARGS+=--enable-texture-float
.endif .endif
...@@ -109,9 +73,11 @@ PLIST_SUB+= ${_d}_DRIVER="@comment " ...@@ -109,9 +73,11 @@ PLIST_SUB+= ${_d}_DRIVER="@comment "
. endif . endif
.endfor .endfor
.if !(${ARCH} == amd64 || ${ARCH} == i386)
CONFIGURE_ARGS+=--disable-gallium-intel
.endif
CONFIGURE_ARGS+=--with-dri-drivers="${DRI_DRIVERS:tl}" CONFIGURE_ARGS+=--with-dri-drivers="${DRI_DRIVERS:tl}"
.include "${.CURDIR}/../../graphics/libGL/Makefile.targets"
post-install:
@${RM} -rf ${STAGEDIR}/etc/OpenCL
.include <bsd.port.mk> .include <bsd.port.mk>
...@@ -4,7 +4,6 @@ ...@@ -4,7 +4,6 @@
@comment include/EGL/eglextchromium.h @comment include/EGL/eglextchromium.h
@comment include/EGL/eglmesaext.h @comment include/EGL/eglmesaext.h
@comment include/EGL/eglplatform.h @comment include/EGL/eglplatform.h
include/GL/internal/dri_interface.h
@comment include/GL/gl.h @comment include/GL/gl.h
@comment include/GL/gl_mangle.h @comment include/GL/gl_mangle.h
@comment include/GL/glcorearb.h @comment include/GL/glcorearb.h
...@@ -12,31 +11,53 @@ include/GL/internal/dri_interface.h ...@@ -12,31 +11,53 @@ include/GL/internal/dri_interface.h
@comment include/GL/glx.h @comment include/GL/glx.h
@comment include/GL/glx_mangle.h @comment include/GL/glx_mangle.h
@comment include/GL/glxext.h @comment include/GL/glxext.h
include/GL/internal/dri_interface.h
@comment include/GL/osmesa.h @comment include/GL/osmesa.h
@comment include/GL/wglext.h @comment include/GL/wglext.h
@comment include/GL/wmesa.h @comment include/GL/wmesa.h
@comment include/GLES2/gl2.h
@comment include/GLES2/gl2ext.h
@comment include/GLES2/gl2platform.h
@comment include/GLES3/gl3.h
@comment include/GLES3/gl31.h
@comment include/GLES3/gl3ext.h
@comment include/GLES3/gl3platform.h
@comment include/KHR/khrplatform.h @comment include/KHR/khrplatform.h
@comment include/gbm.h @comment include/gbm.h
%%GALLIUM%%lib/dri/kms_swrast_dri.so
%%I915_DRIVER%%lib/dri/i915_dri.so %%I915_DRIVER%%lib/dri/i915_dri.so
%%I965_DRIVER%%lib/dri/i965_dri.so %%I965_DRIVER%%lib/dri/i965_dri.so
lib/dri/kms_swrast_dri.so
%%R200_DRIVER%%lib/dri/r200_dri.so %%R200_DRIVER%%lib/dri/r200_dri.so
%%GALLIUM%%lib/dri/r300_dri.so lib/dri/r300_dri.so
%%GALLIUM%%lib/dri/r600_dri.so lib/dri/r600_dri.so
%%RADEON_DRIVER%%lib/dri/radeon_dri.so %%RADEON_DRIVER%%lib/dri/radeon_dri.so
%%GALLIUM%%lib/dri/radeonsi_dri.so lib/dri/radeonsi_dri.so
%%SWRAST_DRIVER%%lib/dri/swrast_dri.so %%SWRAST_DRIVER%%lib/dri/swrast_dri.so
%%GALLIUM%%lib/dri/vmwgfx_dri.so lib/dri/vmwgfx_dri.so
%%GALLIUM%%lib/libXvMCr600.so @comment lib/gallium-pipe/pipe_r300.so
%%GALLIUM%%lib/libXvMCr600.so.1 @comment lib/gallium-pipe/pipe_r600.so
%%GALLIUM%%lib/libXvMCr600.so.1.0 @comment lib/gallium-pipe/pipe_radeonsi.so
%%GALLIUM%%lib/libXvMCr600.so.1.0.0 @comment lib/gallium-pipe/pipe_swrast.so
@comment lib/gallium-pipe/pipe_vmwgfx.so
@comment lib/libEGL.so @comment lib/libEGL.so
@comment lib/libEGL.so.1 @comment lib/libEGL.so.1
@comment lib/libEGL.so.1.0.0 @comment lib/libEGL.so.1.0.0
@comment lib/libGL.so @comment lib/libGL.so
@comment lib/libGL.so.1 @comment lib/libGL.so.1
@comment lib/libGL.so.1.2.0 @comment lib/libGL.so.1.2.0
@comment lib/libGLESv2.so
@comment lib/libGLESv2.so.2
@comment lib/libGLESv2.so.2.0.0
@comment lib/libMesaOpenCL.so
@comment lib/libMesaOpenCL.so.1
@comment lib/libMesaOpenCL.so.1.0.0
@comment lib/libOSMesa.so
@comment lib/libOSMesa.so.8
@comment lib/libOSMesa.so.8.0.0
lib/libXvMCr600.so
lib/libXvMCr600.so.1
lib/libXvMCr600.so.1.0
lib/libXvMCr600.so.1.0.0
@comment lib/libgbm.so @comment lib/libgbm.so
@comment lib/libgbm.so.1 @comment lib/libgbm.so.1
@comment lib/libgbm.so.1.0.0 @comment lib/libgbm.so.1.0.0
...@@ -55,7 +76,9 @@ include/GL/internal/dri_interface.h ...@@ -55,7 +76,9 @@ include/GL/internal/dri_interface.h
%%VDPAU%%lib/vdpau/libvdpau_radeonsi.so.1 %%VDPAU%%lib/vdpau/libvdpau_radeonsi.so.1
%%VDPAU%%lib/vdpau/libvdpau_radeonsi.so.1.0 %%VDPAU%%lib/vdpau/libvdpau_radeonsi.so.1.0
%%VDPAU%%lib/vdpau/libvdpau_radeonsi.so.1.0.0 %%VDPAU%%lib/vdpau/libvdpau_radeonsi.so.1.0.0
@comment libdata/pkgconfig/egl.pc
libdata/pkgconfig/dri.pc libdata/pkgconfig/dri.pc
@comment libdata/pkgconfig/egl.pc
@comment libdata/pkgconfig/gbm.pc @comment libdata/pkgconfig/gbm.pc
@comment libdata/pkgconfig/gl.pc @comment libdata/pkgconfig/gl.pc
@comment libdata/pkgconfig/glesv2.pc
@comment libdata/pkgconfig/osmesa.pc
%%I965_DRIVER%%etc/drirc
@comment include/EGL/egl.h
@comment include/EGL/eglext.h
@comment include/EGL/eglmesaext.h
@comment include/EGL/eglplatform.h
@comment include/GL/gl.h
@comment include/GL/gl_mangle.h
@comment include/GL/glext.h
@comment include/GL/glx.h
@comment include/GL/glx_mangle.h
@comment include/GL/glxext.h
include/GL/internal/dri_interface.h
@comment include/GL/osmesa.h
@comment include/GL/wglext.h
@comment include/GL/wmesa.h
@comment include/KHR/khrplatform.h
@comment include/gbm.h
%%I915_DRIVER%%lib/dri/i915_dri.so
%%I965_DRIVER%%lib/dri/i965_dri.so
%%R200_DRIVER%%lib/dri/r200_dri.so
%%GALLIUM%%lib/dri/r300_dri.so
%%GALLIUM%%lib/dri/r600_dri.so
%%RADEON_DRIVER%%lib/dri/radeon_dri.so
%%GALLIUM%%lib/dri/radeonsi_dri.so
%%SWRAST_DRIVER%%lib/dri/swrast_dri.so
%%GALLIUM%%lib/dri/vmwgfx_dri.so
%%GALLIUM%%lib/libXvMCr300.so
%%GALLIUM%%lib/libXvMCr300.so.1
%%GALLIUM%%lib/libXvMCr300.so.1.0.0
%%GALLIUM%%lib/libXvMCr600.so
%%GALLIUM%%lib/libXvMCr600.so.1
%%GALLIUM%%lib/libXvMCr600.so.1.0.0
%%GALLIUM%%lib/libXvMCsoftpipe.so
%%GALLIUM%%lib/libXvMCsoftpipe.so.1
%%GALLIUM%%lib/libXvMCsoftpipe.so.1.0.0
@comment lib/libEGL.so
@comment lib/libEGL.so.1
@comment lib/libEGL.so.1.0.0
@comment lib/libGL.so
@comment lib/libGL.so.1
@comment lib/libGL.so.1.2.0
lib/libdricore9.1.7.so
lib/libdricore9.1.7.so.1
lib/libdricore9.1.7.so.1.0.0
@comment lib/libgbm.so
@comment lib/libgbm.so.1
@comment lib/libgbm.so.1.0.0
@comment lib/libglapi.so
@comment lib/libglapi.so.0
@comment lib/libglapi.so.0.0.0
%%GALLIUM%%lib/libllvmradeon%%VERSION%%.so
%%GALLIUM%%%%VDPAU%%lib/vdpau/libvdpau_r300.so
%%GALLIUM%%%%VDPAU%%lib/vdpau/libvdpau_r300.so.1
%%GALLIUM%%%%VDPAU%%lib/vdpau/libvdpau_r300.so.1.0.0
%%GALLIUM%%%%VDPAU%%lib/vdpau/libvdpau_r600.so
%%GALLIUM%%%%VDPAU%%lib/vdpau/libvdpau_r600.so.1
%%GALLIUM%%%%VDPAU%%lib/vdpau/libvdpau_r600.so.1.0.0
%%GALLIUM%%%%VDPAU%%lib/vdpau/libvdpau_radeonsi.so
%%GALLIUM%%%%VDPAU%%lib/vdpau/libvdpau_radeonsi.so.1
%%GALLIUM%%%%VDPAU%%lib/vdpau/libvdpau_radeonsi.so.1.0.0
%%GALLIUM%%%%VDPAU%%lib/vdpau/libvdpau_softpipe.so
%%GALLIUM%%%%VDPAU%%lib/vdpau/libvdpau_softpipe.so.1
%%GALLIUM%%%%VDPAU%%lib/vdpau/libvdpau_softpipe.so.1.0.0
libdata/pkgconfig/dri.pc
@comment libdata/pkgconfig/egl.pc
@comment libdata/pkgconfig/gbm.pc
@comment libdata/pkgconfig/gl.pc
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
PORTNAME= gbm PORTNAME= gbm
PORTVERSION= ${MESAVERSION} PORTVERSION= ${MESAVERSION}
PORTREVISION= ${GBM_REVISION} PORTREVISION= 0
CATEGORIES= graphics CATEGORIES= graphics
COMMENT= gbm library COMMENT= gbm library
...@@ -19,23 +19,12 @@ USE_XORG= x11 xau xcb xdmcp ...@@ -19,23 +19,12 @@ USE_XORG= x11 xau xcb xdmcp
USE_XORG+= glproto dri2proto xext xdamage xfixes presentproto \ USE_XORG+= glproto dri2proto xext xdamage xfixes presentproto \
xshmfence xshmfence
BUILD_WRKSRC= ${WRKSRC}/src/gbm
INSTALL_WRKSRC= ${WRKSRC}/src/gbm
.include <bsd.port.options.mk> .include <bsd.port.options.mk>
.include "${.CURDIR}/../../graphics/libGL/bsd.mesalib.mk" .include "${.CURDIR}/../../graphics/libGL/Makefile.common"
.if defined(WITH_NEW_MESA) MESA_BUILD_WRKSRC= src/mapi src/gbm
GBM_REVISION= 0 MESA_INSTALL_WRKSRC= src/gbm
.else
GBM_REVISION= 0 .include "${.CURDIR}/../../graphics/libGL/Makefile.targets"
.endif
pre-build:
.if defined(WITH_NEW_MESA)
@cd ${WRKSRC}/src/mapi/ && ${MAKE_CMD} ${_MAKE_JOBS}
.else
@cd ${WRKSRC}/src/mapi/shared-glapi && ${MAKE_CMD} ${_MAKE_JOBS}
.endif
.include <bsd.port.mk> .include <bsd.port.mk>
This package contains the EGL utility library. This package contains the gbm utility library.
WWW: http://www.freedesktop.org/Software/xorg WWW: http://mesa3d.org/
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
PORTNAME= libEGL PORTNAME= libEGL
PORTVERSION= ${MESAVERSION} PORTVERSION= ${MESAVERSION}
PORTREVISION= ${LIBEGL_REVISION} PORTREVISION= 0
CATEGORIES= graphics CATEGORIES= graphics
COMMENT= OpenEGL library COMMENT= OpenEGL library
...@@ -11,7 +11,8 @@ COMMENT= OpenEGL library ...@@ -11,7 +11,8 @@ COMMENT= OpenEGL library
LIB_DEPENDS+= libpthread-stubs.so:${PORTSDIR}/devel/libpthread-stubs \ LIB_DEPENDS+= libpthread-stubs.so:${PORTSDIR}/devel/libpthread-stubs \
libexpat.so:${PORTSDIR}/textproc/expat2 \ libexpat.so:${PORTSDIR}/textproc/expat2 \
libdevq.so:${PORTSDIR}/devel/libdevq \ libdevq.so:${PORTSDIR}/devel/libdevq \
libdrm.so:${PORTSDIR}/graphics/libdrm libdrm.so:${PORTSDIR}/graphics/libdrm \
libgbm.so:${PORTSDIR}/graphics/gbm
USE_XORG= x11 xau xcb xdmcp USE_XORG= x11 xau xcb xdmcp
...@@ -20,38 +21,12 @@ USE_XORG+= glproto dri2proto xext xdamage xfixes presentproto \ ...@@ -20,38 +21,12 @@ USE_XORG+= glproto dri2proto xext xdamage xfixes presentproto \
xshmfence xshmfence
.include <bsd.port.options.mk> .include <bsd.port.options.mk>
.include "${.CURDIR}/../../graphics/libGL/bsd.mesalib.mk" .include "${.CURDIR}/../../graphics/libGL/Makefile.common"
.if defined(WITH_NEW_MESA) MESA_BUILD_WRKSRC= src/mapi src/gbm src/egl/drivers/dri2 src/egl/main
BUILD_WRKSRC= src/egl/drivers/dri2 src/egl/main MESA_INSTALL_WRKSRC= src/egl/drivers/dri2 src/egl/main
INSTALL_WRKSRC= src/egl/drivers/dri2 src/egl/main
.else .include "${.CURDIR}/../../graphics/libGL/Makefile.targets"
BUILD_WRKSRC= ${WRKSRC}/src/egl
INSTALL_WRKSRC= ${WRKSRC}/src/egl
.endif
.if defined(WITH_NEW_MESA)
LIBEGL_REVISION= 0
.else
LIBEGL_REVISION= 5
.endif
.if defined(WITH_NEW_MESA)
do-build: egl-do-build
do-install: egl-do-install
egl-do-build:
. for dir in ${BUILD_WRKSRC}
@(cd ${WRKSRC}/${dir}; ${DO_MAKE_BUILD} ${ALL_TARGET};)
. endfor
egl-do-install:
. for dir in ${INSTALL_WRKSRC}
@(cd ${WRKSRC}/${dir} && ${SETENV} ${MAKE_ENV} ${MAKE_CMD} \
${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} ${INSTALL_TARGET})
. endfor
.endif
post-install: post-install:
@${MKDIR} ${STAGEDIR}${PREFIX}/lib/.mesa @${MKDIR} ${STAGEDIR}${PREFIX}/lib/.mesa
......
This package contains the EGL utility library. This package contains the EGL utility library.
WWW: http://www.freedesktop.org/Software/xorg WWW: http://mesa3d.org/
include/EGL/egl.h include/EGL/egl.h
include/EGL/eglext.h include/EGL/eglext.h
%%NEW%%include/EGL/eglextchromium.h include/EGL/eglextchromium.h
include/EGL/eglmesaext.h include/EGL/eglmesaext.h
include/EGL/eglplatform.h include/EGL/eglplatform.h
include/KHR/khrplatform.h include/KHR/khrplatform.h
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
PORTNAME= libGL PORTNAME= libGL
PORTVERSION= ${MESAVERSION} PORTVERSION= ${MESAVERSION}
PORTREVISION= ${LIBGLREVISION} PORTREVISION= 0
CATEGORIES= graphics CATEGORIES= graphics
COMMENT= OpenGL library that renders using GLX or DRI COMMENT= OpenGL library that renders using GLX or DRI
...@@ -16,21 +16,18 @@ USE_XORG= glproto x11 xext xxf86vm xdamage xfixes dri2proto:both \ ...@@ -16,21 +16,18 @@ USE_XORG= glproto x11 xext xxf86vm xdamage xfixes dri2proto:both \
presentproto xshmfence presentproto xshmfence
.include <bsd.port.options.mk> .include <bsd.port.options.mk>
.include "${.CURDIR}/bsd.mesalib.mk" .include "${.CURDIR}/Makefile.common"
.if defined(WITH_NEW_MESA) MESA_BUILD_WRKSRC= src/mapi src/glx
LIBGLREVISION= 0 MESA_INSTALL_WRKSRC= src/glx
.else
LIBGLREVISION= 4
.endif
.if !(${ARCH} == "amd64" || ${ARCH} == "i386") .include "${.CURDIR}/Makefile.targets"
CONFIGURE_ARGS+=--disable-gallium-intel
.endif
post-install: post-install:
@${MKDIR} ${STAGEDIR}${PREFIX}/lib/.mesa @${MKDIR} ${STAGEDIR}${PREFIX}/lib/.mesa
@${MV} ${STAGEDIR}${PREFIX}/lib/libGL* \ @${MV} ${STAGEDIR}${PREFIX}/lib/libGL* \
${STAGEDIR}${PREFIX}/lib/.mesa/ ${STAGEDIR}${PREFIX}/lib/.mesa/
@cd ${WRKSRC}/src/mesa && ${SETENV} DESTDIR=${STAGEDIR} \
${MAKE_CMD} install-pkgconfigDATA install-glHEADERS
.include <bsd.port.mk> .include <bsd.port.mk>
# bsd.mesalib.mk - shared code between MesaLib ports. # Makefile.common - shared code between MesaLib ports.
# #
# !!! Here be dragons !!! (they seem to be everywhere these days) # !!! Here be dragons !!! (they seem to be everywhere these days)
# #
...@@ -15,58 +15,37 @@ ...@@ -15,58 +15,37 @@
# #
# $FreeBSD$ # $FreeBSD$
# hw context support in the i915kms driver
.if ${OPSYS} == FreeBSD && \
(${OSVERSION} >= 1000717 && ${OSVERSION} < 1100000 || \
${OSVERSION} >= 1100035)
WITH_NEW_MESA=1
.endif
.if ${OPSYS} == DragonFly && ${DFLYVERSION} >= 300901
WITH_NEW_MESA=1
.endif
MESAVERSION= ${MESABASEVERSION}${MESASUBVERSION:C/^(.)/.\1/} MESAVERSION= ${MESABASEVERSION}${MESASUBVERSION:C/^(.)/.\1/}
MESADISTVERSION=${MESABASEVERSION}${MESASUBVERSION:C/^(.)/-\1/} MESADISTVERSION=${MESABASEVERSION}${MESASUBVERSION:C/^(.)/-\1/}
.if defined(WITH_NEW_MESA) MESABASEVERSION= 10.6.6
MESABASEVERSION= 10.4.6
# if there is a subversion, don't include the '-' between 7.11-rc2. # if there is a subversion, don't include the '-' between 7.11-rc2.
MESASUBVERSION= MESASUBVERSION=
MASTER_SITES= ftp://ftp.freedesktop.org/pub/mesa/${MESABASEVERSION}/ MASTER_SITES= ftp://ftp.freedesktop.org/pub/mesa/${MESABASEVERSION}/
PLIST_SUB+= OLD="@comment " NEW=""
# work around libarchive bug?
EXTRACT_CMD= ${LOCALBASE}/bin/gtar
EXTRACT_DEPENDS+= gtar:${PORTSDIR}/archivers/gtar
.else DISTFILES= mesa-${MESADISTVERSION}${EXTRACT_SUFX}
MESABASEVERSION= 9.1.7
MESASUBVERSION=
MASTER_SITES= ftp://ftp.freedesktop.org/pub/mesa/older-versions/${MESABASEVERSION:R:R}.x/${MESABASEVERSION}/
PLIST_SUB+= OLD="" NEW="@comment "
.endif
DISTFILES= MesaLib-${MESADISTVERSION}${EXTRACT_SUFX}
MAINTAINER= x11@FreeBSD.org MAINTAINER= x11@FreeBSD.org
BUILD_DEPENDS+= makedepend:${PORTSDIR}/devel/makedepend \ BUILD_DEPENDS+= makedepend:${PORTSDIR}/devel/makedepend
${PYTHON_SITELIBDIR}/libxml2.py:${PORTSDIR}/textproc/py-libxml2
LIB_DEPENDS+= libdevq.so:${PORTSDIR}/devel/libdevq LIB_DEPENDS+= libdevq.so:${PORTSDIR}/devel/libdevq
USES+= bison gettext-tools gmake libtool pathfix pkgconfig \ USES+= compiler:c++11-lib gettext-tools gmake libtool \
python:2,build shebangfix tar:bzip2 pathfix pkgconfig shebangfix tar:xz
USE_LDCONFIG= yes USE_LDCONFIG= yes
GNU_CONFIGURE= yes GNU_CONFIGURE= yes
CPPFLAGS+= -isystem${LOCALBASE}/include CPPFLAGS+= -isystem${LOCALBASE}/include
LDFLAGS+= -Wl,-Y${LOCALBASE}/lib LDFLAGS+= -Wl,-Y${LOCALBASE}/lib
PKGINSTALL= ${.CURDIR}/pkg-install PKGINSTALL= ${.CURDIR}/pkg-install
PKGDEINSTALL= ${.CURDIR}/pkg-deinstall PKGDEINSTALL= ${.CURDIR}/pkg-deinstall