Index: Mk/bsd.port.mk =================================================================== --- Mk/bsd.port.mk (revision 328562) +++ Mk/bsd.port.mk (working copy) @@ -358,7 +358,7 @@ # MAKE_ENV are extended with a DISPLAY variable. # # USE_GL - A list of Mesa or GL related dependencies needed by the port. -# Supported components are: glut, glu, glw, and gl. +# Supported components are: egl, glesv2, glut, glu, glw, and gl. # If set to "yes", this is equivalent to "glu". Note that # glew and glut depend on glu, glw and glu depend on gl. ## @@ -1892,13 +1892,15 @@ PKG_IGNORE_DEPENDS?= 'this_port_does_not_exist' -_GL_gl_LIB_DEPENDS= GL.1:${PORTSDIR}/graphics/libGL +_GL_glesv2_LIB_DEPENDS= libGLESv2.so:${PORTSDIR}/grahpics/libglesv2 +_GL_egl_LIB_DEPENDS= libEGL.so:${PORTSDIR}/graphics/libEGL +_GL_gl_LIB_DEPENDS= libGL.so:${PORTSDIR}/graphics/libGL _GL_gl_USE_XORG= glproto dri2proto -_GL_glew_LIB_DEPENDS= GLEW.1:${PORTSDIR}/graphics/glew -_GL_glu_LIB_DEPENDS= GLU.1:${PORTSDIR}/graphics/libGLU +_GL_glew_LIB_DEPENDS= libGLEW.so:${PORTSDIR}/graphics/glew +_GL_glu_LIB_DEPENDS= libGLU.so:${PORTSDIR}/graphics/libGLU _GL_glu_USE_XORG= glproto dri2proto -_GL_glw_LIB_DEPENDS= GLw.1:${PORTSDIR}/graphics/libGLw -_GL_glut_LIB_DEPENDS= glut.12:${PORTSDIR}/graphics/freeglut +_GL_glw_LIB_DEPENDS= libGLw.so:${PORTSDIR}/graphics/libGLw +_GL_glut_LIB_DEPENDS= libglut.so:${PORTSDIR}/graphics/freeglut .if defined(USE_GL) . if ${USE_GL:L} == "yes" Index: UPDATING =================================================================== --- UPDATING (revision 328562) +++ UPDATING (working copy) @@ -5,6 +5,34 @@ You should get into the habit of checking this file for changes each time you update your ports collection, before attempting any port upgrades. +201309xx: + AFFECTS: users of x11/pixman + AUTHOR: zeising@FreeBSD.org + + The library version of x11/pixman has changed, and portrevision has + been bumped in all dependent ports. If you have external software that + depends on pixman, this software needs to be recompiled. + To recompile all software dependent on pixman, run: + + # portmaster -r pixman + or + # portupgrade -rf pixman + +201309xx: + AFFECTS: users of graphics/libGL, graphics/dri and other MESA ports + AUTHOR: zeising@FreeBSD.org + + The graphics/libGL, graphics/dri and related MESA ports have been + updated to 9.1 when compiled with WITH_NEW_XORG= set. It is necessary + to remove the old versions of both ports before updating. + + # pkg_delete -f libGl-\* dri-\* + or + # pkg delete -f libGL dri + followed by + # portmaster -a + +======= 20130925 AFFECTS: Users of print/qpdf AUTHOR: d.y.kazarov@mail.ru @@ -602,7 +630,7 @@ settings in rc.conf prior to restarting postgrey. 20130525: - AFFECTS: users of x11/xorg and all X.Org ports + AFFECTS: users of x11/xorg and all xorg ports AUTHOR: zeising@FreeBSD.org X.Org, including libraries and some drivers, was updated. If you are Index: astro/viking/Makefile =================================================================== --- astro/viking/Makefile (revision 328562) +++ astro/viking/Makefile (working copy) @@ -3,6 +3,7 @@ PORTNAME= viking PORTVERSION= 1.4.2 +PORTREVISION= 1 CATEGORIES= astro MASTER_SITES= SF/${PORTNAME}/${PORTNAME}/${PORTVERSION}/ Index: cad/pdnmesh/Makefile =================================================================== --- cad/pdnmesh/Makefile (revision 328562) +++ cad/pdnmesh/Makefile (working copy) @@ -3,7 +3,7 @@ PORTNAME= pdnmesh PORTVERSION= 0.2.2 -PORTREVISION= 2 +PORTREVISION= 3 CATEGORIES= cad MASTER_SITES= SF/${PORTNAME}/${PORTNAME}-source/${PORTVERSION} Index: cad/repsnapper/Makefile =================================================================== --- cad/repsnapper/Makefile (revision 328562) +++ cad/repsnapper/Makefile (working copy) @@ -3,6 +3,7 @@ PORTNAME= repsnapper PORTVERSION= 2.2.0b3 +PORTREVISION= 1 CATEGORIES= cad MASTER_SITES= https://codeload.github.com/timschmidt/repsnapper/tar.gz/ DISTNAME= ${PORTVERSION} Index: deskutils/pinot/Makefile =================================================================== --- deskutils/pinot/Makefile (revision 328562) +++ deskutils/pinot/Makefile (working copy) @@ -3,7 +3,7 @@ PORTNAME= pinot PORTVERSION= 1.06 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= deskutils MASTER_SITES= ${MASTER_SITE_GOOGLE_CODE} #MASTER_SITES= http://colinf.chez.com/pinot/ Index: devel/xorg-macros/Makefile =================================================================== --- devel/xorg-macros/Makefile (revision 328562) +++ devel/xorg-macros/Makefile (working copy) @@ -2,7 +2,7 @@ # $FreeBSD$ PORTNAME= xorg-macros -PORTVERSION= 1.17 +PORTVERSION= 1.17.1 CATEGORIES= devel x11 DISTNAME= util-macros-$(PORTVERSION) Index: devel/xorg-macros/distinfo =================================================================== --- devel/xorg-macros/distinfo (revision 328562) +++ devel/xorg-macros/distinfo (working copy) @@ -1,2 +1,2 @@ -SHA256 (xorg/util/util-macros-1.17.tar.bz2) = 7d79edde72fc17dcdc56cfbe2f8ff384d1bffd1d8c58c0fd25970f5b2ccb75ed -SIZE (xorg/util/util-macros-1.17.tar.bz2) = 77029 +SHA256 (xorg/util/util-macros-1.17.1.tar.bz2) = 5e52654f2a0b04223cf28a9d7fd62cf288852e639ac13a75172fd47d0d6ac625 +SIZE (xorg/util/util-macros-1.17.1.tar.bz2) = 79105 Index: emulators/catapult/Makefile =================================================================== --- emulators/catapult/Makefile (revision 328562) +++ emulators/catapult/Makefile (working copy) @@ -3,7 +3,7 @@ PORTNAME= catapult PORTVERSION= 0.9.1 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= emulators MASTER_SITES= SF/openmsx/openmsx/${PORTVERSION} DISTNAME= openmsx-${PORTNAME}-${PORTVERSION} @@ -32,8 +32,7 @@ USE_GNOME= gdkpixbuf2 glib20 gtk20 libxml2 USE_WX= 2.6+ USE_PYTHON_BUILD=yes -USE_GMAKE= yes -USES= gettext iconv +USES= gettext gmake iconv USE_XORG= ice pixman sm x11 xau xcb xcomposite xcursor xdamage xdmcp \ xext xfixes xi xinerama xrandr xrender xxf86vm MAKEFILE= GNUmakefile Index: emulators/qemu-devel/Makefile =================================================================== --- emulators/qemu-devel/Makefile (revision 328562) +++ emulators/qemu-devel/Makefile (working copy) @@ -3,7 +3,7 @@ PORTNAME= qemu PORTVERSION= 1.6.0 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= emulators MASTER_SITES= http://wiki.qemu.org/download/:release \ LOCAL/nox:snapshot @@ -14,13 +14,12 @@ MAINTAINER= nox@FreeBSD.org COMMENT= QEMU CPU Emulator - development version -LIB_DEPENDS= pixman-1:${PORTSDIR}/x11/pixman - HAS_CONFIGURE= yes USE_BZIP2= yes USES= gmake pkgconfig bison perl5 USE_PERL5= build USE_PYTHON_BUILD= -2.7 +USE_XORG= pixman USE_GNOME+= glib20 PATCH_STRIP= -p1 MAKE_ENV+= BSD_MAKE="${MAKE}" Index: emulators/tme/Makefile =================================================================== --- emulators/tme/Makefile (revision 328562) +++ emulators/tme/Makefile (working copy) @@ -3,7 +3,7 @@ PORTNAME= tme PORTVERSION= 0.8 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= emulators MASTER_SITES= http://people.csail.mit.edu/fredette/tme/ @@ -21,9 +21,8 @@ expat:${PORTSDIR}/textproc/expat2 \ fontconfig:${PORTSDIR}/x11-fonts/fontconfig -USES= pkgconfig gettext iconv perl5 +USES= pkgconfig gettext gmake iconv perl5 USE_GNOME= gdkpixbuf2 gtk20 -USE_GMAKE= yes USE_AUTOTOOLS= libtool libltdl CONFIGURE_ENV= ac_cv_have_isinff=no CONFIGURE_ARGS= --datadir=${WRKDIR}/tmproot --disable-warnings Index: games/klavaro/Makefile =================================================================== --- games/klavaro/Makefile (revision 328562) +++ games/klavaro/Makefile (working copy) @@ -3,6 +3,7 @@ PORTNAME= klavaro PORTVERSION= 1.9.9 +PORTREVISION= 1 CATEGORIES= games MASTER_SITES= SF/${PORTNAME}/ Index: graphics/Makefile =================================================================== --- graphics/Makefile (revision 328562) +++ graphics/Makefile (working copy) @@ -484,6 +484,7 @@ SUBDIR += leptonica SUBDIR += lfview SUBDIR += lib3ds + SUBDIR += libEGL SUBDIR += libGL SUBDIR += libGLU SUBDIR += libGLw @@ -505,6 +506,7 @@ SUBDIR += libgeotiff SUBDIR += libgfx SUBDIR += libggi + SUBDIR += libglesv2 SUBDIR += libgltext SUBDIR += libgnomecanvas SUBDIR += libgnomecanvas-reference Index: graphics/cairo/Makefile =================================================================== --- graphics/cairo/Makefile (revision 328562) +++ graphics/cairo/Makefile (working copy) @@ -4,7 +4,7 @@ PORTNAME= cairo PORTVERSION= 1.10.2 -PORTREVISION= 5 +PORTREVISION= 6 PORTEPOCH?= 2 CATEGORIES= graphics MASTER_SITES= http://cairographics.org/releases/ Index: graphics/dri/Makefile =================================================================== --- graphics/dri/Makefile (revision 328562) +++ graphics/dri/Makefile (working copy) @@ -9,15 +9,35 @@ COMMENT= OpenGL hardware acceleration drivers for the DRI -LIB_DEPENDS= drm:${PORTSDIR}/graphics/libdrm \ - expat:${PORTSDIR}/textproc/expat2 +LIB_DEPENDS= libdrm.so:${PORTSDIR}/graphics/libdrm \ + libexpat.so:${PORTSDIR}/textproc/expat2 USES= pkgconfig USE_XORG= glproto x11 xext xxf86vm xdamage xfixes dri2proto +.include + +# gcc from base can't handle some code in mesa 9.1+ +# We only care for 9.x and 8.x, not for old pre-clang default current. +# This is for 0b0000 binary which gcc 4.3+ understands and is in the i965 driver. +.if defined(WITH_NEW_XORG) +. if ${OSVERSION} >= 901000 && ${OSVERSION} < 902502 \ + && (${ARCH} == i386 || ${ARCH} == amd64) +CC=clang +CXX=clang++ +CPP=clang-cpp +. elif ${OSVERSION} < 901500 +USE_GCC=yes +. endif +.endif + +.if ${ARCH} == ia64 +#BROKEN= does not install on ia64 +.endif + ALL_DRI_DRIVERS=I915 I965 R200 RADEON SWRAST -.if ! defined(WITH_NEW_XORG) +.if !defined(WITH_NEW_XORG) ALL_DRI_DRIVERS+=I810 MACH64 MGA R128 R300 R600 SAVAGE SIS TDFX UNICHROME .endif @@ -24,41 +44,42 @@ NO_STAGE= yes .include "${.CURDIR}/../../graphics/libGL/bsd.mesalib.mk" -OPTIONS_DEFINE_i386= ${ALL_DRI_DRIVERS} -OPTIONS_DEFINE_amd64= ${OPTIONS_DEFINE_i386} +PLIST_SUB+= VERSION=${MESADISTVERSION} -.if defined(WITH_NEW_XORG) -OPTIONS_DEFINE_powerpc= RADEON SWRAST -OPTIONS_DEFINE_sparc64= RADEON SWRAST -.else -OPTIONS_DEFINE_powerpc= MACH64 RADEON SWRAST TDFX -OPTIONS_DEFINE_sparc64= MACH64 RADEON SWRAST +.if ${ARCH} == amd64 || ${ARCH} == i386 +DRI_DRIVERS= ${ALL_DRI_DRIVERS} .endif -OPTIONS_DEFAULT=${OPTIONS_DEFINE} +.if defined(WITH_NEW_XORG) +. if defined(WITH_GALLIUM) && (${ARCH} == i386 || ${ARCH} == amd64) +BUILD_DEPENDS+= llvm-config33:${PORTSDIR}/devel/llvm33 +RUN_DEPENDS+= llvm-config33:${PORTSDIR}/devel/llvm33 +CONFIGURE_ENV+= LLVM_CONFIG=${LOCALBASE}/bin/llvm-config33 -I810_DESC= Include DRI support for Intel i810 -I915_DESC= Include DRI support for Intel i915 -I965_DESC= Include DRI support for Intel i965 -MACH64_DESC= Include DRI support for AMD/ATI Mach64 -MGA_DESC= Include DRI support for Matrox -R128_DESC= Include DRI support for AMD/ATI R128 -R200_DESC= Include DRI support for AMD/ATI R200 -R300_DESC= Include DRI support for AMD/ATI R300 -R600_DESC= Include DRI support for AMD/ATI R600 -RADEON_DESC= Include DRI support for AMD/ATI RADEON -SAVAGE_DESC= Include DRI support for S3/Via Savage -SIS_DESC= Include DRI support for SiS 300 and 6326 -SWRAST_DESC= Include generic software DRI support -TDFX_DESC= Include DRI support for 3dfx Voodoo -UNICHROME_DESC= Include DRI support for S3/Via Unichrome +CONFIGURE_ARGS+=--enable-gallium-llvm --disable-gallium-egl -.include +CONFIGURE_ARGS+=--with-gallium-drivers=r300,r600,radeonsi,svga,swrast +PLIST_SUB+= GALLIUM="" +. else +CONFIGURE_ARGS+=--enable-gallium-llvm=no --without-gallium-drivers +PLIST_SUB+= GALLIUM="@comment " +. endif +. if ${ARCH} == powerpc || ${ARCH} == ia64 +DRI_DRIVERS= RADEON SWRAST +. endif +. if ${ARCH} == sparc64 +DRI_DRIVERS= SWRAST +. endif +.else # !defined(WITH_NEW_XORG) +. if ${ARCH} == powerpc +DRI_DRIVERS= MACH64 RADEON SWRAST TDFX +. elif ${ARCH} == sparc64 +DRI_DRIVERS= MACH64 RADEON SWRAST +. endif +.endif # defined(WITH_NEW_XORG) -DRI_DRIVERS= .for _d in ${ALL_DRI_DRIVERS} -.if ${PORT_OPTIONS:M${_d}} -DRI_DRIVERS+= ${_d} +.if ${DRI_DRIVERS:M${_d}} PLIST_SUB+= ${_d}_DRIVER="" .else PLIST_SUB+= ${_d}_DRIVER="@comment " @@ -65,16 +86,31 @@ .endif .endfor -.if ${ARCH} == "ia64" -BROKEN= does not install on ia64 -.endif - -.if !(${ARCH} == "amd64" || ${ARCH} == "i386") +.if !(${ARCH} == amd64 || ${ARCH} == i386) CONFIGURE_ARGS+=--disable-gallium-intel .endif CONFIGURE_ARGS+=--with-dri-drivers="${DRI_DRIVERS:L}" +.if defined(WITH_NEW_XORG) && !defined(WITH_GALLIUM) \ + && (${ARCH} == i386 || ${ARCH} == amd64) +pre-everything:: + @${ECHO_MSG} "" + @${ECHO_MSG} "For r300, r600, radeonsi and swrast gallium based drivers." + @${ECHO_MSG} "Please define WITH_GALLIUM in /etc/make.conf" + @${ECHO_MSG} "Note that gallium support is highly experimental." + @${ECHO_MSG} "" +.endif + do-install: +.if !defined(WITH_NEW_XORG) cd ${WRKSRC}/src/mesa; ${GMAKE} install-dri +.else + cd ${WRKSRC}/src/mesa/libdricore; ${GMAKE} install + cd ${WRKSRC}/src/mesa/drivers/dri; ${GMAKE} install +. if defined(WITH_GALLIUM) && (${ARCH} == i386 || ${ARCH} == amd64) + cd ${WRKSRC}/src/gallium/drivers/radeon; ${GMAKE} install + cd ${WRKSRC}/src/gallium/targets; ${GMAKE} install +. endif +.endif .include Index: graphics/dri/pkg-plist =================================================================== --- graphics/dri/pkg-plist (revision 328562) +++ graphics/dri/pkg-plist (working copy) @@ -1,19 +1,38 @@ +%%NEW%%%%I965_DRIVER%%etc/drirc include/GL/internal/dri_interface.h %%OLD%%%%I810_DRIVER%%lib/dri/i810_dri.so +%%NEW%%%%I915_DRIVER%%lib/dri/i915_dri.la %%I915_DRIVER%%lib/dri/i915_dri.so +%%NEW%%%%I965_DRIVER%%lib/dri/i965_dri.la %%I965_DRIVER%%lib/dri/i965_dri.so %%OLD%%%%MACH64_DRIVER%%lib/dri/mach64_dri.so %%OLD%%%%MGA_DRIVER%%lib/dri/mga_dri.so %%OLD%%%%R128_DRIVER%%lib/dri/r128_dri.so +%%NEW%%%%R200_DRIVER%%lib/dri/r200_dri.la %%R200_DRIVER%%lib/dri/r200_dri.so %%OLD%%%%R300_DRIVER%%lib/dri/r300_dri.so +%%NEW%%%%GALLIUM%%lib/dri/r300_dri.la +%%NEW%%%%GALLIUM%%lib/dri/r300_dri.so %%OLD%%%%R600_DRIVER%%lib/dri/r600_dri.so +%%NEW%%%%GALLIUM%%lib/dri/r600_dri.la +%%NEW%%%%GALLIUM%%lib/dri/r600_dri.so +%%NEW%%%%RADEON_DRIVER%%lib/dri/radeon_dri.la %%RADEON_DRIVER%%lib/dri/radeon_dri.so +%%NEW%%%%GALLIUM%%lib/dri/radeonsi_dri.la +%%NEW%%%%GALLIUM%%lib/dri/radeonsi_dri.so %%OLD%%%%SAVAGE_DRIVER%%lib/dri/savage_dri.so %%OLD%%%%SIS_DRIVER%%lib/dri/sis_dri.so +%%NEW%%%%SWRAST_DRIVER%%lib/dri/swrast_dri.la %%SWRAST_DRIVER%%lib/dri/swrast_dri.so %%OLD%%%%TDFX_DRIVER%%lib/dri/tdfx_dri.so %%OLD%%%%UNICHROME_DRIVER%%lib/dri/unichrome_dri.so +%%NEW%%%%GALLIUM%%lib/dri/vmwgfx_dri.la +%%NEW%%%%GALLIUM%%lib/dri/vmwgfx_dri.so +%%NEW%%lib/libdricore%%VERSION%%.la +%%NEW%%lib/libdricore%%VERSION%%.so +%%NEW%%lib/libdricore%%VERSION%%.so.1 +%%NEW%%%%GALLIUM%%lib/libllvmradeon%%VERSION%%.la +%%NEW%%%%GALLIUM%%lib/libllvmradeon%%VERSION%%.so libdata/pkgconfig/dri.pc @dirrm lib/dri @dirrmtry include/GL/internal Index: graphics/libEGL/Makefile =================================================================== --- graphics/libEGL/Makefile (revision 0) +++ graphics/libEGL/Makefile (working copy) @@ -0,0 +1,30 @@ +# Created by: kwm@FreeBSD.org +# $FreeBSD$ + +PORTNAME= libEGL +PORTVERSION= ${MESAVERSION} +CATEGORIES= graphics + +COMMENT= OpenEGL library + +LIB_DEPENDS+= libpthread-stubs.so:${PORTSDIR}/devel/libpthread-stubs + +.if ! defined(WITH_NEW_XORG) +IGNORE= Please enable WITH_NEW_XORG, libEGL needs libdrm higher then 2.4.24 +.endif + +USE_XORG= x11 xau xcb xdmcp + +# stuff not needed by libEGL but configure wants it +USE_XORG+= glproto dri2proto xext xdamage xfixes +LIB_DEPENDS+= libexpat.so:${PORTSDIR}/textproc/expat2 \ + libdrm.so:${PORTSDIR}/graphics/libdrm + +BUILD_WKRSRC= ${WRKSRC}/src/egl +INSTALL_WRKSRC= ${WRKSRC}/src/egl + +WITH_NEW_XORG= yes + +.include +.include "${.CURDIR}/../../graphics/libGL/bsd.mesalib.mk" +.include Property changes on: graphics/libEGL/Makefile ___________________________________________________________________ Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +FreeBSD=%H \ No newline at end of property Index: graphics/libEGL/pkg-descr =================================================================== --- graphics/libEGL/pkg-descr (revision 0) +++ graphics/libEGL/pkg-descr (working copy) @@ -0,0 +1,3 @@ +This package contains the EGL utility library. + +WWW: http://www.freedesktop.org/Software/xorg Property changes on: graphics/libEGL/pkg-descr ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: graphics/libEGL/pkg-plist =================================================================== --- graphics/libEGL/pkg-plist (revision 0) +++ graphics/libEGL/pkg-plist (working copy) @@ -0,0 +1,11 @@ +include/EGL/egl.h +include/EGL/eglext.h +include/EGL/eglmesaext.h +include/EGL/eglplatform.h +include/KHR/khrplatform.h +lib/libEGL.la +lib/libEGL.so +lib/libEGL.so.1 +libdata/pkgconfig/egl.pc +@dirrmtry include/KHR +@dirrmtry include/EGL Property changes on: graphics/libEGL/pkg-plist ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: graphics/libGL/Makefile =================================================================== --- graphics/libGL/Makefile (revision 328562) +++ graphics/libGL/Makefile (working copy) @@ -3,14 +3,13 @@ PORTNAME= libGL PORTVERSION= ${MESAVERSION} -PORTREVISION= 4 +PORTREVISION= ${LIBGLREVISION} CATEGORIES= graphics -MAINTAINER= x11@FreeBSD.org COMMENT= OpenGL library that renders using GLX or DRI -LIB_DEPENDS+= drm:${PORTSDIR}/graphics/libdrm \ - expat:${PORTSDIR}/textproc/expat2 +LIB_DEPENDS+= libdrm.so:${PORTSDIR}/graphics/libdrm \ + libexpat.so:${PORTSDIR}/textproc/expat2 USES= pkgconfig USE_XORG= glproto x11 xext xxf86vm xdamage xfixes dri2proto:both @@ -18,9 +17,28 @@ SUB_FILES= pkg-install pkg-deinstall NO_STAGE= yes +.include + +.if defined(WITH_NEW_XORG) +LIBGLREVISION= 0 +.else +LIBGLREVISION= 4 +.endif + do-install: +.if ! defined(WITH_NEW_XORG) ${RM} -f ${WRKSRC}/include/GL/glu*.h + @${MKDIR} ${PREFIX}/lib/.libGL cd ${WRKSRC}/src/mesa; ${GMAKE} install-libgl +.else + cd ${WRKSRC}/src/mesa; ${GMAKE} install-pkgconfigDATA + cd ${WRKSRC}/src/glx; ${GMAKE} install + ${MKDIR} ${PREFIX}/include/GL + cd ${WRKSRC}/include/GL && ${COPYTREE_SHARE} \*.h ${PREFIX}/include/GL/ + @${MKDIR} ${PREFIX}/lib/.libGL + ${INSTALL_LIB} ${WRKSRC}/src/glx/.libs/libGL.so ${PREFIX}/lib/.libGL/ + ${INSTALL_LIB} ${WRKSRC}/src/glx/.libs/libGL.so.1 ${PREFIX}/lib/.libGL/ +.endif post-install: @PKG_PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL @@ -27,10 +45,8 @@ .include "${.CURDIR}/bsd.mesalib.mk" -.include - .if !(${ARCH} == "amd64" || ${ARCH} == "i386") CONFIGURE_ARGS+=--disable-gallium-intel .endif -.include +.include Index: graphics/libGL/bsd.mesalib.mk =================================================================== --- graphics/libGL/bsd.mesalib.mk (revision 328562) +++ graphics/libGL/bsd.mesalib.mk (working copy) @@ -1,16 +1,12 @@ -#-*- mode: Fundamental; tab-width: 4; -*- -# ex:ts=4 +# bsd.mesalib.mk - shared code between MesaLib ports. # -# bsd.mesa.mk - an attempt to refactor MesaLib ports. -# -# Created by: Florent Thoumie -# # !!! Here be dragons !!! (they seem to be everywhere these days) # # Remember to upgrade the following ports everytime you bump MESAVERSION: # +# - graphics/libEGL # - graphics/libGL -# - graphics/libGLU +# - grahpics/libglesv2 # - graphics/dri # # $FreeBSD$ @@ -21,7 +17,7 @@ MESADISTVERSION=${MESABASEVERSION}${MESASUBVERSION:C/^(.)/-\1/} .if defined(WITH_NEW_XORG) -MESABASEVERSION= 8.0.5 +MESABASEVERSION= 9.1.6 # if there is a subversion, include the '-' between 7.11-rc2 for example. MESASUBVERSION= PLIST_SUB+= OLD="@comment " NEW="" @@ -35,64 +31,80 @@ DISTFILES= MesaLib-${MESADISTVERSION}${EXTRACT_SUFX} MAINTAINER?= x11@FreeBSD.org -# HACK: added lang/python as build dependency - we need to check, which -# python versions are cleanly supported by Mesa BUILD_DEPENDS+= makedepend:${PORTSDIR}/devel/makedepend \ - python:${PORTSDIR}/lang/python \ + python2:${PORTSDIR}/lang/python2 \ ${PYTHON_SITELIBDIR}/libxml2.py:${PORTSDIR}/textproc/py-libxml2 -USES+= bison -USE_PYTHON_BUILD=yes +USES= bison gmake pathfix pkgconfig shebangfix +USE_PYTHON_BUILD=-2.7 USE_BZIP2= yes -USE_GMAKE= yes USE_LDCONFIG= yes GNU_CONFIGURE= yes CPPFLAGS+= -I${LOCALBASE}/include LDFLAGS+= -L${LOCALBASE}/lib -CONFIGURE_ARGS+=--enable-gallium-llvm=no --without-gallium-drivers \ - --disable-egl +.if ${OSVERSION} < 1000033 +BUILD_DEPENDS+= ${LOCALBASE}/bin/flex:${PORTSDIR}/textproc/flex +CONFIGURE_ENV+=ac_cv_prog_LEX=${LOCALBASE}/bin/flex +.endif + .if defined(WITH_NEW_XORG) -EXTRA_PATCHES+= ${PATCHDIR}/extra-configure \ - ${PATCHDIR}/extra-src-glsl_ir_constant_expression.cpp \ - ${PATCHDIR}/extra-src__gallium__include__pipe__p_config.h \ - ${PATCHDIR}/extra-src__mesa__drivers__dri__nouveau__nouveau_array.c \ - ${PATCHDIR}/extra-src__mesa__drivers__dri__nouveau__nouveau_render_t.c \ - ${PATCHDIR}/extra-src_glx_XF86dri.c +USE_AUTOTOOLS= autoconf:env automake:env libtool:env +# probably be shared lib, and in it own port. +CONFIGURE_ARGS+= --enable-shared-glapi=no +# we need to reapply these patches because we doing wierd stuff with autogen +REAPPLY_PATCHES= \ + ${PATCHDIR}/patch-configure \ + ${PATCHDIR}/patch-src_egl_main_Makefile.in \ + ${PATCHDIR}/patch-src_glx_Makefile.in \ + ${PATCHDIR}/patch-src_mapi_es2api_Makefile.in \ + ${PATCHDIR}/patch-src_mapi_shared-glapi_Makefile.in \ + ${PATCHDIR}/patch-src_mesa_drivers_dri_common_Makefile.in \ + ${PATCHDIR}/patch-src_mesa_drivers_dri_common_xmlpool_Makefile.in \ + ${PATCHDIR}/patch-src_mesa_libdricore_Makefile.in + +python_OLD_CMD= "/usr/bin/env[[:space:]]python" +python_CMD= ${LOCALBASE}/bin/python2 +SHEBANG_FILES= src/gallium/*/*/*.py src/gallium/tools/trace/*.py \ + src/gallium/drivers/svga/svgadump/svga_dump.py \ + src/glsl/tests/compare_ir src/mapi/glapi/gen/*.py \ + src/mapi/mapi/mapi_abi.py .else -EXTRA_PATCHES+= ${PATCHDIR}/extra-configure-old \ - ${PATCHDIR}/extra-mach64_context.h-old \ - ${PATCHDIR}/extra-src__mesa__x86-64__glapi_x86-64.S \ - ${PATCHDIR}/extra-src__mesa__x86-64__xform4.S \ - ${PATCHDIR}/extra-src__mesa__x86__glapi_x86.S \ - ${PATCHDIR}/extra-src__mesa__x86__read_rgba_span_x86.S \ - ${PATCHDIR}/extra-src_glx_x11_XF86dri.c -CONFIGURE_ARGS+=--disable-glut --disable-glw -.endif +CONFIGURE_ARGS+=--disable-glut --disable-glw --disable-glu ALL_TARGET= default +.endif MASTERDIR= ${.CURDIR}/../../graphics/libGL +.if defined(WITH_NEW_XORG) PATCHDIR= ${MASTERDIR}/files +.else +PATCHDIR= ${MASTERDIR}/files-old +.endif DESCR= ${.CURDIR}/pkg-descr PLIST= ${.CURDIR}/pkg-plist WRKSRC= ${WRKDIR}/Mesa-${MESADISTVERSION} -.if !defined(ARCH) -ARCH!= uname -p -.endif - COMPONENT= ${PORTNAME:L:C/^lib//:C/mesa-//} -.if ${COMPONENT:Mglu} == "" -CONFIGURE_ARGS+= --disable-glu +.if ${COMPONENT:Mglesv2} == "" +CONFIGURE_ARGS+= --disable-gles2 +.else +CONFIGURE_ARGS+= --enable-gles2 .endif +.if ${COMPONENT:Megl} == "" +CONFIGURE_ARGS+= --disable-egl +.else +CONFIGURE_ARGS+= --enable-egl +.endif + .if ${COMPONENT:Mdri} == "" -CONFIGURE_ARGS+= --with-dri-drivers=no +CONFIGURE_ARGS+=--with-dri-drivers=no +CONFIGURE_ARGS+=--enable-gallium-llvm=no --without-gallium-drivers .else -CONFIGURE_ARGS+= --with-dri-drivers="i915,i965,r200,radeon,swrast" +# done in the dri port .endif .if !defined(WITH_NEW_XORG) @@ -106,8 +118,35 @@ post-patch: @${REINPLACE_CMD} -e 's|-ffast-math|${FAST_MATH}|' -e 's|x86_64|amd64|' \ ${WRKSRC}/configure + @${REINPLACE_CMD} -e 's|/etc/|${PREFIX}/etc/|g' \ + ${WRKSRC}/src/mesa/drivers/dri/common/xmlconfig.c +.if !defined(WITH_NEW_XORG) @${REINPLACE_CMD} -e 's|[$$](INSTALL_LIB_DIR)/pkgconfig|${PREFIX}/libdata/pkgconfig|' \ ${WRKSRC}/src/glu/Makefile \ ${WRKSRC}/src/mesa/Makefile \ ${WRKSRC}/src/mesa/drivers/dri/Makefile +.else + @${REINPLACE_CMD} -e 's|#!/use/bin/python|#!${LOCALBASE}/bin/python2|g' \ + ${WRKSRC}/src/mesa/drivers/dri/common/xmlpool/gen_xmlpool.py \ + ${WRKSRC}/src/glsl/builtins/tools/*.py + @${REINPLACE_CMD} -e 's|!/use/bin/python2|!${LOCALBASE}/bin/python2|g' \ + ${WRKSRC}/src/mesa/main/get_hash_generator.py \ + ${WRKSRC}/src/mapi/glapi/gen/gl_enums.py \ + ${WRKSRC}/src/mapi/glapi/gen/gl_table.py \ +.endif + +pre-configure: +# workaround for stupid rerunning configure in do-build step +# xxx +.if defined(WITH_NEW_XORG) + cd ${WRKSRC} && env NOCONFIGURE=1 sh autogen.sh +. for file in ${REAPPLY_PATCHES} + @cd ${WRKSRC} && ${PATCH} -p0 --quiet < ${file} +. endfor +# make sure the pkg-config files are installed in the correct place. +# this was reverted by running autogen.sh + @${FIND} ${WRKSRC} -name Makefile.in -type f | ${XARGS} ${REINPLACE_CMD} -e \ + 's|[(]libdir[)]/pkgconfig|(prefix)/libdata/pkgconfig|g' ; +.endif + Index: graphics/libGL/distinfo =================================================================== --- graphics/libGL/distinfo (revision 328562) +++ graphics/libGL/distinfo (working copy) @@ -1,4 +1,4 @@ SHA256 (MesaLib-7.6.1.tar.bz2) = 701f0e4cb85d6298181651b780d1c0a439fadd02aad29ee6623fc05588bb8d44 SIZE (MesaLib-7.6.1.tar.bz2) = 4886995 -SHA256 (MesaLib-8.0.5.tar.bz2) = 511b8da34f8e69ed24caf422964fb7ae747f3b1d8093f6b8aa2602164a475a5e -SIZE (MesaLib-8.0.5.tar.bz2) = 5734571 +SHA256 (MesaLib-9.1.6.tar.bz2) = e632dff0acafad0a59dc208d16dedb37f7bd58f94c5d58c4b51912e41d005e3d +SIZE (MesaLib-9.1.6.tar.bz2) = 6134267 Index: graphics/libGL/files/extra-configure =================================================================== --- graphics/libGL/files/extra-configure (revision 328562) +++ graphics/libGL/files/extra-configure (working copy) @@ -1,40 +0,0 @@ ---- configure.orig 2012-07-10 17:30:46.000000000 +0200 -+++ configure 2012-09-01 13:27:22.000000000 +0200 -@@ -9017,9 +9017,34 @@ - DEFINES="$DEFINES -DPTHREADS -DUSE_EXTERNAL_DXTN_LIB=1" - DEFINES="$DEFINES -DIN_DRI_DRIVER -DHAVE_ALIAS" - -- if test "x$DRI_DIRS" = "xyes"; then -- DRI_DIRS="i915 i965 nouveau r200 radeon swrast" -- fi -+ case "$host_cpu" in -+ x86_64) -+ # i810 is missing because there is no x86-64 system where it -+ # could *ever* be used. -+ if test "x$DRI_DIRS" = "xyes"; then -+ DRI_DIRS="i915 i965 nouveau r200 radeon swrast" -+ fi -+ ;; -+ i*86) -+ if test "x$DRI_DIRS" = "xyes"; then -+ DRI_DIRS="i915 i965 nouveau r200 radeon swrast" -+ fi -+ ;; -+ powerpc*) -+ # Build only the drivers for cards that exist on PowerPC. -+ # At some point MGA will be added, but not yet. -+ if test "x$DRI_DIRS" = "xyes"; then -+ DRI_DIRS="r200 radeon swrast" -+ fi -+ ;; -+ sparc*) -+ # Build only the drivers for cards that exist on SPARC. -+ if test "x$DRI_DIRS" = "xyes"; then -+ DRI_DIRS="r200 radeon swrast" -+ fi -+ ;; -+ esac -+ - ;; - gnu*) - DEFINES="$DEFINES -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER" Index: graphics/libGL/files/extra-configure-old =================================================================== --- graphics/libGL/files/extra-configure-old (revision 328562) +++ graphics/libGL/files/extra-configure-old (working copy) @@ -1,43 +0,0 @@ ---- configure.orig 2009-12-22 03:31:30.000000000 +0100 -+++ configure 2012-06-27 19:49:26.000000000 +0200 -@@ -6946,12 +6946,35 @@ - CXXFLAGS="$CXXFLAGS -ansi -pedantic" - fi - -- # ffb and gamma are missing because they have not been converted -- # to use the new interface. -- if test "x$DRI_DIRS" = "xyes"; then -- DRI_DIRS="i810 i915 i965 mach64 mga r128 r200 r300 r600 radeon tdfx \ -+ case "$host_cpu" in -+ x86_64) -+ # i810 is missing because there is no x86-64 system where it -+ # could *ever* be used. -+ if test "x$DRI_DIRS" = "xyes"; then -+ DRI_DIRS="i915 i965 mach64 mga r128 r200 r300 r600 radeon tdfx \ - unichrome savage sis swrast" -- fi -+ fi -+ ;; -+ i*86) -+ if test "x$DRI_DIRS" = "xyes"; then -+ DRI_DIRS="i810 i915 i965 mach64 mga r128 r200 r300 r600 radeon tdfx \ -+ unichrome savage sis swrast" -+ fi -+ ;; -+ powerpc*) -+ # Build only the drivers for cards that exist on PowerPC. -+ # At some point MGA will be added, but not yet. -+ if test "x$DRI_DIRS" = "xyes"; then -+ DRI_DIRS="mach64 r128 r200 r300 r600 radeon tdfx swrast" -+ fi -+ ;; -+ sparc*) -+ # Build only the drivers for cards that exist on SPARC. -+ if test "x$DRI_DIRS" = "xyes"; then -+ DRI_DIRS="mach64 r128 r200 r300 r600 radeon swrast" -+ fi -+ ;; -+ esac - ;; - gnu*) - DEFINES="$DEFINES -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER" Index: graphics/libGL/files/extra-mach64_context.h-old =================================================================== --- graphics/libGL/files/extra-mach64_context.h-old (revision 328562) +++ graphics/libGL/files/extra-mach64_context.h-old (working copy) @@ -1,20 +0,0 @@ ---- src/mesa/drivers/dri/mach64/mach64_context.h.orig 2012-06-27 19:59:32.000000000 +0200 -+++ src/mesa/drivers/dri/mach64/mach64_context.h 2012-06-27 20:08:30.000000000 +0200 -@@ -294,11 +294,14 @@ - #define LE32_OUT( x, y ) do { *(GLuint *)(x) = (y); } while (0) - #define LE32_OUT_FLOAT( x, y ) do { *(GLfloat *)(x) = (y); } while (0) - #else --#ifndef __OpenBSD__ --#include --#else -+#if defined(__OpenBSD__) - #include - #define bswap_32 bswap32 -+#elif defined(__FreeBSD__) -+#include -+#define bswap_32 bswap32 -+#else -+#include - #endif - - #define LE32_IN( x ) bswap_32( *(GLuint *)(x) ) Index: graphics/libGL/files/extra-src-glsl_ir_constant_expression.cpp =================================================================== --- graphics/libGL/files/extra-src-glsl_ir_constant_expression.cpp (revision 328562) +++ graphics/libGL/files/extra-src-glsl_ir_constant_expression.cpp (working copy) @@ -1,14 +0,0 @@ ---- src/glsl/ir_constant_expression.cpp.orig 2011-07-23 15:08:44.000000000 +0200 -+++ src/glsl/ir_constant_expression.cpp 2011-07-23 15:09:03.000000000 +0200 -@@ -39,6 +39,11 @@ - #include "ir_visitor.h" - #include "glsl_types.h" - -+#include -+#if __FreeBSD_version <= 704100 || (__FreeBSD_version >= 800000 && __FreeBSD_version < 802502) || (__FreeBSD_version >= 900000 && __FreeBSD_version < 900027) -+#define log2(x) (log(x) / log(2)) -+#endif -+ - static float - dot(ir_constant *op0, ir_constant *op1) - { Index: graphics/libGL/files/extra-src__gallium__include__pipe__p_config.h =================================================================== --- graphics/libGL/files/extra-src__gallium__include__pipe__p_config.h (revision 328562) +++ graphics/libGL/files/extra-src__gallium__include__pipe__p_config.h (working copy) @@ -1,25 +0,0 @@ ---- src/gallium/include/pipe/p_config.h.orig 2011-10-15 02:43:58.000000000 +0200 -+++ src/gallium/include/pipe/p_config.h 2012-06-28 21:27:06.000000000 +0200 -@@ -106,6 +106,13 @@ - #endif - #endif - -+#if defined(__sparc__) || defined(__sparc64__) -+#define PIPE_ARCH_SPARC -+#if defined(__sparc64__) -+#define PIPE_ARCH_SPARC_64 -+#endif -+#endif -+ - - /* - * Endian detection. -@@ -133,7 +140,7 @@ - - #if defined(PIPE_ARCH_X86) || defined(PIPE_ARCH_X86_64) - #define PIPE_ARCH_LITTLE_ENDIAN --#elif defined(PIPE_ARCH_PPC) || defined(PIPE_ARCH_PPC_64) -+#elif defined(PIPE_ARCH_PPC) || defined(PIPE_ARCH_PPC_64) || defined(PIPE_ARCH_SPARC) || defined(PIPE_ARCH_SPARC_64) - #define PIPE_ARCH_BIG_ENDIAN - #endif - Index: graphics/libGL/files/extra-src__mesa__drivers__dri__nouveau__nouveau_array.c =================================================================== --- graphics/libGL/files/extra-src__mesa__drivers__dri__nouveau__nouveau_array.c (revision 328562) +++ graphics/libGL/files/extra-src__mesa__drivers__dri__nouveau__nouveau_array.c (working copy) @@ -1,99 +0,0 @@ ---- src/mesa/drivers/dri/nouveau/nouveau_array.c.orig 2011-01-06 01:19:15.000000000 +0100 -+++ src/mesa/drivers/dri/nouveau/nouveau_array.c 2012-04-28 18:27:06.000000000 +0200 -@@ -29,54 +29,71 @@ - #include "nouveau_array.h" - #include "nouveau_bufferobj.h" - -+#define EXTRACT(in_t, out_t) extract_func_##in_t##_to_##out_t -+ -+#define EXTRACT_FUNC(in_t, out_t, k) \ -+static out_t EXTRACT(in_t, out_t) \ -+(struct nouveau_array *a, int i, int j) { \ -+ in_t x = ((in_t *)(a->buf + i * a->stride))[j]; \ -+ \ -+ return (out_t)x / (k); \ -+} -+ -+EXTRACT_FUNC(GLchar, unsigned, 1); -+EXTRACT_FUNC(GLchar, float, SCHAR_MAX); -+EXTRACT_FUNC(GLubyte, unsigned, 1); -+EXTRACT_FUNC(GLubyte, float, UCHAR_MAX); -+EXTRACT_FUNC(GLshort, unsigned, 1); -+EXTRACT_FUNC(GLshort, float, SHRT_MAX); -+EXTRACT_FUNC(GLushort, unsigned, 1); -+EXTRACT_FUNC(GLushort, float, USHRT_MAX); -+EXTRACT_FUNC(GLint, unsigned, 1); -+EXTRACT_FUNC(GLint, float, INT_MAX); -+EXTRACT_FUNC(GLuint, unsigned, 1); -+EXTRACT_FUNC(GLuint, float, UINT_MAX); -+EXTRACT_FUNC(GLfloat, unsigned, 1.0 / UINT_MAX); -+EXTRACT_FUNC(GLfloat, float, 1); -+ -+#undef EXTRACT_FUNC -+ - static void - get_array_extract(struct nouveau_array *a, extract_u_t *extract_u, - extract_f_t *extract_f) - { --#define EXTRACT(in_t, out_t, k) \ -- ({ \ -- auto out_t f(struct nouveau_array *, int, int); \ -- out_t f(struct nouveau_array *a, int i, int j) { \ -- in_t x = ((in_t *)(a->buf + i * a->stride))[j]; \ -- \ -- return (out_t)x / (k); \ -- }; \ -- f; \ -- }); -- - switch (a->type) { - case GL_BYTE: -- *extract_u = EXTRACT(char, unsigned, 1); -- *extract_f = EXTRACT(char, float, SCHAR_MAX); -+ *extract_u = EXTRACT(GLchar, unsigned); -+ *extract_f = EXTRACT(GLchar, float); - break; - case GL_UNSIGNED_BYTE: -- *extract_u = EXTRACT(unsigned char, unsigned, 1); -- *extract_f = EXTRACT(unsigned char, float, UCHAR_MAX); -+ *extract_u = EXTRACT(GLubyte, unsigned); -+ *extract_f = EXTRACT(GLubyte, float); - break; - case GL_SHORT: -- *extract_u = EXTRACT(short, unsigned, 1); -- *extract_f = EXTRACT(short, float, SHRT_MAX); -+ *extract_u = EXTRACT(GLshort, unsigned); -+ *extract_f = EXTRACT(GLshort, float); - break; - case GL_UNSIGNED_SHORT: -- *extract_u = EXTRACT(unsigned short, unsigned, 1); -- *extract_f = EXTRACT(unsigned short, float, USHRT_MAX); -+ *extract_u = EXTRACT(GLushort, unsigned); -+ *extract_f = EXTRACT(GLushort, float); - break; - case GL_INT: -- *extract_u = EXTRACT(int, unsigned, 1); -- *extract_f = EXTRACT(int, float, INT_MAX); -+ *extract_u = EXTRACT(GLint, unsigned); -+ *extract_f = EXTRACT(GLint, float); - break; - case GL_UNSIGNED_INT: -- *extract_u = EXTRACT(unsigned int, unsigned, 1); -- *extract_f = EXTRACT(unsigned int, float, UINT_MAX); -+ *extract_u = EXTRACT(GLuint, unsigned); -+ *extract_f = EXTRACT(GLuint, float); - break; - case GL_FLOAT: -- *extract_u = EXTRACT(float, unsigned, 1.0 / UINT_MAX); -- *extract_f = EXTRACT(float, float, 1); -+ *extract_u = EXTRACT(GLfloat, unsigned); -+ *extract_f = EXTRACT(GLfloat, float); - break; - default: - assert(0); - } - } -+#undef EXTRACT - - void - nouveau_init_array(struct nouveau_array *a, int attr, int stride, Index: graphics/libGL/files/extra-src__mesa__drivers__dri__nouveau__nouveau_render_t.c =================================================================== --- graphics/libGL/files/extra-src__mesa__drivers__dri__nouveau__nouveau_render_t.c (revision 328562) +++ graphics/libGL/files/extra-src__mesa__drivers__dri__nouveau__nouveau_render_t.c (working copy) @@ -1,91 +0,0 @@ ---- src/mesa/drivers/dri/nouveau/nouveau_render_t.c.orig 2011-01-06 01:19:34.000000000 +0100 -+++ src/mesa/drivers/dri/nouveau/nouveau_render_t.c 2012-04-28 18:27:06.000000000 +0200 -@@ -97,52 +97,49 @@ - } \ - } while (0) - --/* -- * Select an appropriate dispatch function for the given index buffer. -- */ --static dispatch_t --get_array_dispatch(struct nouveau_array *a) -+static void -+dispatch_l(struct gl_context *ctx, unsigned int start, int delta, -+ unsigned int n) - { -- if (!a->fields) { -- auto void f(struct gl_context *, unsigned int, int, unsigned int); -- -- void f(struct gl_context *ctx, unsigned int start, int delta, -- unsigned int n) { -- struct nouveau_channel *chan = context_chan(ctx); -- RENDER_LOCALS(ctx); -+ struct nouveau_channel *chan = context_chan(ctx); -+ RENDER_LOCALS(ctx); - -- EMIT_VBO(L, ctx, start, delta, n); -- }; -- -- return f; -- -- } else if (a->type == GL_UNSIGNED_INT) { -- auto void f(struct gl_context *, unsigned int, int, unsigned int); -- -- void f(struct gl_context *ctx, unsigned int start, int delta, -- unsigned int n) { -- struct nouveau_channel *chan = context_chan(ctx); -- RENDER_LOCALS(ctx); -+ EMIT_VBO(L, ctx, start, delta, n); -+} - -- EMIT_VBO(I32, ctx, start, delta, n); -- }; -+static void -+dispatch_i32(struct gl_context *ctx, unsigned int start, int delta, -+ unsigned int n) -+{ -+ struct nouveau_channel *chan = context_chan(ctx); -+ RENDER_LOCALS(ctx); - -- return f; -+ EMIT_VBO(I32, ctx, start, delta, n); -+} - -- } else { -- auto void f(struct gl_context *, unsigned int, int, unsigned int); -+static void -+dispatch_i16(struct gl_context *ctx, unsigned int start, int delta, -+ unsigned int n) -+{ -+ struct nouveau_channel *chan = context_chan(ctx); -+ RENDER_LOCALS(ctx); - -- void f(struct gl_context *ctx, unsigned int start, int delta, -- unsigned int n) { -- struct nouveau_channel *chan = context_chan(ctx); -- RENDER_LOCALS(ctx); -- -- EMIT_VBO(I32, ctx, start, delta, n & 1); -- EMIT_VBO(I16, ctx, start, delta, n & ~1); -- }; -+ EMIT_VBO(I32, ctx, start, delta, n & 1); -+ EMIT_VBO(I16, ctx, start, delta, n & ~1); -+} - -- return f; -- } -+/* -+ * Select an appropriate dispatch function for the given index buffer. -+ */ -+static dispatch_t -+get_array_dispatch(struct nouveau_array *a) -+{ -+ if (!a->fields) -+ return dispatch_l; -+ else if (a->type == GL_UNSIGNED_INT) -+ return dispatch_i32; -+ else -+ return dispatch_i16; - } - - /* Index: graphics/libGL/files/extra-src__mesa__x86-64__glapi_x86-64.S =================================================================== --- graphics/libGL/files/extra-src__mesa__x86-64__glapi_x86-64.S (revision 328562) +++ graphics/libGL/files/extra-src__mesa__x86-64__glapi_x86-64.S (working copy) @@ -1,12 +0,0 @@ ---- ./src/mesa/x86-64/glapi_x86-64.S.orig 2009-03-13 04:28:49.000000000 +0100 -+++ ./src/mesa/x86-64/glapi_x86-64.S 2011-01-28 18:12:18.000000000 +0100 -@@ -73,7 +73,8 @@ _x86_64_get_dispatch: - - .p2align 4,,15 - _x86_64_get_dispatch: -- movq _gl_DispatchTSD(%rip), %rdi -+ movq _gl_DispatchTSD@GOTPCREL(%rip), %rax -+ movl (%rax), %edi - jmp pthread_getspecific@PLT - - #elif defined(THREADS) Index: graphics/libGL/files/extra-src__mesa__x86-64__xform4.S =================================================================== --- graphics/libGL/files/extra-src__mesa__x86-64__xform4.S (revision 328562) +++ graphics/libGL/files/extra-src__mesa__x86-64__xform4.S (working copy) @@ -1,74 +0,0 @@ ---- src/mesa/x86-64/xform4.S.orig 2009-01-22 18:38:35.000000000 +0100 -+++ src/mesa/x86-64/xform4.S 2011-05-09 21:26:00.000000000 +0200 -@@ -53,7 +53,7 @@ _mesa_x86_64_transform_points4_general: - * rdx = source - */ - movl V4F_COUNT(%rdx), %ecx /* count */ -- movzx V4F_STRIDE(%rdx), %eax /* stride */ -+ movzbl V4F_STRIDE(%rdx), %eax /* stride */ - - movl %ecx, V4F_COUNT(%rdi) /* set dest count */ - movl $4, V4F_SIZE(%rdi) /* set dest size */ -@@ -116,7 +116,7 @@ p4_constants: - .byte 0x00, 0x00, 0x00, 0x00 - .byte 0x00, 0x00, 0x00, 0x00 - .byte 0x00, 0x00, 0x00, 0x00 --.float 0f+1.0 -+.float 1.0 - - .text - .align 16 -@@ -135,7 +135,7 @@ _mesa_x86_64_transform_points4_3d: - movaps 16(%rax), %xmm10 - - movl V4F_COUNT(%rdx), %ecx /* count */ -- movzx V4F_STRIDE(%rdx), %eax /* stride */ -+ movzbl V4F_STRIDE(%rdx), %eax /* stride */ - - movl %ecx, V4F_COUNT(%rdi) /* set dest count */ - movl $4, V4F_SIZE(%rdi) /* set dest size */ -@@ -195,7 +195,7 @@ p4_3d_done: - _mesa_x86_64_transform_points4_identity: - - movl V4F_COUNT(%rdx), %ecx /* count */ -- movzx V4F_STRIDE(%rdx), %eax /* stride */ -+ movzbl V4F_STRIDE(%rdx), %eax /* stride */ - - movl %ecx, V4F_COUNT(%rdi) /* set dest count */ - movl $4, V4F_SIZE(%rdi) /* set dest size */ -@@ -223,7 +223,7 @@ p4_identity_done: - _mesa_3dnow_transform_points4_3d_no_rot: - - movl V4F_COUNT(%rdx), %ecx /* count */ -- movzx V4F_STRIDE(%rdx), %eax /* stride */ -+ movzbl V4F_STRIDE(%rdx), %eax /* stride */ - - movl %ecx, V4F_COUNT(%rdi) /* set dest count */ - movl $4, V4F_SIZE(%rdi) /* set dest size */ -@@ -287,7 +287,7 @@ p4_3d_no_rot_done: - _mesa_3dnow_transform_points4_perspective: - - movl V4F_COUNT(%rdx), %ecx /* count */ -- movzx V4F_STRIDE(%rdx), %eax /* stride */ -+ movzbl V4F_STRIDE(%rdx), %eax /* stride */ - - movl %ecx, V4F_COUNT(%rdi) /* set dest count */ - movl $4, V4F_SIZE(%rdi) /* set dest size */ -@@ -353,7 +353,7 @@ p4_perspective_done: - _mesa_3dnow_transform_points4_2d_no_rot: - - movl V4F_COUNT(%rdx), %ecx /* count */ -- movzx V4F_STRIDE(%rdx), %eax /* stride */ -+ movzbl V4F_STRIDE(%rdx), %eax /* stride */ - - movl %ecx, V4F_COUNT(%rdi) /* set dest count */ - movl $4, V4F_SIZE(%rdi) /* set dest size */ -@@ -408,7 +408,7 @@ p4_2d_no_rot_done: - _mesa_3dnow_transform_points4_2d: - - movl V4F_COUNT(%rdx), %ecx /* count */ -- movzx V4F_STRIDE(%rdx), %eax /* stride */ -+ movzbl V4F_STRIDE(%rdx), %eax /* stride */ - - movl %ecx, V4F_COUNT(%rdi) /* set dest count */ - movl $4, V4F_SIZE(%rdi) /* set dest size */ Index: graphics/libGL/files/extra-src__mesa__x86__glapi_x86.S =================================================================== --- graphics/libGL/files/extra-src__mesa__x86__glapi_x86.S (revision 328562) +++ graphics/libGL/files/extra-src__mesa__x86__glapi_x86.S (working copy) @@ -1,11 +0,0 @@ ---- ./src/mesa/x86/glapi_x86.S.orig 2009-03-13 04:28:49.000000000 +0100 -+++ ./src/mesa/x86/glapi_x86.S 2011-01-28 18:11:56.000000000 +0100 -@@ -47,7 +47,7 @@ - #define GL_OFFSET(x) CODEPTR(REGOFF(4 * x, EAX)) - - #if defined(GNU_ASSEMBLER) && !defined(__DJGPP__) && !defined(__MINGW32__) --#define GLOBL_FN(x) GLOBL x ; .type x, function -+#define GLOBL_FN(x) GLOBL x ; .type x, @function - #else - #define GLOBL_FN(x) GLOBL x - #endif Index: graphics/libGL/files/extra-src__mesa__x86__read_rgba_span_x86.S =================================================================== --- graphics/libGL/files/extra-src__mesa__x86__read_rgba_span_x86.S (revision 328562) +++ graphics/libGL/files/extra-src__mesa__x86__read_rgba_span_x86.S (working copy) @@ -1,11 +0,0 @@ ---- ./src/mesa/x86/read_rgba_span_x86.S.orig 2008-08-25 16:46:47.000000000 +0200 -+++ ./src/mesa/x86/read_rgba_span_x86.S 2011-01-28 18:10:06.000000000 +0100 -@@ -648,7 +648,7 @@ _generic_read_RGBA_span_RGB565_MMX: - testl $0x01, %ecx - je .L01 - -- movzxw (%eax), %ecx -+ movzwl (%eax), %ecx - movd %ecx, %mm4 - - pshufw $0x00, %mm4, %mm0 Index: graphics/libGL/files/extra-src_glx_XF86dri.c =================================================================== --- graphics/libGL/files/extra-src_glx_XF86dri.c (revision 328562) +++ graphics/libGL/files/extra-src_glx_XF86dri.c (working copy) @@ -1,38 +0,0 @@ ---- src/glx/XF86dri.c.orig 2012-10-24 19:03:59.000000000 +0000 -+++ src/glx/XF86dri.c 2013-05-29 10:07:33.000000000 +0000 -@@ -43,6 +43,7 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN - #include - #include - #include "xf86dristr.h" -+#include - - static XExtensionInfo _xf86dri_info_data; - static XExtensionInfo *xf86dri_info = &_xf86dri_info_data; -@@ -201,7 +202,11 @@ XF86DRIOpenConnection(Display * dpy, int - } - - if (rep.length) { -- if (!(*busIdString = (char *) Xcalloc(rep.busIdStringLength + 1, 1))) { -+ if (rep.busIdStringLength < INT_MAX) -+ *busIdString = Xcalloc(rep.busIdStringLength + 1, 1); -+ else -+ *busIdString = NULL; -+ if (*busIdString == NULL) { - _XEatData(dpy, ((rep.busIdStringLength + 3) & ~3)); - UnlockDisplay(dpy); - SyncHandle(); -@@ -300,9 +305,11 @@ XF86DRIGetClientDriverName(Display * dpy - *ddxDriverPatchVersion = rep.ddxDriverPatchVersion; - - if (rep.length) { -- if (! -- (*clientDriverName = -- (char *) Xcalloc(rep.clientDriverNameLength + 1, 1))) { -+ if (rep.clientDriverNameLength < INT_MAX) -+ *clientDriverName = Xcalloc(rep.clientDriverNameLength + 1, 1); -+ else -+ *clientDriverName = NULL; -+ if (*clientDriverName == NULL) { - _XEatData(dpy, ((rep.clientDriverNameLength + 3) & ~3)); - UnlockDisplay(dpy); - SyncHandle(); Index: graphics/libGL/files/extra-src_glx_x11_XF86dri.c =================================================================== --- graphics/libGL/files/extra-src_glx_x11_XF86dri.c (revision 328562) +++ graphics/libGL/files/extra-src_glx_x11_XF86dri.c (working copy) @@ -1,38 +0,0 @@ ---- src/glx/x11/XF86dri.c.orig 2009-06-17 18:35:16.000000000 +0000 -+++ src/glx/x11/XF86dri.c 2013-05-29 10:09:37.000000000 +0000 -@@ -43,6 +43,7 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN - #include - #include - #include "xf86dristr.h" -+#include - - - #if defined(__GNUC__) && (__GNUC__ * 100 + __GNUC_MINOR__) >= 303 -@@ -212,7 +213,11 @@ XF86DRIOpenConnection(Display * dpy, int - } - - if (rep.length) { -- if (!(*busIdString = (char *) Xcalloc(rep.busIdStringLength + 1, 1))) { -+ if (rep.busIdStringLength < INT_MAX) -+ *busIdString = Xcalloc(rep.busIdStringLength + 1, 1); -+ else -+ *busIdString = NULL; -+ if (*busIdString == NULL) { - _XEatData(dpy, ((rep.busIdStringLength + 3) & ~3)); - UnlockDisplay(dpy); - SyncHandle(); -@@ -311,9 +316,11 @@ XF86DRIGetClientDriverName(Display * dpy - *ddxDriverPatchVersion = rep.ddxDriverPatchVersion; - - if (rep.length) { -- if (! -- (*clientDriverName = -- (char *) Xcalloc(rep.clientDriverNameLength + 1, 1))) { -+ if (rep.clientDriverNameLength < INT_MAX) -+ *clientDriverName = Xcalloc(rep.clientDriverNameLength + 1, 1); -+ else -+ *clientDriverName = NULL; -+ if (*clientDriverName == NULL) { - _XEatData(dpy, ((rep.clientDriverNameLength + 3) & ~3)); - UnlockDisplay(dpy); - SyncHandle(); Index: graphics/libGL/files/patch-configure =================================================================== --- graphics/libGL/files/patch-configure (revision 0) +++ graphics/libGL/files/patch-configure (working copy) @@ -0,0 +1,49 @@ +--- configure.orig 2013-08-01 23:22:15.000000000 +0200 ++++ configure 2013-08-19 20:05:02.000000000 +0200 +@@ -21046,9 +21046,34 @@ + DEFINES="$DEFINES -DHAVE_PTHREAD -DUSE_EXTERNAL_DXTN_LIB=1" + DEFINES="$DEFINES -DIN_DRI_DRIVER -DHAVE_ALIAS" + +- if test "x$DRI_DIRS" = "xyes"; then +- DRI_DIRS="i915 i965 nouveau r200 radeon swrast" +- fi ++ case "$host_cpu" in ++ x86_64) ++ # i810 is missing because there is no x86-64 system where it ++ # could *ever* be used. ++ if test "x$DRI_DIRS" = "xyes"; then ++ DRI_DIRS="i915 i965 nouveau r200 radeon swrast" ++ fi ++ ;; ++ i*86) ++ if test "x$DRI_DIRS" = "xyes"; then ++ DRI_DIRS="i915 i965 nouveau r200 radeon swrast" ++ fi ++ ;; ++ powerpc*) ++ # Build only the drivers for cards that exist on PowerPC. ++ # At some point MGA will be added, but not yet. ++ if test "x$DRI_DIRS" = "xyes"; then ++ DRI_DIRS="r200 radeon swrast" ++ fi ++ ;; ++ sparc*) ++ # Build only the drivers for cards that exist on SPARC. ++ if test "x$DRI_DIRS" = "xyes"; then ++ DRI_DIRS="r200 radeon swrast" ++ fi ++ ;; ++ esac ++ + ;; + gnu*) + DEFINES="$DEFINES -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER" +@@ -23396,7 +23421,7 @@ + radeon_llvm_check() { + LLVM_REQUIRED_VERSION_MAJOR="3" + LLVM_REQUIRED_VERSION_MINOR="2" +- if test "$LLVM_VERSION_INT" -ne "${LLVM_REQUIRED_VERSION_MAJOR}0${LLVM_REQUIRED_VERSION_MINOR}"; then ++ if test "$LLVM_VERSION_INT" -lt "${LLVM_REQUIRED_VERSION_MAJOR}0${LLVM_REQUIRED_VERSION_MINOR}"; then + as_fn_error $? "LLVM $LLVM_REQUIRED_VERSION_MAJOR.$LLVM_REQUIRED_VERSION_MINOR with R600 target enabled is required. + To use the r600/radeonsi LLVM backend, you need to fetch the LLVM source from: + git://people.freedesktop.org/~tstellar/llvm master Property changes on: graphics/libGL/files/patch-configure ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: graphics/libGL/files/patch-src-glsl_ir_constant_expression.cpp =================================================================== --- graphics/libGL/files/patch-src-glsl_ir_constant_expression.cpp (revision 0) +++ graphics/libGL/files/patch-src-glsl_ir_constant_expression.cpp (working copy) @@ -0,0 +1,14 @@ +--- src/glsl/ir_constant_expression.cpp.orig 2011-07-23 15:08:44.000000000 +0200 ++++ src/glsl/ir_constant_expression.cpp 2011-07-23 15:09:03.000000000 +0200 +@@ -39,6 +39,11 @@ + #include "ir_visitor.h" + #include "glsl_types.h" + ++#include ++#if __FreeBSD_version <= 704100 || (__FreeBSD_version >= 800000 && __FreeBSD_version < 802502) || (__FreeBSD_version >= 900000 && __FreeBSD_version < 900027) ++#define log2(x) (log(x) / log(2)) ++#endif ++ + static float + dot(ir_constant *op0, ir_constant *op1) + { Property changes on: graphics/libGL/files/patch-src-glsl_ir_constant_expression.cpp ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Index: graphics/libGL/files/patch-src__gallium__include__pipe__p_config.h =================================================================== --- graphics/libGL/files/patch-src__gallium__include__pipe__p_config.h (revision 0) +++ graphics/libGL/files/patch-src__gallium__include__pipe__p_config.h (working copy) @@ -0,0 +1,25 @@ +--- src/gallium/include/pipe/p_config.h.orig 2011-10-15 02:43:58.000000000 +0200 ++++ src/gallium/include/pipe/p_config.h 2012-06-28 21:27:06.000000000 +0200 +@@ -106,6 +106,13 @@ + #endif + #endif + ++#if defined(__sparc__) || defined(__sparc64__) ++#define PIPE_ARCH_SPARC ++#if defined(__sparc64__) ++#define PIPE_ARCH_SPARC_64 ++#endif ++#endif ++ + + /* + * Endian detection. +@@ -133,7 +140,7 @@ + + #if defined(PIPE_ARCH_X86) || defined(PIPE_ARCH_X86_64) + #define PIPE_ARCH_LITTLE_ENDIAN +-#elif defined(PIPE_ARCH_PPC) || defined(PIPE_ARCH_PPC_64) ++#elif defined(PIPE_ARCH_PPC) || defined(PIPE_ARCH_PPC_64) || defined(PIPE_ARCH_SPARC) || defined(PIPE_ARCH_SPARC_64) + #define PIPE_ARCH_BIG_ENDIAN + #endif + Property changes on: graphics/libGL/files/patch-src__gallium__include__pipe__p_config.h ___________________________________________________________________ Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: graphics/libGL/files/patch-src_egl_main_Makefile.in =================================================================== --- graphics/libGL/files/patch-src_egl_main_Makefile.in (revision 0) +++ graphics/libGL/files/patch-src_egl_main_Makefile.in (working copy) @@ -0,0 +1,19 @@ +--- src/egl/main/Makefile.in.orig 2013-08-01 23:22:16.000000000 +0200 ++++ src/egl/main/Makefile.in 2013-09-01 11:33:47.000000000 +0200 +@@ -990,8 +990,14 @@ + # a while by putting a link to the driver into /lib of the build tree. + all-local: libEGL.la + $(MKDIR_P) $(top_builddir)/$(LIB_DIR); +- ln -f .libs/libEGL.so.1.0.0 $(top_builddir)/$(LIB_DIR)/libEGL.so.1 +- ln -sf libEGL.so.1 $(top_builddir)/$(LIB_DIR)/libEGL.so ++ base=$(basename $<); \ ++ dlname=$$(grep dlname= .libs/$< | cut -d "'" -f 2); \ ++ ver=$$(grep current= .libs/$< | cut -d "=" -f 2); \ ++ ln -f .libs/$$dlname $(top_builddir)/$(LIB_DIR)/$$dlname; \ ++ if [ ! -f $(top_builddir)/$(LIB_DIR)/$$base.so.$$ver ]; then \ ++ ln -sf $$dlname $(top_builddir)/$(LIB_DIR)/$$base.so.$$ver; \ ++ fi; \ ++ ln -sf $$base.so.$$ver $(top_builddir)/$(LIB_DIR)/$$base.so + + # Tell versions [3.59,3.63) of GNU make to not export all variables. + # Otherwise a system limit (for SysV at least) may be exceeded. Property changes on: graphics/libGL/files/patch-src_egl_main_Makefile.in ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: graphics/libGL/files/patch-src_gallium_drivers_r300_r300-chipset.c =================================================================== --- graphics/libGL/files/patch-src_gallium_drivers_r300_r300-chipset.c (revision 0) +++ graphics/libGL/files/patch-src_gallium_drivers_r300_r300-chipset.c (working copy) @@ -0,0 +1,26 @@ +diff --git a/src/gallium/drivers/r300/r300_chipset.c b/src/gallium/drivers/r300/r300_chipset.c +index 11061ed..daf990e 100644 +--- src/gallium/drivers/r300/r300_chipset.c ++++ src/gallium/drivers/r300/r300_chipset.c +@@ -48,6 +48,21 @@ static void r300_apply_hyperz_blacklist(struct r300_capabilities* caps) + }; + int i; + ++#if defined(__DragonFly__) || \ ++ defined(__FreeBSD__) || \ ++ defined(__NetBSD__) || \ ++ defined(__OpenBSD__) ++ const char *progname, *program_invocation_short_name; ++ ++ progname = getprogname(); ++ program_invocation_short_name = strrchr(progname, '/'); ++ if (program_invocation_short_name) { ++ program_invocation_short_name++; ++ } else { ++ program_invocation_short_name = progname; ++ } ++#endif ++ + for (i = 0; i < Elements(list); i++) { + if (strcmp(list[i], program_invocation_short_name) == 0) { + caps->zmask_ram = 0; Property changes on: graphics/libGL/files/patch-src_gallium_drivers_r300_r300-chipset.c ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: graphics/libGL/files/patch-src_gallium_drivers_r600_r600-asm.c =================================================================== --- graphics/libGL/files/patch-src_gallium_drivers_r600_r600-asm.c (revision 0) +++ graphics/libGL/files/patch-src_gallium_drivers_r600_r600-asm.c (working copy) @@ -0,0 +1,15 @@ +--- src/gallium/drivers/r600/r600_asm.c.orig 2013-03-20 00:28:25.000000000 +0100 ++++ src/gallium/drivers/r600/r600_asm.c 2013-06-26 23:29:14.000000000 +0200 +@@ -27,7 +27,12 @@ + #include "r600d.h" + + #include ++#if defined(__linux__) + #include ++#elif defined(__FreeBSD__) ++#include ++#define bswap_32(x) bswap32((x)) ++#endif + #include "util/u_memory.h" + #include "pipe/p_shader_tokens.h" + Property changes on: graphics/libGL/files/patch-src_gallium_drivers_r600_r600-asm.c ___________________________________________________________________ Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: graphics/libGL/files/patch-src_gallium_drivers_r600_r600-shader.c =================================================================== --- graphics/libGL/files/patch-src_gallium_drivers_r600_r600-shader.c (revision 0) +++ graphics/libGL/files/patch-src_gallium_drivers_r600_r600-shader.c (working copy) @@ -0,0 +1,15 @@ +--- src/gallium/drivers/r600/r600_shader.c.orig 2013-05-16 19:38:54.000000000 +0200 ++++ src/gallium/drivers/r600/r600_shader.c 2013-06-26 23:26:02.000000000 +0200 +@@ -35,7 +35,12 @@ + #include "util/u_memory.h" + #include + #include ++#if defined(__linux__) + #include ++#elif defined(__FreeBSD__) ++#include ++#define bswap_32(x) bswap32((x)) ++#endif + + /* CAYMAN notes + Why CAYMAN got loops for lots of instructions is explained here. Property changes on: graphics/libGL/files/patch-src_gallium_drivers_r600_r600-shader.c ___________________________________________________________________ Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: graphics/libGL/files/patch-src_gallium_drivers_r600_r600_state_common.c =================================================================== --- graphics/libGL/files/patch-src_gallium_drivers_r600_r600_state_common.c (revision 0) +++ graphics/libGL/files/patch-src_gallium_drivers_r600_r600_state_common.c (working copy) @@ -0,0 +1,15 @@ +--- src/gallium/drivers/r600/r600_state_common.c.orig 2013-03-06 00:25:39.000000000 +0100 ++++ src/gallium/drivers/r600/r600_state_common.c 2013-06-26 23:26:02.000000000 +0200 +@@ -33,7 +33,12 @@ + #include "util/u_memory.h" + #include "util/u_upload_mgr.h" + #include "tgsi/tgsi_parse.h" ++#if defined(__linux__) + #include ++#elif defined(__FreeBSD__) ++#include ++#define bswap_32(x) bswap32((x)) ++#endif + + #define R600_PRIM_RECTANGLE_LIST PIPE_PRIM_MAX + Property changes on: graphics/libGL/files/patch-src_gallium_drivers_r600_r600_state_common.c ___________________________________________________________________ Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: graphics/libGL/files/patch-src_gallium_drivers_radeon_radeon-llvm-emit.cpp =================================================================== --- graphics/libGL/files/patch-src_gallium_drivers_radeon_radeon-llvm-emit.cpp (revision 0) +++ graphics/libGL/files/patch-src_gallium_drivers_radeon_radeon-llvm-emit.cpp (working copy) @@ -0,0 +1,28 @@ +--- src/gallium/drivers/radeon/radeon_llvm_emit.cpp.orig 2013-08-19 21:23:06.000000000 +0200 ++++ src/gallium/drivers/radeon/radeon_llvm_emit.cpp 2013-08-19 21:30:58.000000000 +0200 +@@ -25,13 +25,13 @@ + */ + #include "radeon_llvm_emit.h" + +-#include +-#include ++#include ++#include + #include + #include + #include + #include +-#include ++#include + #include + #include + #include +@@ -39,7 +39,7 @@ + #include + #include + #include +-#include ++#include + + #include + #include Property changes on: graphics/libGL/files/patch-src_gallium_drivers_radeon_radeon-llvm-emit.cpp ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: graphics/libGL/files/patch-src_gallium_drivers_radeonsi_r600-buffer.c =================================================================== --- graphics/libGL/files/patch-src_gallium_drivers_radeonsi_r600-buffer.c (revision 0) +++ graphics/libGL/files/patch-src_gallium_drivers_radeonsi_r600-buffer.c (working copy) @@ -0,0 +1,16 @@ +--- src/gallium/drivers/radeonsi/r600_buffer.c.orig 2013-08-01 00:56:45.000000000 +0200 ++++ src/gallium/drivers/radeonsi/r600_buffer.c 2013-08-19 21:36:02.000000000 +0200 +@@ -24,7 +24,13 @@ + * Jerome Glisse + * Corbin Simpson + */ ++ ++#if defined(__linux__) + #include ++#elif defined(__FreeBSD__) ++#include ++#define bswap_32(x) bswap32((x)) ++#endif + + #include "pipe/p_screen.h" + #include "util/u_format.h" Property changes on: graphics/libGL/files/patch-src_gallium_drivers_radeonsi_r600-buffer.c ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: graphics/libGL/files/patch-src_gallium_winsys_svga_drm_vmw-screen-ioctl.c =================================================================== --- graphics/libGL/files/patch-src_gallium_winsys_svga_drm_vmw-screen-ioctl.c (revision 0) +++ graphics/libGL/files/patch-src_gallium_winsys_svga_drm_vmw-screen-ioctl.c (working copy) @@ -0,0 +1,18 @@ +diff --git a/src/gallium/winsys/svga/drm/vmw_screen_ioctl.c b/src/gallium/winsys/svga/drm/vmw_screen_ioctl.c +index 36888dc..62a6e6a 100644 +--- src/gallium/winsys/svga/drm/vmw_screen_ioctl.c ++++ src/gallium/winsys/svga/drm/vmw_screen_ioctl.c +@@ -66,6 +66,13 @@ struct vmw_region + */ + #define SVGA3D_SURFACE_HINT_SCANOUT (1 << 9) + ++#if defined(__DragonFly__) || \ ++ defined(__FreeBSD__) || \ ++ defined(__NetBSD__) || \ ++ defined(__OpenBSD__) ++#define ERESTART EINTR ++#endif ++ + uint32 + vmw_ioctl_context_create(struct vmw_winsys_screen *vws) + { Property changes on: graphics/libGL/files/patch-src_gallium_winsys_svga_drm_vmw-screen-ioctl.c ___________________________________________________________________ Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: graphics/libGL/files/patch-src_glx_Makefile.in =================================================================== --- graphics/libGL/files/patch-src_glx_Makefile.in (revision 0) +++ graphics/libGL/files/patch-src_glx_Makefile.in (working copy) @@ -0,0 +1,59 @@ +--- src/glx/Makefile.in.orig 2013-07-03 15:13:37.000000000 +0200 ++++ src/glx/Makefile.in 2013-07-03 15:19:44.000000000 +0200 +@@ -162,12 +162,12 @@ + depcomp = $(SHELL) $(top_srcdir)/bin/depcomp + am__depfiles_maybe = depfiles + am__mv = mv -f +-COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ +- $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) ++COMPILE = $(CC) $(DEFS) $(AM_CFLAGS) $(DEFAULT_INCLUDES) $(INCLUDES) \ ++ $(AM_CPPFLAGS) $(CPPFLAGS) $(CFLAGS) + LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ +- $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ +- $(AM_CFLAGS) $(CFLAGS) ++ $(AM_CFLAGS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ ++ $(CPPFLAGS) $(CFLAGS) + AM_V_CC = $(am__v_CC_@AM_V@) + am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) + am__v_CC_0 = @echo " CC " $@; +@@ -632,17 +632,17 @@ + $(am__aclocal_m4_deps): + install-libLTLIBRARIES: $(lib_LTLIBRARIES) + @$(NORMAL_INSTALL) +- @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ ++ @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)/.libGL" || list=; \ + list2=; for p in $$list; do \ + if test -f $$p; then \ + list2="$$list2 $$p"; \ + else :; fi; \ + done; \ + test -z "$$list2" || { \ +- echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \ +- $(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \ +- echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \ +- $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \ ++ echo " $(MKDIR_P) '$(DESTDIR)$(libdir)/.libGL'"; \ ++ $(MKDIR_P) "$(DESTDIR)$(libdir)/.libGL" || exit 1; \ ++ echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)/.libGL'"; \ ++ $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)/.libGL"; \ + } + + uninstall-libLTLIBRARIES: +@@ -1068,8 +1068,14 @@ + # a while by putting a link to the driver into /lib of the build tree. + all-local: lib@GL_LIB@.la + $(MKDIR_P) $(top_builddir)/$(LIB_DIR); +- ln -f .libs/lib@GL_LIB@.so.1.2.0 $(top_builddir)/$(LIB_DIR)/lib@GL_LIB@.so.1 +- ln -sf lib@GL_LIB@.so.1 $(top_builddir)/$(LIB_DIR)/lib@GL_LIB@.so ++ base=$(basename $<); \ ++ dlname=$$(grep dlname= .libs/$< | cut -d "'" -f 2); \ ++ ver=$$(grep current= .libs/$< | cut -d "=" -f 2); \ ++ ln -f .libs/$$dlname $(top_builddir)/$(LIB_DIR)/$$dlname; \ ++ if [ ! -f $(top_builddir)/$(LIB_DIR)/$$base.so.$$ver ]; then \ ++ ln -sf $$dlname $(top_builddir)/$(LIB_DIR)/$$base.so.$$ver; \ ++ fi; \ ++ ln -sf $$base.so.$$ver $(top_builddir)/$(LIB_DIR)/$$base.so + + # Tell versions [3.59,3.63) of GNU make to not export all variables. + # Otherwise a system limit (for SysV at least) may be exceeded. Property changes on: graphics/libGL/files/patch-src_glx_Makefile.in ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: graphics/libGL/files/patch-src_mapi_es2api_Makefile.in =================================================================== --- graphics/libGL/files/patch-src_mapi_es2api_Makefile.in (revision 0) +++ graphics/libGL/files/patch-src_mapi_es2api_Makefile.in (working copy) @@ -0,0 +1,20 @@ +--- src/mapi/es2api/Makefile.in.orig 2013-08-01 23:22:21.000000000 +0200 ++++ src/mapi/es2api/Makefile.in 2013-09-01 11:38:01.000000000 +0200 +@@ -958,9 +958,14 @@ + # a while by putting a link to the driver into /lib of the build tree. + all-local: libGLESv2.la + $(MKDIR_P) $(top_builddir)/$(LIB_DIR); +- ln -f .libs/libGLESv2.so $(top_builddir)/$(LIB_DIR)/libGLESv2.so +- ln -f .libs/libGLESv2.so.2 $(top_builddir)/$(LIB_DIR)/libGLESv2.so.2 +- ln -f .libs/libGLESv2.so.2.0.0 $(top_builddir)/$(LIB_DIR)/libGLESv2.so.2.0.0 ++ base=$(basename $<); \ ++ dlname=$$(grep dlname= .libs/$< | cut -d "'" -f 2); \ ++ ver=$$(grep current= .libs/$< | cut -d "=" -f 2); \ ++ ln -f .libs/$$dlname $(top_builddir)/$(LIB_DIR)/$$dlname; \ ++ if [ ! -f $(top_builddir)/$(LIB_DIR)/$$base.so.$$ver ]; then \ ++ ln -sf $$dlname $(top_builddir)/$(LIB_DIR)/$$base.so.$$ver; \ ++ fi; \ ++ ln -sf $$base.so.$$ver $(top_builddir)/$(LIB_DIR)/$$base.so + + # Tell versions [3.59,3.63) of GNU make to not export all variables. + # Otherwise a system limit (for SysV at least) may be exceeded. Property changes on: graphics/libGL/files/patch-src_mapi_es2api_Makefile.in ___________________________________________________________________ Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: graphics/libGL/files/patch-src_mapi_glapi_gen_gl-gentable.py =================================================================== --- graphics/libGL/files/patch-src_mapi_glapi_gen_gl-gentable.py (revision 0) +++ graphics/libGL/files/patch-src_mapi_glapi_gen_gl-gentable.py (working copy) @@ -0,0 +1,11 @@ +--- src/mapi/glapi/gen/gl_gentable.py.orig 2013-07-17 15:41:13.000000000 +0200 ++++ src/mapi/glapi/gen/gl_gentable.py 2013-07-17 15:41:55.000000000 +0200 +@@ -42,7 +42,7 @@ + #endif + + #if (defined(GLXEXT) && defined(HAVE_BACKTRACE)) \\ +- || (!defined(GLXEXT) && defined(DEBUG) && !defined(_WIN32_WCE) && !defined(__CYGWIN__)) ++ || (!defined(GLXEXT) && defined(DEBUG) && !defined(_WIN32_WCE) && !defined(__CYGWIN__) && !defined(__OpenBSD__) && !defined(__FreeBSD__)) + #define USE_BACKTRACE + #endif + Property changes on: graphics/libGL/files/patch-src_mapi_glapi_gen_gl-gentable.py ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: graphics/libGL/files/patch-src_mapi_shared-glapi_Makefile.in =================================================================== --- graphics/libGL/files/patch-src_mapi_shared-glapi_Makefile.in (revision 0) +++ graphics/libGL/files/patch-src_mapi_shared-glapi_Makefile.in (working copy) @@ -0,0 +1,20 @@ +--- src/mapi/shared-glapi/Makefile.in.orig 2013-06-27 00:42:45.000000000 +0200 ++++ src/mapi/shared-glapi/Makefile.in 2013-06-27 00:43:25.000000000 +0200 +@@ -889,9 +889,14 @@ + + all-local: libglapi.la + $(MKDIR_P) $(top_builddir)/$(LIB_DIR) +- ln -f .libs/libglapi.so.0.0.0 $(top_builddir)/$(LIB_DIR)/libglapi.so.0.0.0 +- ln -sf libglapi.so.0.0.0 $(top_builddir)/$(LIB_DIR)/libglapi.so.0 +- ln -sf libglapi.so.0 $(top_builddir)/$(LIB_DIR)/libglapi.so ++ base=$(basename $<); \ ++ dlname=$$(grep dlname= .libs/$< | cut -d "'" -f 2); \ ++ ver=$$(grep current= .libs/$< | cut -d "=" -f 2); \ ++ ln -f .libs/$$dlname $(top_builddir)/$(LIB_DIR)/$$dlname; \ ++ if [ ! -f $(top_builddir)/$(LIB_DIR)/$$base.so.$$ver ]; then \ ++ ln -sf $$dlname $(top_builddir)/$(LIB_DIR)/$$base.so.$$ver; \ ++ fi; \ ++ ln -sf $$base.so.$$ver $(top_builddir)/$(LIB_DIR)/$$base.so + + # Tell versions [3.59,3.63) of GNU make to not export all variables. + # Otherwise a system limit (for SysV at least) may be exceeded. Property changes on: graphics/libGL/files/patch-src_mapi_shared-glapi_Makefile.in ___________________________________________________________________ Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: graphics/libGL/files/patch-src_mesa_Makefile =================================================================== --- graphics/libGL/files/patch-src_mesa_Makefile (revision 328562) +++ graphics/libGL/files/patch-src_mesa_Makefile (working copy) @@ -1,15 +0,0 @@ ---- src/mesa/Makefile.orig 2012-04-22 18:34:50.000000000 +0200 -+++ src/mesa/Makefile 2012-04-22 18:35:00.000000000 +0200 -@@ -183,10 +183,10 @@ - $(DESTDIR)$(INSTALL_INC_DIR)/GL - - install-libgl: default gl.pc install-headers -- $(INSTALL) -d $(DESTDIR)$(INSTALL_LIB_DIR) -+ $(INSTALL) -d $(DESTDIR)$(INSTALL_LIB_DIR)/.libGL - $(INSTALL) -d $(DESTDIR)$(INSTALL_LIB_DIR)/pkgconfig - $(MINSTALL) $(TOP)/$(LIB_DIR)/$(GL_LIB_GLOB) \ -- $(DESTDIR)$(INSTALL_LIB_DIR) -+ $(DESTDIR)$(INSTALL_LIB_DIR)/.libGL - $(INSTALL) -m 644 gl.pc $(DESTDIR)$(INSTALL_LIB_DIR)/pkgconfig - - install-osmesa: default osmesa.pc Index: graphics/libGL/files/patch-src_mesa_drivers_dri_common_Makefile.in =================================================================== --- graphics/libGL/files/patch-src_mesa_drivers_dri_common_Makefile.in (revision 0) +++ graphics/libGL/files/patch-src_mesa_drivers_dri_common_Makefile.in (working copy) @@ -0,0 +1,17 @@ +--- src/mesa/drivers/dri/common/Makefile.in.orig 2013-04-20 14:50:15.000000000 +0000 ++++ src/mesa/drivers/dri/common/Makefile.in 2013-04-20 15:02:05.000000000 +0000 +@@ -123,11 +123,11 @@ + am__depfiles_maybe = depfiles + am__mv = mv -f + COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ +- $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) ++ $(AM_CFLAGS) $(CPPFLAGS) $(CFLAGS) + LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ +- $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ +- $(AM_CFLAGS) $(CFLAGS) ++ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(AM_CFLAGS) $(CPPFLAGS) \ ++ $(CFLAGS) + AM_V_CC = $(am__v_CC_@AM_V@) + am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) + am__v_CC_0 = @echo " CC " $@; Property changes on: graphics/libGL/files/patch-src_mesa_drivers_dri_common_Makefile.in ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: graphics/libGL/files/patch-src_mesa_drivers_dri_common_xmlpool_Makefile.in =================================================================== --- graphics/libGL/files/patch-src_mesa_drivers_dri_common_xmlpool_Makefile.in (revision 0) +++ graphics/libGL/files/patch-src_mesa_drivers_dri_common_xmlpool_Makefile.in (working copy) @@ -0,0 +1,11 @@ +--- src/mesa/drivers/dri/common/xmlpool/Makefile.in.orig 2013-07-02 22:42:09.000000000 +0200 ++++ src/mesa/drivers/dri/common/xmlpool/Makefile.in 2013-07-02 22:53:30.000000000 +0200 +@@ -639,7 +639,7 @@ + # Update .mo files from the corresponding .po files. + %/LC_MESSAGES/options.mo: %.po + @mo="$@"; \ +- lang=$${mo%%/*}; \ ++ lang=$*; \ + echo "Updating ($$lang) $@ from $?."; \ + mkdir -p $$lang/LC_MESSAGES; \ + msgfmt -o $@ $? Property changes on: graphics/libGL/files/patch-src_mesa_drivers_dri_common_xmlpool_Makefile.in ___________________________________________________________________ Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: graphics/libGL/files/patch-src_mesa_libdricore_Makefile.in =================================================================== --- graphics/libGL/files/patch-src_mesa_libdricore_Makefile.in (revision 0) +++ graphics/libGL/files/patch-src_mesa_libdricore_Makefile.in (working copy) @@ -0,0 +1,19 @@ +--- src/mesa/libdricore/Makefile.in.orig 2013-06-27 00:21:26.000000000 +0200 ++++ src/mesa/libdricore/Makefile.in 2013-06-27 00:28:29.000000000 +0200 +@@ -3950,8 +4000,14 @@ + # a while by putting a link to the driver into /lib of the build tree. + @HAVE_DRI_TRUE@all-local: libdricore@VERSION@.la + @HAVE_DRI_TRUE@ $(MKDIR_P) $(top_builddir)/$(LIB_DIR); +-@HAVE_DRI_TRUE@ ln -f .libs/libdricore@VERSION@.so.1.0.0 $(top_builddir)/$(LIB_DIR)/libdricore@VERSION@.so.1; +-@HAVE_DRI_TRUE@ ln -sf libdricore@VERSION@.so.1 $(top_builddir)/$(LIB_DIR)/libdricore@VERSION@.so ++@HAVE_DRI_TRUE@ base=$(basename $<); \ ++@HAVE_DRI_TRUE@ dlname=$$(grep dlname= .libs/$< | cut -d "'" -f 2); \ ++@HAVE_DRI_TRUE@ ver=$$(grep current= .libs/$< | cut -d "=" -f 2); \ ++@HAVE_DRI_TRUE@ ln -f .libs/$$dlname $(top_builddir)/$(LIB_DIR)/$$dlname; \ ++@HAVE_DRI_TRUE@ if [ ! -f $(top_builddir)/$(LIB_DIR)/$$base.so.$$ver ]; then \ ++@HAVE_DRI_TRUE@ ln -sf $$dlname $(top_builddir)/$(LIB_DIR)/$$base.so.$$ver; \ ++@HAVE_DRI_TRUE@ fi; \ ++@HAVE_DRI_TRUE@ ln -sf $$base.so.$$ver $(top_builddir)/$(LIB_DIR)/$$base.so + + -include $(DEPENDS) + Property changes on: graphics/libGL/files/patch-src_mesa_libdricore_Makefile.in ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: graphics/libGL/files/patch-src_mesa_main_compiler.h =================================================================== --- graphics/libGL/files/patch-src_mesa_main_compiler.h (revision 0) +++ graphics/libGL/files/patch-src_mesa_main_compiler.h (working copy) @@ -0,0 +1,12 @@ +--- src/mesa/main/compiler.h.orig 2013-04-06 04:01:09.000000000 +0200 ++++ src/mesa/main/compiler.h 2013-06-26 23:26:02.000000000 +0200 +@@ -171,6 +171,9 @@ + #if defined(__linux__) + #include + #define CPU_TO_LE32( x ) bswap_32( x ) ++#elif defined(__FreeBSD__) ++#include ++#define CPU_TO_LE32( x ) bswap32( x ) + #elif defined(__APPLE__) + #include + #define CPU_TO_LE32( x ) CFSwapInt32HostToLittle( x ) Property changes on: graphics/libGL/files/patch-src_mesa_main_compiler.h ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: graphics/libGL/files-old/patch-configure =================================================================== --- graphics/libGL/files-old/patch-configure (revision 0) +++ graphics/libGL/files-old/patch-configure (working copy) @@ -0,0 +1,43 @@ +--- configure.orig 2009-12-22 03:31:30.000000000 +0100 ++++ configure 2012-06-27 19:49:26.000000000 +0200 +@@ -6946,12 +6946,35 @@ + CXXFLAGS="$CXXFLAGS -ansi -pedantic" + fi + +- # ffb and gamma are missing because they have not been converted +- # to use the new interface. +- if test "x$DRI_DIRS" = "xyes"; then +- DRI_DIRS="i810 i915 i965 mach64 mga r128 r200 r300 r600 radeon tdfx \ ++ case "$host_cpu" in ++ x86_64) ++ # i810 is missing because there is no x86-64 system where it ++ # could *ever* be used. ++ if test "x$DRI_DIRS" = "xyes"; then ++ DRI_DIRS="i915 i965 mach64 mga r128 r200 r300 r600 radeon tdfx \ + unichrome savage sis swrast" +- fi ++ fi ++ ;; ++ i*86) ++ if test "x$DRI_DIRS" = "xyes"; then ++ DRI_DIRS="i810 i915 i965 mach64 mga r128 r200 r300 r600 radeon tdfx \ ++ unichrome savage sis swrast" ++ fi ++ ;; ++ powerpc*) ++ # Build only the drivers for cards that exist on PowerPC. ++ # At some point MGA will be added, but not yet. ++ if test "x$DRI_DIRS" = "xyes"; then ++ DRI_DIRS="mach64 r128 r200 r300 r600 radeon tdfx swrast" ++ fi ++ ;; ++ sparc*) ++ # Build only the drivers for cards that exist on SPARC. ++ if test "x$DRI_DIRS" = "xyes"; then ++ DRI_DIRS="mach64 r128 r200 r300 r600 radeon swrast" ++ fi ++ ;; ++ esac + ;; + gnu*) + DEFINES="$DEFINES -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER" Property changes on: graphics/libGL/files-old/patch-configure ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: graphics/libGL/files-old/patch-mach64_context.h =================================================================== --- graphics/libGL/files-old/patch-mach64_context.h (revision 0) +++ graphics/libGL/files-old/patch-mach64_context.h (working copy) @@ -0,0 +1,20 @@ +--- src/mesa/drivers/dri/mach64/mach64_context.h.orig 2012-06-27 19:59:32.000000000 +0200 ++++ src/mesa/drivers/dri/mach64/mach64_context.h 2012-06-27 20:08:30.000000000 +0200 +@@ -294,11 +294,14 @@ + #define LE32_OUT( x, y ) do { *(GLuint *)(x) = (y); } while (0) + #define LE32_OUT_FLOAT( x, y ) do { *(GLfloat *)(x) = (y); } while (0) + #else +-#ifndef __OpenBSD__ +-#include +-#else ++#if defined(__OpenBSD__) + #include + #define bswap_32 bswap32 ++#elif defined(__FreeBSD__) ++#include ++#define bswap_32 bswap32 ++#else ++#include + #endif + + #define LE32_IN( x ) bswap_32( *(GLuint *)(x) ) Property changes on: graphics/libGL/files-old/patch-mach64_context.h ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: graphics/libGL/files-old/patch-src__mesa__x86-64__glapi_x86-64.S =================================================================== --- graphics/libGL/files-old/patch-src__mesa__x86-64__glapi_x86-64.S (revision 0) +++ graphics/libGL/files-old/patch-src__mesa__x86-64__glapi_x86-64.S (working copy) @@ -0,0 +1,12 @@ +--- ./src/mesa/x86-64/glapi_x86-64.S.orig 2009-03-13 04:28:49.000000000 +0100 ++++ ./src/mesa/x86-64/glapi_x86-64.S 2011-01-28 18:12:18.000000000 +0100 +@@ -73,7 +73,8 @@ _x86_64_get_dispatch: + + .p2align 4,,15 + _x86_64_get_dispatch: +- movq _gl_DispatchTSD(%rip), %rdi ++ movq _gl_DispatchTSD@GOTPCREL(%rip), %rax ++ movl (%rax), %edi + jmp pthread_getspecific@PLT + + #elif defined(THREADS) Property changes on: graphics/libGL/files-old/patch-src__mesa__x86-64__glapi_x86-64.S ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Index: graphics/libGL/files-old/patch-src__mesa__x86-64__xform4.S =================================================================== --- graphics/libGL/files-old/patch-src__mesa__x86-64__xform4.S (revision 0) +++ graphics/libGL/files-old/patch-src__mesa__x86-64__xform4.S (working copy) @@ -0,0 +1,74 @@ +--- src/mesa/x86-64/xform4.S.orig 2009-01-22 18:38:35.000000000 +0100 ++++ src/mesa/x86-64/xform4.S 2011-05-09 21:26:00.000000000 +0200 +@@ -53,7 +53,7 @@ _mesa_x86_64_transform_points4_general: + * rdx = source + */ + movl V4F_COUNT(%rdx), %ecx /* count */ +- movzx V4F_STRIDE(%rdx), %eax /* stride */ ++ movzbl V4F_STRIDE(%rdx), %eax /* stride */ + + movl %ecx, V4F_COUNT(%rdi) /* set dest count */ + movl $4, V4F_SIZE(%rdi) /* set dest size */ +@@ -116,7 +116,7 @@ p4_constants: + .byte 0x00, 0x00, 0x00, 0x00 + .byte 0x00, 0x00, 0x00, 0x00 + .byte 0x00, 0x00, 0x00, 0x00 +-.float 0f+1.0 ++.float 1.0 + + .text + .align 16 +@@ -135,7 +135,7 @@ _mesa_x86_64_transform_points4_3d: + movaps 16(%rax), %xmm10 + + movl V4F_COUNT(%rdx), %ecx /* count */ +- movzx V4F_STRIDE(%rdx), %eax /* stride */ ++ movzbl V4F_STRIDE(%rdx), %eax /* stride */ + + movl %ecx, V4F_COUNT(%rdi) /* set dest count */ + movl $4, V4F_SIZE(%rdi) /* set dest size */ +@@ -195,7 +195,7 @@ p4_3d_done: + _mesa_x86_64_transform_points4_identity: + + movl V4F_COUNT(%rdx), %ecx /* count */ +- movzx V4F_STRIDE(%rdx), %eax /* stride */ ++ movzbl V4F_STRIDE(%rdx), %eax /* stride */ + + movl %ecx, V4F_COUNT(%rdi) /* set dest count */ + movl $4, V4F_SIZE(%rdi) /* set dest size */ +@@ -223,7 +223,7 @@ p4_identity_done: + _mesa_3dnow_transform_points4_3d_no_rot: + + movl V4F_COUNT(%rdx), %ecx /* count */ +- movzx V4F_STRIDE(%rdx), %eax /* stride */ ++ movzbl V4F_STRIDE(%rdx), %eax /* stride */ + + movl %ecx, V4F_COUNT(%rdi) /* set dest count */ + movl $4, V4F_SIZE(%rdi) /* set dest size */ +@@ -287,7 +287,7 @@ p4_3d_no_rot_done: + _mesa_3dnow_transform_points4_perspective: + + movl V4F_COUNT(%rdx), %ecx /* count */ +- movzx V4F_STRIDE(%rdx), %eax /* stride */ ++ movzbl V4F_STRIDE(%rdx), %eax /* stride */ + + movl %ecx, V4F_COUNT(%rdi) /* set dest count */ + movl $4, V4F_SIZE(%rdi) /* set dest size */ +@@ -353,7 +353,7 @@ p4_perspective_done: + _mesa_3dnow_transform_points4_2d_no_rot: + + movl V4F_COUNT(%rdx), %ecx /* count */ +- movzx V4F_STRIDE(%rdx), %eax /* stride */ ++ movzbl V4F_STRIDE(%rdx), %eax /* stride */ + + movl %ecx, V4F_COUNT(%rdi) /* set dest count */ + movl $4, V4F_SIZE(%rdi) /* set dest size */ +@@ -408,7 +408,7 @@ p4_2d_no_rot_done: + _mesa_3dnow_transform_points4_2d: + + movl V4F_COUNT(%rdx), %ecx /* count */ +- movzx V4F_STRIDE(%rdx), %eax /* stride */ ++ movzbl V4F_STRIDE(%rdx), %eax /* stride */ + + movl %ecx, V4F_COUNT(%rdi) /* set dest count */ + movl $4, V4F_SIZE(%rdi) /* set dest size */ Property changes on: graphics/libGL/files-old/patch-src__mesa__x86-64__xform4.S ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Index: graphics/libGL/files-old/patch-src__mesa__x86__glapi_x86.S =================================================================== --- graphics/libGL/files-old/patch-src__mesa__x86__glapi_x86.S (revision 0) +++ graphics/libGL/files-old/patch-src__mesa__x86__glapi_x86.S (working copy) @@ -0,0 +1,11 @@ +--- ./src/mesa/x86/glapi_x86.S.orig 2009-03-13 04:28:49.000000000 +0100 ++++ ./src/mesa/x86/glapi_x86.S 2011-01-28 18:11:56.000000000 +0100 +@@ -47,7 +47,7 @@ + #define GL_OFFSET(x) CODEPTR(REGOFF(4 * x, EAX)) + + #if defined(GNU_ASSEMBLER) && !defined(__DJGPP__) && !defined(__MINGW32__) +-#define GLOBL_FN(x) GLOBL x ; .type x, function ++#define GLOBL_FN(x) GLOBL x ; .type x, @function + #else + #define GLOBL_FN(x) GLOBL x + #endif Property changes on: graphics/libGL/files-old/patch-src__mesa__x86__glapi_x86.S ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Index: graphics/libGL/files-old/patch-src__mesa__x86__read_rgba_span_x86.S =================================================================== --- graphics/libGL/files-old/patch-src__mesa__x86__read_rgba_span_x86.S (revision 0) +++ graphics/libGL/files-old/patch-src__mesa__x86__read_rgba_span_x86.S (working copy) @@ -0,0 +1,11 @@ +--- ./src/mesa/x86/read_rgba_span_x86.S.orig 2008-08-25 16:46:47.000000000 +0200 ++++ ./src/mesa/x86/read_rgba_span_x86.S 2011-01-28 18:10:06.000000000 +0100 +@@ -648,7 +648,7 @@ _generic_read_RGBA_span_RGB565_MMX: + testl $0x01, %ecx + je .L01 + +- movzxw (%eax), %ecx ++ movzwl (%eax), %ecx + movd %ecx, %mm4 + + pshufw $0x00, %mm4, %mm0 Property changes on: graphics/libGL/files-old/patch-src__mesa__x86__read_rgba_span_x86.S ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Index: graphics/libGL/files-old/patch-src_glx_x11_XF86dri.c =================================================================== --- graphics/libGL/files-old/patch-src_glx_x11_XF86dri.c (revision 0) +++ graphics/libGL/files-old/patch-src_glx_x11_XF86dri.c (working copy) @@ -0,0 +1,38 @@ +--- src/glx/x11/XF86dri.c.orig 2009-06-17 18:35:16.000000000 +0000 ++++ src/glx/x11/XF86dri.c 2013-05-29 10:09:37.000000000 +0000 +@@ -43,6 +43,7 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN + #include + #include + #include "xf86dristr.h" ++#include + + + #if defined(__GNUC__) && (__GNUC__ * 100 + __GNUC_MINOR__) >= 303 +@@ -212,7 +213,11 @@ XF86DRIOpenConnection(Display * dpy, int + } + + if (rep.length) { +- if (!(*busIdString = (char *) Xcalloc(rep.busIdStringLength + 1, 1))) { ++ if (rep.busIdStringLength < INT_MAX) ++ *busIdString = Xcalloc(rep.busIdStringLength + 1, 1); ++ else ++ *busIdString = NULL; ++ if (*busIdString == NULL) { + _XEatData(dpy, ((rep.busIdStringLength + 3) & ~3)); + UnlockDisplay(dpy); + SyncHandle(); +@@ -311,9 +316,11 @@ XF86DRIGetClientDriverName(Display * dpy + *ddxDriverPatchVersion = rep.ddxDriverPatchVersion; + + if (rep.length) { +- if (! +- (*clientDriverName = +- (char *) Xcalloc(rep.clientDriverNameLength + 1, 1))) { ++ if (rep.clientDriverNameLength < INT_MAX) ++ *clientDriverName = Xcalloc(rep.clientDriverNameLength + 1, 1); ++ else ++ *clientDriverName = NULL; ++ if (*clientDriverName == NULL) { + _XEatData(dpy, ((rep.clientDriverNameLength + 3) & ~3)); + UnlockDisplay(dpy); + SyncHandle(); Property changes on: graphics/libGL/files-old/patch-src_glx_x11_XF86dri.c ___________________________________________________________________ Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Added: fbsd:nokeywords ## -0,0 +1 ## +on \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: graphics/libGL/files-old/patch-src_mesa_Makefile =================================================================== --- graphics/libGL/files-old/patch-src_mesa_Makefile (revision 0) +++ graphics/libGL/files-old/patch-src_mesa_Makefile (working copy) @@ -0,0 +1,15 @@ +--- src/mesa/Makefile.orig 2009-12-22 03:31:19.000000000 +0100 ++++ src/mesa/Makefile 2013-08-19 23:19:42.000000000 +0200 +@@ -127,10 +127,10 @@ + $(DESTDIR)$(INSTALL_INC_DIR)/GL + + install-libgl: default gl.pc install-headers +- $(INSTALL) -d $(DESTDIR)$(INSTALL_LIB_DIR) ++ $(INSTALL) -d $(DESTDIR)$(INSTALL_LIB_DIR)/.libGL + $(INSTALL) -d $(DESTDIR)$(INSTALL_LIB_DIR)/pkgconfig + $(MINSTALL) $(TOP)/$(LIB_DIR)/$(GL_LIB_GLOB) \ +- $(DESTDIR)$(INSTALL_LIB_DIR) ++ $(DESTDIR)$(INSTALL_LIB_DIR)/.libGL + $(INSTALL) -m 644 gl.pc $(DESTDIR)$(INSTALL_LIB_DIR)/pkgconfig + + install-osmesa: default osmesa.pc Property changes on: graphics/libGL/files-old/patch-src_mesa_Makefile ___________________________________________________________________ Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: graphics/libGL/pkg-plist =================================================================== --- graphics/libGL/pkg-plist (revision 328562) +++ graphics/libGL/pkg-plist (working copy) @@ -11,9 +11,10 @@ %%OLD%%include/GL/mglmesa.h include/GL/osmesa.h %%OLD%%include/GL/svgamesa.h -include/GL/vms_x_fix.h +%%OLD%%include/GL/vms_x_fix.h include/GL/wglext.h include/GL/wmesa.h +%%NEW%%lib/.libGL/libGL.la lib/.libGL/libGL.so lib/.libGL/libGL.so.1 libdata/pkgconfig/gl.pc Index: graphics/libGLw/Makefile =================================================================== --- graphics/libGLw/Makefile (revision 328562) +++ graphics/libGLw/Makefile (working copy) @@ -12,9 +12,10 @@ COMMENT= OpenGL widgets library USE_BZIP2= yes -USES= pathfix pkgconfig motif +USES= pathfix pkgconfig USE_LDCONFIG= yes USE_GL= gl +USE_MOTIF= yes USE_XORG= x11 xt xext GNU_CONFIGURE= yes CONFIGURE_ARGS= --disable-static --enable-motif Index: graphics/libdrm/Makefile =================================================================== --- graphics/libdrm/Makefile (revision 328562) +++ graphics/libdrm/Makefile (working copy) @@ -10,8 +10,8 @@ MAINTAINER= x11@FreeBSD.org COMMENT= Userspace interface to kernel Direct Rendering Module services -LIB_DEPENDS= pciaccess:${PORTSDIR}/devel/libpciaccess \ - pthread-stubs:${PORTSDIR}/devel/libpthread-stubs +LIB_DEPENDS= libpciaccess.so:${PORTSDIR}/devel/libpciaccess \ + libpthread-stubs.so:${PORTSDIR}/devel/libpthread-stubs USES= pkgconfig USE_BZIP2= yes @@ -19,15 +19,8 @@ USE_LDCONFIG= yes NO_STAGE= yes +OPTIONS_DEFINE= MANPAGES -.if defined(WITH_NEW_XORG) - -USES+= gmake - -OPTIONS_DEFINE= KMS MANPAGES -OPTIONS_DEFAULT=KMS -KMS_DESC= Enable KMS support - .if defined(PACKAGE_BUILDING) OPTIONS_DEFAULT+= MANPAGES .endif @@ -34,12 +27,18 @@ .include -.if ${PORT_OPTIONS:MKMS} +.if defined(WITH_NEW_XORG) + +USES+= gmake + +# KMS support in the kernel is only build on these archs, disable others +.if ${ARCH} == "amd64" || ${ARCH} == "i386" CONFIGURE_ARGS+=--enable-libkms EXTRA_PATCHES+= ${FILESDIR}/extra-xf86drmMode.c -PLIST_SUB+= KMS="" +PLIST_SUB+= KMS="" NOUVEAU="" .else -PLIST_SUB+= KMS="@comment " +CONFIGURE_ARGS+=--disable-libkms +PLIST_SUB+= KMS="@comment " NOUVEAU="@comment " .endif .if ${PORT_OPTIONS:MMANPAGES} @@ -70,11 +69,9 @@ CONFIGURE_ARGS= --enable-nouveau-experimental-api LIBDRM_VERSION= 2.4.17 LIBDRM_REVISION=1 -PLIST_SUB+= OLD="" NEW="@comment " +PLIST_SUB+= OLD="" NEW="@comment " NOUVEAU="" .endif -.include - .if ${ARCH} == "amd64" || ${ARCH} == "i386" || ${ARCH} == "ia64" || ${ARCH} == "powerpc" PLIST_SUB+= INTEL_DRIVER="" PLIST_SUB+= RADEON_DRIVERS="" @@ -88,4 +85,4 @@ s,i?86|x86_64),i?86|amd64|x86_64),g' \ ${WRKSRC}/configure -.include +.include Index: graphics/libdrm/pkg-plist =================================================================== --- graphics/libdrm/pkg-plist (revision 328562) +++ graphics/libdrm/pkg-plist (working copy) @@ -22,8 +22,9 @@ %%NEW%%%%INTEL_DRIVER%%include/libdrm/intel_debug.h %%NEW%%include/libdrm/mach64_drm.h %%NEW%%include/libdrm/mga_drm.h -%%NEW%%include/libdrm/nouveau.h +%%NEW%%%%NOUVEAU%%include/libdrm/nouveau.h %%NEW%%include/libdrm/nouveau_drm.h +%%NEW%%include/libdrm/qxl_drm.h %%NEW%%include/libdrm/r128_drm.h %%NEW%%%%RADEON_DRIVERS%%include/libdrm/r600_pci_ids.h %%NEW%%%%RADEON_DRIVERS%%include/libdrm/radeon_bo.h @@ -54,10 +55,10 @@ %%INTEL_DRIVER%%lib/libdrm_intel.la %%INTEL_DRIVER%%lib/libdrm_intel.so %%INTEL_DRIVER%%lib/libdrm_intel.so.1 -lib/libdrm_nouveau.la -lib/libdrm_nouveau.so -%%OLD%%lib/libdrm_nouveau.so.1 -%%NEW%%lib/libdrm_nouveau.so.2 +%%NOUVEAU%%lib/libdrm_nouveau.la +%%NOUVEAU%%lib/libdrm_nouveau.so +%%OLD%%%%NOUVEAU%%lib/libdrm_nouveau.so.1 +%%NEW%%%%NOUVEAU%%lib/libdrm_nouveau.so.2 %%NEW%%%%RADEON_DRIVERS%%lib/libdrm_radeon.la %%NEW%%%%RADEON_DRIVERS%%lib/libdrm_radeon.so %%NEW%%%%RADEON_DRIVERS%%lib/libdrm_radeon.so.1 @@ -66,7 +67,7 @@ %%NEW%%%%KMS%%lib/libkms.so.1 libdata/pkgconfig/libdrm.pc %%INTEL_DRIVER%%libdata/pkgconfig/libdrm_intel.pc -libdata/pkgconfig/libdrm_nouveau.pc +%%NOUVEAU%%libdata/pkgconfig/libdrm_nouveau.pc %%NEW%%%%RADEON_DRIVERS%%libdata/pkgconfig/libdrm_radeon.pc %%NEW%%%%KMS%%libdata/pkgconfig/libkms.pc %%OLD%%@dirrm include/nouveau Index: graphics/libglesv2/Makefile =================================================================== --- graphics/libglesv2/Makefile (revision 0) +++ graphics/libglesv2/Makefile (working copy) @@ -0,0 +1,29 @@ +# Created by: kwm@FreeBSD.org +# $FreeBSD$ + +PORTNAME= libglesv2 +PORTVERSION= ${MESAVERSION} +CATEGORIES= graphics + +COMMENT= OpenGL ES v2 library + +LIB_DEPENDS+= libdrm.so:${PORTSDIR}/graphics/libdrm \ + libexpat.so:${PORTSDIR}/textproc/expat2 + +.if ! defined(WITH_NEW_XORG) +IGNORE= Please enable WITH_NEW_XORG, libglesv2 needs libdrm higher then 2.4.24 +.endif + +# stuff not needed by libEGL but configure wants it +USE_XORG+= glproto dri2proto xext xdamage xfixes + + +BUILD_WKRSRC= ${WRKSRC}/src/mapi/es2api +INSTALL_WRKSRC= ${WRKSRC}/src/mapi/es2api + +# this library doesn't exist in Mesa 7.6 so use newer +WITH_NEW_XORG=yes + +.include +.include "${.CURDIR}/../../graphics/libGL/bsd.mesalib.mk" +.include Property changes on: graphics/libglesv2/Makefile ___________________________________________________________________ Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +FreeBSD=%H \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: graphics/libglesv2/pkg-descr =================================================================== --- graphics/libglesv2/pkg-descr (revision 0) +++ graphics/libglesv2/pkg-descr (working copy) @@ -0,0 +1,3 @@ +This package contains the GL ES v2 utility library. + +WWW: http://www.freedesktop.org/Software/xorg Property changes on: graphics/libglesv2/pkg-descr ___________________________________________________________________ Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: graphics/libglesv2/pkg-plist =================================================================== --- graphics/libglesv2/pkg-plist (revision 0) +++ graphics/libglesv2/pkg-plist (working copy) @@ -0,0 +1,12 @@ +include/GLES2/gl2.h +include/GLES2/gl2ext.h +include/GLES2/gl2platform.h +include/GLES3/gl3.h +include/GLES3/gl3ext.h +include/GLES3/gl3platform.h +lib/libGLESv2.la +lib/libGLESv2.so +lib/libGLESv2.so.2 +libdata/pkgconfig/glesv2.pc +@dirrmtry include/GLES3 +@dirrmtry include/GLES2 Property changes on: graphics/libglesv2/pkg-plist ___________________________________________________________________ Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: graphics/libreatlas/Makefile =================================================================== --- graphics/libreatlas/Makefile (revision 328562) +++ graphics/libreatlas/Makefile (working copy) @@ -30,8 +30,7 @@ fontconfig:${PORTSDIR}/x11-fonts/fontconfig GNU_CONFIGURE= yes -USES= pkgconfig gettext iconv -USE_GMAKE= yes +USES= pkgconfig gettext gmake iconv USE_XORG= ice pixman sm x11 xau xcb xcomposite xcursor xdamage xdmcp xext \ xfixes xi xinerama xrandr xrender xxf86vm USE_GNOME= atk gdkpixbuf2 glib20 gtk20 pango Index: multimedia/freetuxtv/Makefile =================================================================== --- multimedia/freetuxtv/Makefile (revision 328562) +++ multimedia/freetuxtv/Makefile (working copy) @@ -3,7 +3,7 @@ PORTNAME= freetuxtv PORTVERSION= 0.6.5 -PORTREVISION= 4 +PORTREVISION= 5 CATEGORIES= multimedia MASTER_SITES= GOOGLE_CODE @@ -26,13 +26,12 @@ expat:${PORTSDIR}/textproc/expat2 \ fontconfig:${PORTSDIR}/x11-fonts/fontconfig -USES= iconv pathfix pkgconfig +USES= gmake iconv pathfix pkgconfig USE_GNOME= glib20 gtk20 USE_XORG= pixman x11 xau xcb xcomposite xcursor xdamage xdmcp xext xfixes \ xi xinerama xrandr xrender GNU_CONFIGURE= yes CONFIGURE_ARGS+=--with-gtk=2.0 -USE_GMAKE= yes CFLAGS= -Wno-return-type INSTALLS_ICONS= yes Index: net/cvsup/Makefile =================================================================== --- net/cvsup/Makefile (revision 328562) +++ net/cvsup/Makefile (working copy) @@ -3,7 +3,7 @@ PORTNAME= cvsup PORTVERSION= 16.1h -PORTREVISION= 4 +PORTREVISION= 5 CATEGORIES= net devel MASTER_SITES= ${MASTER_SITE_FREEBSD_ORG} MASTER_SITE_SUBDIR=development/CVSup/snapshots Index: net/tigervnc/Makefile =================================================================== --- net/tigervnc/Makefile (revision 328562) +++ net/tigervnc/Makefile (working copy) @@ -3,6 +3,7 @@ PORTNAME= tigervnc PORTVERSION= 1.3.0 +PORTREVISION= 1 CATEGORIES= net x11-servers MASTER_SITES= SF:tigervnc MASTER_SITE_SUBDIR= ${PORTNAME}/${PORTNAME}/${PORTVERSION}/:tigervnc Index: print/photoprint/Makefile =================================================================== --- print/photoprint/Makefile (revision 328562) +++ print/photoprint/Makefile (working copy) @@ -2,6 +2,7 @@ PORTNAME= photoprint DISTVERSION= 0.4.2-pre2 +PORTREVISION= 1 CATEGORIES= print graphics MASTER_SITES= http://www.blackfiveimaging.co.uk/photoprint/ @@ -17,7 +18,6 @@ liblcms.so:${PORTSDIR}/graphics/lcms \ libnetpbm.so:${PORTSDIR}/graphics/netpbm \ libpcre.so:${PORTSDIR}/devel/pcre \ - libpixman-1.so:${PORTSDIR}/x11/pixman \ libpng15.so:${PORTSDIR}/graphics/png \ libpthread-stubs.so:${PORTSDIR}/devel/libpthread-stubs \ libtiff.so:${PORTSDIR}/graphics/tiff @@ -25,7 +25,7 @@ GNU_CONFIGURE= yes USES= desktop-file-utils gettext pkgconfig USE_GNOME= pango -USE_XORG= x11 xau xcb xcomposite xcursor xdamage xdmcp xext \ +USE_XORG= pixman x11 xau xcb xcomposite xcursor xdamage xdmcp xext \ xfixes xi xinerama xrandr xrender INSTALLS_ICONS= yes Index: sysutils/gtk-imonc/Makefile =================================================================== --- sysutils/gtk-imonc/Makefile (revision 328562) +++ sysutils/gtk-imonc/Makefile (working copy) @@ -3,7 +3,7 @@ PORTNAME= gtk-imonc PORTVERSION= 0.6.4.1 -PORTREVISION= 12 +PORTREVISION= 13 CATEGORIES= sysutils MASTER_SITES= http://stefan-strigler.de/download/ Index: sysutils/nitrogen/Makefile =================================================================== --- sysutils/nitrogen/Makefile (revision 328562) +++ sysutils/nitrogen/Makefile (working copy) @@ -3,7 +3,7 @@ PORTNAME= nitrogen PORTVERSION= 1.5.2 -PORTREVISION= 2 +PORTREVISION= 3 CATEGORIES= sysutils MASTER_SITES= http://projects.l3ib.org/nitrogen/files/ Index: x11/libSM/Makefile =================================================================== --- x11/libSM/Makefile (revision 328562) +++ x11/libSM/Makefile (working copy) @@ -2,7 +2,7 @@ # $FreeBSD$ PORTNAME= libSM -PORTVERSION= 1.2.1 +PORTVERSION= 1.2.2 PORTEPOCH= 1 CATEGORIES= x11 Index: x11/libSM/distinfo =================================================================== --- x11/libSM/distinfo (revision 328562) +++ x11/libSM/distinfo (working copy) @@ -1,2 +1,2 @@ -SHA256 (xorg/lib/libSM-1.2.1.tar.bz2) = 93c11d569c64f40723b93b44af1efb474a0cfe92573b0c8c330343cabb897f1d -SIZE (xorg/lib/libSM-1.2.1.tar.bz2) = 334696 +SHA256 (xorg/lib/libSM-1.2.2.tar.bz2) = 0baca8c9f5d934450a70896c4ad38d06475521255ca63b717a6510fdb6e287bd +SIZE (xorg/lib/libSM-1.2.2.tar.bz2) = 348908 Index: x11/libX11/Makefile =================================================================== --- x11/libX11/Makefile (revision 328562) +++ x11/libX11/Makefile (working copy) @@ -2,7 +2,7 @@ # $FreeBSD$ PORTNAME= libX11 -PORTVERSION= 1.6.1 +PORTVERSION= 1.6.2 PORTEPOCH= 1 CATEGORIES= x11 Index: x11/libX11/distinfo =================================================================== --- x11/libX11/distinfo (revision 328562) +++ x11/libX11/distinfo (working copy) @@ -1,2 +1,2 @@ -SHA256 (xorg/lib/libX11-1.6.1.tar.bz2) = 10a54fc16b58b4f5a5eed4d080c357a82fd2f42d09af625c1f5df50650701892 -SIZE (xorg/lib/libX11-1.6.1.tar.bz2) = 2356196 +SHA256 (xorg/lib/libX11-1.6.2.tar.bz2) = 2aa027e837231d2eeea90f3a4afe19948a6eb4c8b2bec0241eba7dbc8106bd16 +SIZE (xorg/lib/libX11-1.6.2.tar.bz2) = 2339981 Index: x11/libX11/pkg-plist =================================================================== --- x11/libX11/pkg-plist (revision 328562) +++ x11/libX11/pkg-plist (working copy) @@ -103,6 +103,9 @@ lib/X11/locale/ja_JP.UTF-8/Compose lib/X11/locale/ja_JP.UTF-8/XI18N_OBJS lib/X11/locale/ja_JP.UTF-8/XLC_LOCALE +lib/X11/locale/km_KH.UTF-8/Compose +lib/X11/locale/km_KH.UTF-8/XI18N_OBJS +lib/X11/locale/km_KH.UTF-8/XLC_LOCALE lib/X11/locale/ko/Compose lib/X11/locale/ko/XI18N_OBJS lib/X11/locale/ko/XLC_LOCALE @@ -141,6 +144,9 @@ lib/X11/locale/ru_RU.UTF-8/Compose lib/X11/locale/ru_RU.UTF-8/XI18N_OBJS lib/X11/locale/ru_RU.UTF-8/XLC_LOCALE +lib/X11/locale/sr_CS.UTF-8/Compose +lib/X11/locale/sr_CS.UTF-8/XI18N_OBJS +lib/X11/locale/sr_CS.UTF-8/XLC_LOCALE lib/X11/locale/tatar-cyr/Compose lib/X11/locale/tatar-cyr/XI18N_OBJS lib/X11/locale/tatar-cyr/XLC_LOCALE @@ -215,6 +221,7 @@ @dirrm lib/X11/locale/th_TH.UTF-8 @dirrm lib/X11/locale/th_TH @dirrm lib/X11/locale/tatar-cyr +@dirrm lib/X11/locale/sr_CS.UTF-8 @dirrm lib/X11/locale/ru_RU.UTF-8 @dirrm lib/X11/locale/pt_BR.UTF-8 @dirrm lib/X11/locale/nokhchi-1 @@ -227,6 +234,7 @@ @dirrm lib/X11/locale/koi8-c @dirrm lib/X11/locale/ko_KR.UTF-8 @dirrm lib/X11/locale/ko +@dirrm lib/X11/locale/km_KH.UTF-8 @dirrm lib/X11/locale/ja_JP.UTF-8 @dirrm lib/X11/locale/ja.SJIS @dirrm lib/X11/locale/ja.JIS Index: x11/libXpm/Makefile =================================================================== --- x11/libXpm/Makefile (revision 328562) +++ x11/libXpm/Makefile (working copy) @@ -2,7 +2,7 @@ # $FreeBSD$ PORTNAME= libXpm -PORTVERSION= 3.5.10 +PORTVERSION= 3.5.11 CATEGORIES= x11 MAINTAINER= x11@FreeBSD.org Index: x11/libXpm/distinfo =================================================================== --- x11/libXpm/distinfo (revision 328562) +++ x11/libXpm/distinfo (working copy) @@ -1,2 +1,2 @@ -SHA256 (xorg/lib/libXpm-3.5.10.tar.bz2) = a6db7e234750e7d60330017972e31d8e1f29f0a8c1391e4ac82f6102d919a735 -SIZE (xorg/lib/libXpm-3.5.10.tar.bz2) = 431310 +SHA256 (xorg/lib/libXpm-3.5.11.tar.bz2) = c5bdafa51d1ae30086fac01ab83be8d47fe117b238d3437f8e965434090e041c +SIZE (xorg/lib/libXpm-3.5.11.tar.bz2) = 443496 Index: x11/libXrandr/Makefile =================================================================== --- x11/libXrandr/Makefile (revision 328562) +++ x11/libXrandr/Makefile (working copy) @@ -2,7 +2,7 @@ # $FreeBSD$ PORTNAME= libXrandr -PORTVERSION= 1.4.1 +PORTVERSION= 1.4.2 CATEGORIES= x11 MAINTAINER= x11@FreeBSD.org Index: x11/libXrandr/distinfo =================================================================== --- x11/libXrandr/distinfo (revision 328562) +++ x11/libXrandr/distinfo (working copy) @@ -1,2 +1,2 @@ -SHA256 (xorg/lib/libXrandr-1.4.1.tar.bz2) = d914a0490fd0a2ea6c3194505b5b28c56e2a277d8f4648b0275ee0ee370fb905 -SIZE (xorg/lib/libXrandr-1.4.1.tar.bz2) = 312857 +SHA256 (xorg/lib/libXrandr-1.4.2.tar.bz2) = caa7b31ac769be51a532343c65376f1d4df3f307afaed58e34fb5e82e8b825ad +SIZE (xorg/lib/libXrandr-1.4.2.tar.bz2) = 315165 Index: x11/libXv/Makefile =================================================================== --- x11/libXv/Makefile (revision 328562) +++ x11/libXv/Makefile (working copy) @@ -2,7 +2,7 @@ # $FreeBSD$ PORTNAME= libXv -PORTVERSION= 1.0.9 +PORTVERSION= 1.0.10 PORTEPOCH= 1 CATEGORIES= x11 Index: x11/libXv/distinfo =================================================================== --- x11/libXv/distinfo (revision 328562) +++ x11/libXv/distinfo (working copy) @@ -1,2 +1,2 @@ -SHA256 (xorg/lib/libXv-1.0.9.tar.bz2) = a874dbf864d0271bbe795af67ef5b3f20096c92fc11eacbf0d2af00e32bc5b4b -SIZE (xorg/lib/libXv-1.0.9.tar.bz2) = 309744 +SHA256 (xorg/lib/libXv-1.0.10.tar.bz2) = 55fe92f8686ce8612e2c1bfaf58c057715534419da700bda8d517b1d97914525 +SIZE (xorg/lib/libXv-1.0.10.tar.bz2) = 300633 Index: x11/libxcb/Makefile =================================================================== --- x11/libxcb/Makefile (revision 328562) +++ x11/libxcb/Makefile (working copy) @@ -20,9 +20,8 @@ CONFIGURE_ARGS+= --disable-build-docs --without-doxygen --enable-xinput USE_BZIP2= yes -USES= pathfix pkgconfig +USES= gmake pathfix pkgconfig USE_GNOME= libxslt:build -USE_GMAKE= yes USE_LDCONFIG= yes USE_XORG= xau xdmcp USE_PYTHON_BUILD= 2.5+ Index: x11/pixman/Makefile =================================================================== --- x11/pixman/Makefile (revision 328562) +++ x11/pixman/Makefile (working copy) @@ -1,7 +1,7 @@ # $FreeBSD$ PORTNAME= pixman -PORTVERSION= 0.30.0 +PORTVERSION= 0.30.2 CATEGORIES= x11 MAINTAINER= x11@FreeBSD.org @@ -8,10 +8,9 @@ COMMENT= Low-level pixel manipulation library USES= perl5 +USE_PERL5= build XORG_CAT= lib USE_AUTOTOOLS= libtool -USE_PERL5= build -USE_GNOME= ltverhack:9 CONFIGURE_ARGS= --disable-gtk OPTIONS_DEFINE= SIMD Index: x11/pixman/distinfo =================================================================== --- x11/pixman/distinfo (revision 328562) +++ x11/pixman/distinfo (working copy) @@ -1,2 +1,2 @@ -SHA256 (xorg/lib/pixman-0.30.0.tar.bz2) = 77e756dc7fafdf17f39a4f23bdc8be59f9f6a65c08704f5cac1d8aa87cfaf517 -SIZE (xorg/lib/pixman-0.30.0.tar.bz2) = 681343 +SHA256 (xorg/lib/pixman-0.30.2.tar.bz2) = 4fbb51788fe7cbd8abb5f80aed95ec878704e57a06328f7bebe0306e3822c96c +SIZE (xorg/lib/pixman-0.30.2.tar.bz2) = 666281 Index: x11/pixman/pkg-plist =================================================================== --- x11/pixman/pkg-plist (revision 328562) +++ x11/pixman/pkg-plist (working copy) @@ -3,6 +3,6 @@ lib/libpixman-1.a lib/libpixman-1.la lib/libpixman-1.so -lib/libpixman-1.so.9 +lib/libpixman-1.so.30 libdata/pkgconfig/pixman-1.pc @dirrm include/pixman-1 Index: x11/xinput/Makefile =================================================================== --- x11/xinput/Makefile (revision 328562) +++ x11/xinput/Makefile (working copy) @@ -2,7 +2,7 @@ # $FreeBSD$ PORTNAME= xinput -PORTVERSION= 1.6.0 +PORTVERSION= 1.6.1 CATEGORIES= x11 MAINTAINER= x11@FreeBSD.org Index: x11/xinput/distinfo =================================================================== --- x11/xinput/distinfo (revision 328562) +++ x11/xinput/distinfo (working copy) @@ -1,2 +1,2 @@ -SHA256 (xorg/app/xinput-1.6.0.tar.bz2) = 4ab007d952c76665603bcb82ceb15fd3929d10faf0580fc4873ac16f5f63847e -SIZE (xorg/app/xinput-1.6.0.tar.bz2) = 146209 +SHA256 (xorg/app/xinput-1.6.1.tar.bz2) = b7632d0f228a8a6be93b09857ea413940fcf44091e60f4a0fe9f5fd82efd871f +SIZE (xorg/app/xinput-1.6.1.tar.bz2) = 152587 Index: x11/xkeyboard-config/Makefile =================================================================== --- x11/xkeyboard-config/Makefile (revision 328562) +++ x11/xkeyboard-config/Makefile (working copy) @@ -14,9 +14,8 @@ XORG_CAT= data USE_BZIP2= yes -USE_GMAKE= yes USE_GNOME= intlhack libxslt:build -USES= pathfix perl5 +USES= gmake pathfix perl5 USE_PERL5= build GNU_CONFIGURE= yes MAKE_JOBS_UNSAFE=yes Index: x11/xorg-cf-files/Makefile =================================================================== --- x11/xorg-cf-files/Makefile (revision 328562) +++ x11/xorg-cf-files/Makefile (working copy) @@ -3,6 +3,7 @@ PORTNAME= xorg-cf-files PORTVERSION= 1.0.5 +PORTREVISION= 1 CATEGORIES= x11 MAINTAINER= x11@FreeBSD.org Index: x11/xtrans/Makefile =================================================================== --- x11/xtrans/Makefile (revision 328562) +++ x11/xtrans/Makefile (working copy) @@ -8,8 +8,6 @@ MAINTAINER= x11@FreeBSD.org COMMENT= Abstract network code for X -CONFLICTS= libXtrans - LICENSE= MIT XORG_CAT= lib Index: x11-drivers/xf86-input-mouse/files/patch-src-bsd_mouse.c =================================================================== --- x11-drivers/xf86-input-mouse/files/patch-src-bsd_mouse.c (revision 328562) +++ x11-drivers/xf86-input-mouse/files/patch-src-bsd_mouse.c (working copy) @@ -1,13 +1,65 @@ ---- src/bsd_mouse.c.orig 2012-07-27 08:10:56.000000000 +0200 -+++ src/bsd_mouse.c 2012-07-30 00:49:09.000000000 +0200 -@@ -71,15 +71,20 @@ - static const char *FindDevice(InputInfoPtr, const char *, int); +--- src/bsd_mouse.c.orig 2012-10-08 03:40:07.000000000 +0200 ++++ src/bsd_mouse.c 2013-07-03 01:00:50.897361950 +0200 +@@ -26,6 +26,24 @@ + * authorization from the copyright holder(s) and author(s). + */ - #if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__DragonFly__) ++ ++/* ++ * XXX - Should this be autoconf'd instead? ++ */ ++#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__DragonFly__) ++ ++#if !defined(USBMOUSE_SUPPORT) ++#define USBMOUSE_SUPPORT ++#endif ++#if !defined(HAS_LIB_USB_HID) ++#define HAS_LIB_USB_HID ++#endif +#if !defined(XPS2_SUPPORT) +#define XPS2_SUPPORT +#endif - /* These are for FreeBSD and DragonFly */ ++ ++#endif /* defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__DragonFly__) */ ++ + #include + + #include +@@ -33,9 +51,23 @@ + #include "xf86Priv.h" + #include "xf86_OSlib.h" + #include "xf86Xinput.h" ++#include + #include "mouse.h" + #include "xisb.h" + #include "mipointer.h" ++#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 3 ++#define HAVE_PROPERTIES 1 ++#endif ++#ifdef HAVE_PROPERTIES ++#include ++#include ++/* 1.6 has properties, but no labels */ ++#ifdef AXIS_LABEL_PROP ++#define HAVE_LABELS ++#else ++#undef HAVE_LABELS ++#endif ++#endif + #ifdef WSCONS_SUPPORT + #include + #endif +@@ -47,9 +79,6 @@ + #endif + + #include +-#ifdef USB_GET_REPORT_ID +-#define USB_NEW_HID +-#endif + + #define HUP_GENERIC_DESKTOP 0x0001 + #define HUP_BUTTON 0x0009 +@@ -75,11 +104,13 @@ #define DEFAULT_MOUSE_DEV "/dev/mouse" #define DEFAULT_SYSMOUSE_DEV "/dev/sysmouse" #define DEFAULT_PS2_DEV "/dev/psm0" @@ -21,7 +73,7 @@ NULL }; #elif (defined(__OpenBSD__) || defined(__NetBSD__)) && defined(WSCONS_SUPPORT) -@@ -100,7 +105,11 @@ +@@ -100,7 +131,11 @@ #if defined(__NetBSD__) return MSE_SERIAL | MSE_BUS | MSE_PS2 | MSE_AUTO; #elif defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__DragonFly__) @@ -34,7 +86,7 @@ #else return MSE_SERIAL | MSE_BUS | MSE_PS2 | MSE_XPS2 | MSE_AUTO | MSE_MISC; #endif -@@ -180,9 +189,30 @@ +@@ -180,9 +215,30 @@ { MOUSE_PROTO_SYSMOUSE, "SysMouse" } }; @@ -41,7 +93,7 @@ +#ifdef XPS2_SUPPORT +static struct { + int dmodel; -+ char *name; ++ const char *name; +} ps2proto[] = { + { MOUSE_MODEL_NETSCROLL, "NetScrollPS/2" }, + { MOUSE_MODEL_NET, "NetMousePS/2" }, @@ -59,13 +111,13 @@ SetupAuto(InputInfoPtr pInfo, int *protoPara) { +#ifdef XPS2_SUPPORT -+ char *dev; ++ const char *dev; +#endif + const char *proto; int i; mousehw_t hw; mousemode_t mode; -@@ -190,7 +220,13 @@ +@@ -190,7 +246,13 @@ if (pInfo->fd == -1) return NULL; @@ -79,7 +131,7 @@ i = 1; ioctl(pInfo->fd, MOUSE_SETLEVEL, &i); -@@ -209,9 +245,18 @@ +@@ -209,9 +271,18 @@ protoPara[0] = mode.syncmask[0]; protoPara[1] = mode.syncmask[1]; } @@ -100,7 +152,7 @@ } } } -@@ -234,41 +279,41 @@ +@@ -234,41 +305,41 @@ (protocol && xf86NameCmp(protocol, "SysMouse") == 0)) { /* * As the FreeBSD sysmouse driver defaults to protocol level 0 @@ -159,7 +211,7 @@ } return FALSE; } -@@ -276,17 +321,17 @@ +@@ -276,17 +347,17 @@ static const char * FindDevice(InputInfoPtr pInfo, const char *protocol, int flags) { @@ -181,7 +233,7 @@ #endif } else { /* -@@ -295,28 +340,32 @@ +@@ -295,28 +366,32 @@ * the test for whether /dev/sysmouse is usable can be made. */ if (!strcmp(*pdev, DEFAULT_MOUSE_DEV)) { @@ -227,7 +279,749 @@ break; } } -@@ -764,7 +813,9 @@ +@@ -468,30 +543,78 @@ + + #if defined(USBMOUSE_SUPPORT) + ++#define MAXRIDS 64 ++#define MAXACOLS 8 ++#define MAXLCOLS 16 + typedef struct _UsbMseRec { + int packetSize; +- int iid; +- hid_item_t loc_x; /* x locator item */ +- hid_item_t loc_y; /* y locator item */ +- hid_item_t loc_z; /* z (wheel) locator item */ +- hid_item_t loc_w; /* z (wheel) locator item */ +- hid_item_t loc_btn[MSE_MAXBUTTONS]; /* buttons locator items */ +- unsigned char *buffer; ++ int iid, nrids, nacols, opened; ++ struct { ++ int32_t rid; ++ int size; ++ } rids[MAXRIDS]; ++ struct UsbMseAcol { ++ InputInfoPtr pInfo; ++ int nlcols, nbuttons, hasZ, hasW; ++ int xmin, xmax, ymin, ymax, pmin, pmax, px, py; ++ int cxmin, cxmax, cymin, cymax, cpmin, cpmax; ++ struct UsbMseLcol { ++ hid_item_t loc_x; /* x locator item */ ++ hid_item_t loc_y; /* y locator item */ ++ hid_item_t loc_z; /* z (wheel) locator item */ ++ hid_item_t loc_w; /* w (hwheel) locator item */ ++ hid_item_t loc_p; /* Tip Pressure */ ++ hid_item_t loc_valid; /* Touch Valid */ ++ hid_item_t loc_in_range; /* In Range */ ++ hid_item_t loc_btn[MSE_MAXBUTTONS]; /* buttons locator items */ ++ } lcols[MAXLCOLS]; ++ hid_item_t loc_cc; /* contact count */ ++ } acols[MAXACOLS]; ++ unsigned char *buffer; + } UsbMseRec, *UsbMsePtr; + ++static int * ++usbGetReportSizePtr(UsbMsePtr pUsbMse, int32_t rid) ++{ ++ int i; ++ ++ for (i = 0; i < pUsbMse->nrids; i++) { ++ if (pUsbMse->rids[i].rid == rid) ++ return (&pUsbMse->rids[i].size); ++ } ++ for (i = 0; i < MAXRIDS; i++) { ++ if (pUsbMse->rids[i].size == 0) { ++ pUsbMse->rids[i].rid = rid; ++ pUsbMse->nrids = max(pUsbMse->nrids, i + 1); ++ return (&pUsbMse->rids[i].size); ++ } ++ } ++ return (NULL); ++} ++ + static int + usbMouseProc(DeviceIntPtr pPointer, int what) + { + InputInfoPtr pInfo; + MouseDevPtr pMse; + UsbMsePtr pUsbMse; ++ struct UsbMseAcol *acol; + unsigned char map[MSE_MAXBUTTONS + 1]; +- int nbuttons; ++ int nacol, nbuttons; ++#ifdef HAVE_LABELS ++ Atom btn_labels[MSE_MAXBUTTONS] = {0}; ++ Atom axes_labels[3] = { 0, 0, 0 }; ++#endif + + pInfo = pPointer->public.devicePrivate; + pMse = pInfo->private; + pMse->device = pPointer; + pUsbMse = pMse->mousePriv; ++ for (nacol = 0; nacol < (pUsbMse->nacols - 1); nacol++) { ++ if (pUsbMse->acols[nacol].pInfo == pInfo) ++ break; ++ } ++ acol = &pUsbMse->acols[nacol]; + + switch (what) { + case DEVICE_INIT: +@@ -500,38 +623,96 @@ + for (nbuttons = 0; nbuttons < MSE_MAXBUTTONS; ++nbuttons) + map[nbuttons + 1] = nbuttons + 1; + +- InitPointerDeviceStruct((DevicePtr)pPointer, +- map, +- min(pMse->buttons, MSE_MAXBUTTONS), +- miPointerGetMotionEvents, +- pMse->Ctrl, +- miPointerGetMotionBufferSize()); ++#ifdef HAVE_LABELS ++ btn_labels[0] = XIGetKnownProperty(BTN_LABEL_PROP_BTN_LEFT); ++ btn_labels[1] = XIGetKnownProperty(BTN_LABEL_PROP_BTN_MIDDLE); ++ btn_labels[2] = XIGetKnownProperty(BTN_LABEL_PROP_BTN_RIGHT); ++ axes_labels[0] = XIGetKnownProperty((acol->xmin != acol->xmax) ++ ? AXIS_LABEL_PROP_ABS_X : AXIS_LABEL_PROP_REL_X); ++ axes_labels[1] = XIGetKnownProperty((acol->xmin != acol->xmax) ++ ? AXIS_LABEL_PROP_ABS_Y : AXIS_LABEL_PROP_REL_Y); ++ axes_labels[2] = XIGetKnownProperty(AXIS_LABEL_PROP_ABS_PRESSURE); ++#endif ++ ++ InitButtonClassDeviceStruct(pPointer, min(pMse->buttons, MSE_MAXBUTTONS), ++#ifdef HAVE_LABELS ++ btn_labels, ++#endif ++ map); ++ InitValuatorClassDeviceStruct(pPointer, (acol->pmin != acol->pmax) ? 3 : 2, ++#ifdef HAVE_LABELS ++ axes_labels, ++#endif ++#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) == 0 ++ miPointerGetMotionEvents, ++#elif GET_ABI_MAJOR(ABI_XINPUT_VERSION) < 3 ++ GetMotionHistory, ++#endif ++ GetMotionHistorySize(), ++ (acol->xmin != acol->xmax || acol->ymin != acol->ymax) ? ++ Absolute : Relative); ++ InitPtrFeedbackClassDeviceStruct(pPointer, pMse->Ctrl); + + /* X valuator */ +- xf86InitValuatorAxisStruct(pPointer, 0, 0, -1, 1, 0, 1); ++ xf86InitValuatorAxisStruct(pPointer, 0, ++#ifdef HAVE_LABELS ++ axes_labels[0], ++#endif ++ (acol->xmin != acol->xmax) ? acol->xmin : -1, ++ (acol->xmin != acol->xmax) ? acol->xmax : -1, ++ 1, 0, 1 ++#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 12 ++ , (acol->xmin != acol->xmax) ? Absolute : Relative ++#endif ++ ); + xf86InitValuatorDefaults(pPointer, 0); + /* Y valuator */ +- xf86InitValuatorAxisStruct(pPointer, 1, 0, -1, 1, 0, 1); ++ xf86InitValuatorAxisStruct(pPointer, 1, ++#ifdef HAVE_LABELS ++ axes_labels[1], ++#endif ++ (acol->ymin != acol->ymax) ? acol->ymin : -1, ++ (acol->ymin != acol->ymax) ? acol->ymax : -1, ++ 1, 0, 1 ++#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 12 ++ , (acol->ymin != acol->ymax) ? Absolute : Relative ++#endif ++ ); + xf86InitValuatorDefaults(pPointer, 1); ++ /* Pressure valuator */ ++ if (acol->pmin != acol->pmax) { ++ xf86InitValuatorAxisStruct(pPointer, 2, ++#ifdef HAVE_LABELS ++ axes_labels[2], ++#endif ++ acol->pmin, acol->pmax, 1, 0, 1 ++#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 12 ++ , Absolute ++#endif ++ ); ++ xf86InitValuatorDefaults(pPointer, 2); ++ } + xf86MotionHistoryAllocate(pInfo); + break; + + case DEVICE_ON: +- pInfo->fd = xf86OpenSerial(pInfo->options); +- if (pInfo->fd == -1) +- xf86Msg(X_WARNING, "%s: cannot open input device\n", pInfo->name); +- else { +- pMse->buffer = XisbNew(pInfo->fd, pUsbMse->packetSize); +- if (!pMse->buffer) { +- free(pMse); +- xf86CloseSerial(pInfo->fd); +- pInfo->fd = -1; +- } else { +- xf86FlushInput(pInfo->fd); +- if (!xf86InstallSIGIOHandler (pInfo->fd, usbSigioReadInput, +- pInfo)) +- AddEnabledDevice(pInfo->fd); +- } ++ if (pUsbMse->opened++ == 0) { ++ pInfo->fd = xf86OpenSerial(pInfo->options); ++ if (pInfo->fd == -1) ++ xf86Msg(X_WARNING, "%s: cannot open input device\n", pInfo->name); ++ else { ++ pMse->buffer = XisbNew(pInfo->fd, pUsbMse->packetSize); ++ if (!pMse->buffer) { ++ free(pMse); ++ xf86CloseSerial(pInfo->fd); ++ pInfo->fd = -1; ++ } else { ++ xf86FlushInput(pInfo->fd); ++ if (!xf86InstallSIGIOHandler (pInfo->fd, usbSigioReadInput, ++ pInfo)) ++ AddEnabledDevice(pInfo->fd); ++ } ++ } + } + pMse->lastButtons = 0; + pMse->lastMappedButtons = 0; +@@ -553,6 +734,7 @@ + xf86CloseSerial(pInfo->fd); + pInfo->fd = -1; + } ++ pUsbMse->opened--; + pPointer->public.on = FALSE; + usleep(300000); + break; +@@ -568,45 +750,154 @@ + { + MouseDevPtr pMse; + UsbMsePtr pUsbMse; +- int buttons = pMse->lastButtons; +- int dx = 0, dy = 0, dz = 0, dw = 0; +- int n, c; ++ int buttons, cc; ++ int dx, dy, dz, dw, dp, upd, v, nx, ny, np, in_range; ++ int n, c, rid, *sizep, nacol, nlcol; + unsigned char *pBuf; ++ struct UsbMseAcol *acol; ++ struct UsbMseLcol *lcol; + + pMse = pInfo->private; + pUsbMse = pMse->mousePriv; + + XisbBlockDuration(pMse->buffer, -1); ++next: + pBuf = pUsbMse->buffer; + n = 0; +- while ((c = XisbRead(pMse->buffer)) >= 0 && n < pUsbMse->packetSize) { ++ if (pUsbMse->iid) { ++ rid = XisbRead(pMse->buffer); ++ if (rid < 0) ++ return; ++ pBuf[n++] = (unsigned char)rid; ++ } else ++ rid = 0; ++ sizep = usbGetReportSizePtr(pUsbMse, rid); ++ if (sizep == NULL || *sizep == 0) { ++ xf86Msg(X_WARNING, "%s: unknown report ID %d\n", pInfo->name, rid); ++ goto next; ++ } ++ while (n < *sizep && (c = XisbRead(pMse->buffer)) >= 0) { + pBuf[n++] = (unsigned char)c; + } + if (n == 0) + return; +- if (n != pUsbMse->packetSize) { ++// xf86MsgVerb(X_INFO, 3, "pkt: %d %02x %02x %02x %02x %02x %02x %02x %02x %02x %02x\n", ++// n, pBuf[0], pBuf[1], pBuf[2], pBuf[3], pBuf[4], pBuf[5], pBuf[6], pBuf[7], pBuf[8], pBuf[9]); ++ if (n != *sizep) { + LogMessageVerbSigSafe(X_WARNING, -1, + "%s: incomplete packet, size %d\n", + pInfo->name, n); + } +- /* discard packets with an id that don't match the mouse */ +- /* XXX this is probably not the right thing */ +- if (pUsbMse->iid != 0) { +- if (*pBuf++ != pUsbMse->iid) +- return; +- } +- dx = hid_get_data(pBuf, &pUsbMse->loc_x); +- dy = hid_get_data(pBuf, &pUsbMse->loc_y); +- dz = hid_get_data(pBuf, &pUsbMse->loc_z); +- dw = hid_get_data(pBuf, &pUsbMse->loc_w); +- +- buttons = 0; +- for (n = 0; n < pMse->buttons; n++) { +- if (hid_get_data(pBuf, &pUsbMse->loc_btn[n])) +- buttons |= (1 << UMS_BUT(n)); ++ for (nacol = 0; nacol < pUsbMse->nacols; nacol++) { ++ acol = &pUsbMse->acols[nacol]; ++ if (acol->pInfo == NULL) ++ continue; ++ nx = ny = np = upd = 0; ++ buttons = cc = 0; ++ dx = dy = dz = dw = dp = 0; ++ for (nlcol = 0; nlcol < pUsbMse->acols[nacol].nlcols; nlcol++) { ++ lcol = &acol->lcols[nlcol]; ++ ++ if (lcol->loc_valid.usage != 0 && rid == lcol->loc_valid.report_ID && ++ hid_get_data(pBuf, &lcol->loc_valid) == 0) ++ continue; ++ if (lcol->loc_in_range.usage != 0 && rid == lcol->loc_in_range.report_ID) ++ in_range = hid_get_data(pBuf, &lcol->loc_in_range); ++ else ++ in_range = 1; ++ if (in_range && lcol->loc_x.usage != 0 && rid == lcol->loc_x.report_ID && nx == 0) { ++ v = hid_get_data(pBuf, &lcol->loc_x); ++ if (acol->xmin != acol->xmax) { ++ v = xf86ScaleAxis(v, acol->xmax, acol->xmin, ++ lcol->loc_x.logical_maximum, lcol->loc_x.logical_minimum); ++ if (acol->cxmin != acol->cxmax) ++ v = xf86ScaleAxis(v, acol->xmax, acol->xmin, ++ acol->cxmax, acol->cxmin); ++ } ++ dx += v; ++ nx++; ++ } ++ if (in_range && lcol->loc_y.usage != 0 && rid == lcol->loc_y.report_ID && ny == 0) { ++ v = hid_get_data(pBuf, &lcol->loc_y); ++ if (acol->xmin != acol->xmax) { ++ v = xf86ScaleAxis(v, acol->ymax, acol->ymin, ++ lcol->loc_y.logical_maximum, lcol->loc_y.logical_minimum); ++ if (acol->cymin != acol->cymax) ++ v = xf86ScaleAxis(v, acol->ymax, acol->ymin, ++ acol->cymax, acol->cymin); ++ } ++ dy += v; ++ ny++; ++ } ++ if (lcol->loc_z.usage != 0 && rid == lcol->loc_z.report_ID) { ++ dz -= hid_get_data(pBuf, &lcol->loc_z); ++ upd = 1; ++ } ++ if (lcol->loc_w.usage != 0 && rid == lcol->loc_w.report_ID) { ++ dw += hid_get_data(pBuf, &lcol->loc_w); ++ upd = 1; ++ } ++ if (lcol->loc_p.usage != 0 && rid == lcol->loc_p.report_ID && np == 0) { ++ v = hid_get_data(pBuf, &lcol->loc_p); ++ v = xf86ScaleAxis(v, acol->pmax, acol->pmin, ++ lcol->loc_p.logical_maximum, lcol->loc_p.logical_minimum); ++ if (acol->cpmin != acol->cpmax) ++ v = xf86ScaleAxis(v, acol->pmax, acol->pmin, ++ acol->cpmax, acol->cpmin); ++ dp += v; ++ np++; ++ } ++ ++ for (n = 0; n < acol->nbuttons; n++) { ++ if (lcol->loc_btn[n].usage != 0 && rid == lcol->loc_btn[n].report_ID) { ++ if (hid_get_data(pBuf, &lcol->loc_btn[n])) ++ buttons |= (1 << UMS_BUT(n)); ++ upd = 1; ++ } ++ } ++ } ++ if (acol->loc_cc.usage != 0 && rid == acol->loc_cc.report_ID) ++ cc = hid_get_data(pBuf, &acol->loc_cc); ++ else ++ cc = (nx || ny) ? 1 : 0; ++ if (cc > 1) ++ buttons = (1 << UMS_BUT(1)); ++ if (nx != 0 && acol->xmin != acol->xmax) ++ dx /= nx; ++ if (ny != 0 && acol->ymin != acol->ymax) ++ dy /= ny; ++ if (np != 0 && acol->pmin != acol->pmax) ++ dp /= np; ++// if (upd || nx || ny || np) ++// xf86MsgVerb(X_INFO, 3, "%d cc %d dx %d dy %d dz %d dw %d press %d buttons %02x\n", ++// nacol, cc, dx, dy, dz, dw, dp, buttons); ++ if (nx != 0 || ny != 0) { ++ if (acol->pmin != acol->pmax) { ++ xf86PostMotionEvent(acol->pInfo->dev, ++ /* is_absolute: */ TRUE, ++ /* first_valuator: */ 0, ++ /* num_valuators: */ 3, ++ dx, dy, dp); ++ } else if (acol->xmin != acol->xmax || acol->ymin != acol->ymax) { ++ xf86PostMotionEvent(acol->pInfo->dev, ++ /* is_absolute: */ TRUE, ++ /* first_valuator: */ 0, ++ /* num_valuators: */ 2, ++ dx, dy); ++ } ++ } ++ if (upd || (nx != 0) || (ny != 0)) { ++ ((MouseDevPtr)acol->pInfo->private)->PostEvent(acol->pInfo, buttons, ++ ((acol->xmin != acol->xmax) ? dx - acol->px : dx), ++ ((acol->ymin != acol->ymax) ? dy - acol->py : dy), ++ dz, dw); ++ } ++ if (nx > 0) ++ acol->px = dx; ++ if (ny > 0) ++ acol->py = dy; + } +- pMse->PostEvent(pInfo, buttons, dx, dy, dz, dw); +- return; ++ goto next; + } + + static void +@@ -615,14 +906,17 @@ + usbReadInput ((InputInfoPtr) closure); + } + +-/* This function is called when the protocol is "usb". */ + static Bool +-usbPreInit(InputInfoPtr pInfo, const char *protocol, int flags) ++usbInitFirst(InputInfoPtr pInfo) + { + MouseDevPtr pMse = pInfo->private; + UsbMsePtr pUsbMse; + report_desc_t reportDesc; +- int i; ++ hid_data_t d; ++ hid_item_t h; ++ struct UsbMseAcol *acol; ++ struct UsbMseLcol *lcol; ++ int mdepth, rsize, *rsizep, acolused, lcolused, used; + + pUsbMse = malloc(sizeof(UsbMseRec)); + if (pUsbMse == NULL) { +@@ -631,12 +925,7 @@ + return FALSE; + } + +- pMse->protocol = protocol; +- xf86Msg(X_CONFIG, "%s: Protocol: %s\n", pInfo->name, protocol); +- +- /* Collect the options, and process the common options. */ +- COLLECT_INPUT_OPTIONS(pInfo, NULL); +- xf86ProcessCommonOptions(pInfo, pInfo->options); ++ bzero(pUsbMse, sizeof(UsbMseRec)); + + /* Check if the device can be opened. */ + pInfo->fd = xf86OpenSerial(pInfo->options); +@@ -652,19 +941,134 @@ + } + /* Get USB informations */ + reportDesc = hid_get_report_desc(pInfo->fd); +- /* Get packet size & iid */ +-#ifdef USB_NEW_HID +- if (ioctl(pInfo->fd, USB_GET_REPORT_ID, &pUsbMse->iid) == -1) { +- xf86Msg(X_ERROR, "Error ioctl USB_GET_REPORT_ID on %s : %s\n", +- pInfo->name, strerror(errno)); +- return FALSE; +- } +- pUsbMse->packetSize = hid_report_size(reportDesc, hid_input, +- pUsbMse->iid); +-#else +- pUsbMse->packetSize = hid_report_size(reportDesc, hid_input, +- &pUsbMse->iid); +-#endif ++ mdepth = 0; ++ pUsbMse->nacols = 0; ++ acol = &pUsbMse->acols[pUsbMse->nacols]; ++ lcol = &acol->lcols[acol->nlcols]; ++ acolused = 0; ++ lcolused = 0; ++ d = hid_start_parse(reportDesc, (1 << hid_input) | ++ (1 << hid_collection) | (1 << hid_endcollection), -1); ++ while (hid_get_item(d, &h)) { ++ switch (h.kind) { ++ case hid_collection: ++ if (mdepth != 0) ++ mdepth++; ++ else if (h.collection == 1 && ++ (h.usage == 0x00010001 || h.usage == 0x00010002 || ++ (h.usage >= 0x000d0001 && h.usage <= 0x000d000d))) { ++ mdepth++; ++ if (acolused) { ++ if (lcolused) { ++ acol->nlcols++; ++ lcolused = 0; ++ } ++ pUsbMse->nacols++; ++ acolused = 0; ++ acol = &pUsbMse->acols[pUsbMse->nacols]; ++ lcol = &acol->lcols[acol->nlcols]; ++ } ++ } ++ if (lcolused && (h.collection == 0 || ++ h.collection == 2 || h.collection == 3)) { ++ acol->nlcols++; ++ lcolused = 0; ++ lcol = &acol->lcols[acol->nlcols]; ++ } ++ break; ++ case hid_endcollection: ++ if (mdepth != 0) ++ mdepth--; ++ break; ++ case hid_input: ++ if (h.report_ID != 0) ++ pUsbMse->iid = 1; ++ rsize = pUsbMse->iid + ++ (h.pos + (h.report_size * h.report_count) + 7) / 8; ++ if ((rsizep = usbGetReportSizePtr(pUsbMse, h.report_ID)) != NULL) ++ *rsizep = max(*rsizep, rsize); ++ pUsbMse->packetSize = max(pUsbMse->packetSize, rsize); ++ if (mdepth == 0) ++ break; ++ used = 1; ++ if (h.usage == 0x00010030) { /* X */ ++ lcol->loc_x = h; ++ if ((h.flags & 0x04) == 0) { ++ if (acol->xmin == acol->xmax) { ++ acol->xmin = h.logical_minimum; ++ acol->xmax = h.logical_maximum; ++ } else { ++ acol->xmin = min(acol->xmin, h.logical_minimum); ++ acol->xmax = max(acol->xmax, h.logical_maximum); ++ } ++ } ++ } else if (h.usage == 0x00010031) { /* Y */ ++ lcol->loc_y = h; ++ if ((h.flags & 0x04) == 0) { ++ if (acol->ymin == acol->ymax) { ++ acol->ymin = h.logical_minimum; ++ acol->ymax = h.logical_maximum; ++ } else { ++ acol->ymin = min(acol->ymin, h.logical_minimum); ++ acol->ymax = max(acol->ymax, h.logical_maximum); ++ } ++ } ++ } else if (h.usage == 0x00010038) { /* Z */ ++ lcol->loc_z = h; ++ acol->hasZ = 1; ++ } else if (h.usage == 0x000c0238) { /* W */ ++ lcol->loc_w = h; ++ acol->hasW = 1; ++ } else if (h.usage == 0x000d0030) { /* Press */ ++ lcol->loc_p = h; ++ if ((h.flags & 0x04) == 0) { ++ if (acol->pmin == acol->pmax) { ++ acol->pmin = h.logical_minimum; ++ acol->pmax = h.logical_maximum; ++ } else { ++ acol->pmin = min(acol->pmin, h.logical_minimum); ++ acol->pmax = max(acol->pmax, h.logical_maximum); ++ } ++ } ++ } else if (h.usage == 0x000d0032) /* In Range */ ++ lcol->loc_in_range = h; ++ else if (h.usage == 0x000d0047) /* Valid */ ++ lcol->loc_valid = h; ++ else if (h.usage > 0x00090000 && ++ h.usage <= 0x00090000 + MSE_MAXBUTTONS) { /* Buttons */ ++ lcol->loc_btn[(h.usage & 0xffff) - 1] = h; ++ acol->nbuttons = max(acol->nbuttons, h.usage & 0xffff); ++ } else if (h.usage == 0x000d0042) { /* Tip Switch */ ++ lcol->loc_btn[0] = h; ++ acol->nbuttons = max(acol->nbuttons, 1); ++ } else if (h.usage == 0x000d0044) { /* Barrel Switch */ ++ lcol->loc_btn[1] = h; ++ acol->nbuttons = max(acol->nbuttons, 2); ++ } else if (h.usage == 0x000d0045) { /* Eraser */ ++ lcol->loc_btn[3] = h; ++ acol->nbuttons = max(acol->nbuttons, 4); ++ } else if (h.usage == 0x000d0046) { /* Tablet Pick */ ++ lcol->loc_btn[2] = h; ++ acol->nbuttons = max(acol->nbuttons, 3); ++ } else if (h.usage == 0x000d0054) /* Contact Count */ ++ acol->loc_cc = h; ++ else ++ used = 0; ++ lcolused += used; ++ acolused += used; ++ break; ++ default: ++ break; ++ } ++ } ++ if (lcolused) ++ acol->nlcols++; ++ if (acolused) ++ pUsbMse->nacols++; ++ hid_end_parse(d); ++ xf86Msg(X_DEFAULT, "%s: Found %d usable logical collections\n", ++ pInfo->name, pUsbMse->nacols); ++ + /* Allocate buffer */ + if (pUsbMse->packetSize <= 8) { + pUsbMse->buffer = pMse->protoBuf; +@@ -674,56 +1078,129 @@ + if (pUsbMse->buffer == NULL) { + xf86Msg(X_ERROR, "%s: cannot allocate buffer\n", pInfo->name); + free(pUsbMse); +- free(pMse); + xf86CloseSerial(pInfo->fd); + return FALSE; + } +-#ifdef USB_NEW_HID +- if (hid_locate(reportDesc, HID_USAGE2(HUP_GENERIC_DESKTOP, HUG_X), +- hid_input, &pUsbMse->loc_x, pUsbMse->iid) < 0) { +- xf86Msg(X_WARNING, "%s: no x locator\n", pInfo->name); +- } +- if (hid_locate(reportDesc, HID_USAGE2(HUP_GENERIC_DESKTOP, HUG_Y), +- hid_input, &pUsbMse->loc_y, pUsbMse->iid) < 0) { +- xf86Msg(X_WARNING, "%s: no y locator\n", pInfo->name); +- } +- if (hid_locate(reportDesc, HID_USAGE2(HUP_GENERIC_DESKTOP, HUG_WHEEL), +- hid_input, &pUsbMse->loc_z, pUsbMse->iid) < 0) { +- } +-#else +- if (hid_locate(reportDesc, HID_USAGE2(HUP_GENERIC_DESKTOP, HUG_X), +- hid_input, &pUsbMse->loc_x) < 0) { +- xf86Msg(X_WARNING, "%s: no x locator\n", pInfo->name); +- } +- if (hid_locate(reportDesc, HID_USAGE2(HUP_GENERIC_DESKTOP, HUG_Y), +- hid_input, &pUsbMse->loc_y) < 0) { +- xf86Msg(X_WARNING, "%s: no y locator\n", pInfo->name); +- } +- if (hid_locate(reportDesc, HID_USAGE2(HUP_GENERIC_DESKTOP, HUG_WHEEL), +- hid_input, &pUsbMse->loc_z) < 0) { +- } +-#endif +- /* Probe for number of buttons */ +- for (i = 1; i <= MSE_MAXBUTTONS; i++) { +- if (!hid_locate(reportDesc, HID_USAGE2(HUP_BUTTON, i), +- hid_input, &pUsbMse->loc_btn[i-1] +-#ifdef USB_NEW_HID +- , pUsbMse->iid +-#endif +- )) +- break; +- } +- pMse->buttons = i-1; + + xf86CloseSerial(pInfo->fd); + pInfo->fd = -1; + + /* Private structure */ + pMse->mousePriv = pUsbMse; ++ return TRUE; ++} ++ ++/* This function is called when the protocol is "usb". */ ++static Bool ++usbPreInit(InputInfoPtr pInfo, const char *protocol, int flags) ++{ ++ InputInfoPtr pMatch; ++ MouseDevPtr pMse = pInfo->private; ++ UsbMsePtr pUsbMse; ++ struct UsbMseAcol *acol; ++ char *str; ++ int i, colopt; ++ ++ pMse->protocol = protocol; ++ xf86Msg(X_CONFIG, "%s: Protocol: %s\n", pInfo->name, protocol); ++ ++ /* Collect the options, and process the common options. */ ++ COLLECT_INPUT_OPTIONS(pInfo, NULL); ++ xf86ProcessCommonOptions(pInfo, pInfo->options); ++ ++ /* Check if this HID device is already opened. */ ++ for (pMatch = xf86FirstLocalDevice(); pMatch != NULL; pMatch = pMatch->next) { ++ if ((pInfo != pMatch) && strstr(pMatch->drv->driverName, "mouse")) { ++ char *dev1, *dev2; ++ ++ dev1 = xf86SetStrOption(pInfo->options, "Device", NULL); ++ dev2 = xf86SetStrOption(pMatch->options, "Device", NULL); ++ if (strcmp(dev1, dev2) == 0) { ++ free(dev1); ++ free(dev2); ++ break; ++ } ++ free(dev1); ++ free(dev2); ++ } ++ } ++ if (pMatch == NULL) { ++ xf86Msg(X_DEFAULT, "%s: Opening new HID device\n", pInfo->name); ++ if (!usbInitFirst(pInfo)) { ++ free(pMse); ++ return FALSE; ++ } ++ } else { ++ pMse->mousePriv = ((MouseDevPtr)pMatch->private)->mousePriv; ++ xf86Msg(X_DEFAULT, "%s: Attaching to already opened HID device\n", ++ pInfo->name); ++ } ++ pUsbMse = pMse->mousePriv; ++ ++ /* Attach to collection, respecting "Collection" option. */ ++ colopt = xf86SetIntOption(pInfo->options, "Collection", 0); ++ for (i = 0; i < pUsbMse->nacols; i++) { ++ if (pUsbMse->acols[i].pInfo == NULL && ++ (colopt == 0 || i == colopt - 1)) { ++ pUsbMse->acols[i].pInfo = pInfo; ++ break; ++ } ++ } ++ xf86Msg(colopt == 0 ? X_DEFAULT : X_CONFIG, ++ "%s: Collection: %d\n", pInfo->name, ++ i == pUsbMse->nacols ? colopt : i + 1); ++ if (i == pUsbMse->nacols) { ++ xf86Msg(X_ERROR, ++ "%s: Application collection not found or already handled\n", ++ pInfo->name); ++ free(pMse); ++ return FALSE; ++ } ++ ++ acol = &pUsbMse->acols[i]; ++ pMse->buttons = acol->nbuttons; ++ if (pMse->buttons == 2) ++ pMse->buttons = 3; ++ if (acol->xmin != acol->xmax || acol->ymin != acol->ymax) ++ pMse->disableXY = TRUE; ++ pMse->hasZ = acol->hasZ; ++ pMse->hasW = acol->hasW; + + /* Process common mouse options (like Emulate3Buttons, etc). */ + pMse->CommonOptions(pInfo); + ++ /* Process "Calibration" option. */ ++ str = xf86CheckStrOption(pInfo->options, "Calibration", NULL); ++ if (str != NULL && (acol->xmin != acol->xmax || acol->ymin != acol->ymax)) { ++ int j, xmin, xmax, ymin, ymax, pmin, pmax; ++ ++ j = sscanf(str, "%d %d %d %d %d %d", &xmin, &xmax, &ymin, &ymax, &pmin, &pmax); ++ if (j == 4) { ++ xf86Msg(X_CONFIG, "%s: Calibration: %d %d %d %d\n", ++ pInfo->name, xmin, xmax, ymin, ymax); ++ acol->cxmin = xmin; ++ acol->cxmax = xmax; ++ acol->cymin = ymin; ++ acol->cymax = ymax; ++ } else if (j == 6) { ++ xf86Msg(X_CONFIG, "%s: Calibration: %d %d %d %d %d %d\n", ++ pInfo->name, xmin, xmax, ymin, ymax, pmin, pmax); ++ acol->cxmin = xmin; ++ acol->cxmax = xmax; ++ acol->cymin = ymin; ++ acol->cymax = ymax; ++ acol->cpmin = pmin; ++ acol->cpmax = pmax; ++ } else ++ xf86Msg(X_WARNING, "%s: Calibration: Invalid arguments\n", ++ pInfo->name); ++ free(str); ++ } else if (acol->xmin != acol->xmax || acol->ymin != acol->ymax) { ++ xf86Msg(X_DEFAULT, "%s: Calibration: %d %d %d %d %d %d\n", ++ pInfo->name, acol->xmin, acol->xmax, acol->ymin, acol->ymax, ++ acol->pmin, acol->pmax); ++ } ++ + /* Setup the local procs. */ + pInfo->device_control = usbMouseProc; + pInfo->read_input = usbReadInput; +@@ -766,7 +1243,9 @@ p->CheckProtocol = CheckProtocol; #if (defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__DragonFly__)) && defined(MOUSE_PROTO_SYSMOUSE) p->SetupAuto = SetupAuto; Index: x11-drivers/xf86-input-mouse/files/patch-src_mouse.c =================================================================== --- x11-drivers/xf86-input-mouse/files/patch-src_mouse.c (revision 328562) +++ x11-drivers/xf86-input-mouse/files/patch-src_mouse.c (working copy) @@ -1,5 +1,5 @@ ---- src/mouse.c.orig 2012-07-27 08:10:56.000000000 +0200 -+++ src/mouse.c 2012-07-30 00:31:48.000000000 +0200 +--- src/mouse.c.orig 2012-10-08 03:40:07.000000000 +0200 ++++ src/mouse.c 2013-07-03 01:04:45.398343993 +0200 @@ -280,13 +280,39 @@ pMse = pInfo->private; @@ -135,7 +135,7 @@ protocol = MousePickProtocol(pInfo, device, protocol, &protocolID); -@@ -2137,7 +2148,7 @@ +@@ -2136,7 +2147,7 @@ if (pMse->emulateWheel) { /* Emulate wheel button handling */ @@ -144,7 +144,7 @@ wheelButtonMask = 0; else wheelButtonMask = 1 << (pMse->wheelButton - 1); -@@ -2221,6 +2232,9 @@ +@@ -2220,6 +2231,9 @@ } } } @@ -154,7 +154,7 @@ } /* Absorb the mouse movement while the wheel button is pressed. */ -@@ -2238,7 +2252,7 @@ +@@ -2237,7 +2251,7 @@ if (pMse->emulate3ButtonsSoft && pMse->emulate3Pending && (dx || dy)) buttonTimer(pInfo); @@ -163,8 +163,21 @@ xf86PostMotionEvent(pInfo->dev, 0, 0, 2, dx, dy); if (change) { -@@ -2448,11 +2462,11 @@ +@@ -2349,12 +2363,10 @@ + int dx, int dy, int dz, int dw) + { + MouseDevPtr pMse; +- mousePrivPtr mousepriv; + int zbutton = 0, wbutton = 0, zbuttoncount = 0, wbuttoncount = 0; + int i, b, buttons = 0; + pMse = pInfo->private; +- mousepriv = (mousePrivPtr)pMse->mousePriv; + + if (pMse->protocolID == PROT_MMHIT) + b = reverseBits(hitachMap, truebuttons); +@@ -2447,11 +2459,11 @@ + /* Accumulate the scaled dx, dy in the private variables fracdx,fracdy and return the integer number part */ - if (mousepriv) { Index: x11-drivers/xf86-input-synaptics/Makefile =================================================================== --- x11-drivers/xf86-input-synaptics/Makefile (revision 328562) +++ x11-drivers/xf86-input-synaptics/Makefile (working copy) @@ -17,7 +17,7 @@ .include USES= pathfix -USE_XORG= x11 +USE_XORG= x11 xtst XORG_CAT= driver .if ${PORT_OPTIONS:MHAL} Index: x11-drivers/xf86-video-ati/Makefile =================================================================== --- x11-drivers/xf86-video-ati/Makefile (revision 328562) +++ x11-drivers/xf86-video-ati/Makefile (working copy) @@ -1,7 +1,7 @@ # $FreeBSD$ PORTNAME= xf86-video-ati -PORTVERSION= 6.14.6 +PORTVERSION= ${ATI_VERSION} CATEGORIES= x11-drivers MAINTAINER= x11@FreeBSD.org @@ -12,7 +12,18 @@ USE_XORG= xf86driproto xineramaproto xf86miscproto glproto MAN4= ati.4x radeon.4x +NO_STAGE= yes +.include + +.if ${OSVERSION} < 1000051 +ATI_VERSION= 6.14.6 CONFIGURE_ARGS+=--disable-kms +PLIST_SUB+= OLD="" +.else +ATI_VERSION= 7.2.0 +CONFIGURE_ARGS+=--disable-udev +EXTRA_PATCHES+= ${FILESDIR}/extra-src__radeon_kms.c +PLIST_SUB+= OLD="@comment " +.endif -NO_STAGE= yes -.include +.include Index: x11-drivers/xf86-video-ati/distinfo =================================================================== --- x11-drivers/xf86-video-ati/distinfo (revision 328562) +++ x11-drivers/xf86-video-ati/distinfo (working copy) @@ -1,2 +1,4 @@ SHA256 (xorg/driver/xf86-video-ati-6.14.6.tar.bz2) = aa5286b3e4f0187d7df14785c06dd800255d9405205dbf061da5d77df86bec36 SIZE (xorg/driver/xf86-video-ati-6.14.6.tar.bz2) = 1139495 +SHA256 (xorg/driver/xf86-video-ati-7.2.0.tar.bz2) = f30f5efdc8d7d18d06eda7ef2f91a8b7290f1cfbf6ff26362cd47ab8969daec4 +SIZE (xorg/driver/xf86-video-ati-7.2.0.tar.bz2) = 824613 Index: x11-drivers/xf86-video-ati/files/extra-src__radeon_kms.c =================================================================== --- x11-drivers/xf86-video-ati/files/extra-src__radeon_kms.c (revision 0) +++ x11-drivers/xf86-video-ati/files/extra-src__radeon_kms.c (working copy) @@ -0,0 +1,20 @@ +--- src/radeon_kms.c.orig 2013-08-07 10:44:09.000000000 +0200 ++++ src/radeon_kms.c 2013-08-31 01:20:44.370468797 +0200 +@@ -270,7 +270,7 @@ + radeon_dirty_update(ScreenPtr screen) + { + RegionPtr region; +- PixmapDirtyUpdatePtr ent; ++ PixmapDirtyUpdatePtr ent = NULL; + + if (xorg_list_is_empty(&screen->pixmap_dirty_list)) + return; +@@ -606,7 +606,7 @@ + dev->domain, dev->bus, dev->dev, dev->func); + #endif + +- info->dri2.drm_fd = drmOpen("radeon", busid); ++ info->dri2.drm_fd = drmOpen("radeonkms", busid); + if (info->dri2.drm_fd == -1) { + + xf86DrvMsg(pScrn->scrnIndex, X_ERROR, Property changes on: x11-drivers/xf86-video-ati/files/extra-src__radeon_kms.c ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: x11-drivers/xf86-video-ati/files/patch-src__radeon_dri2.c =================================================================== --- x11-drivers/xf86-video-ati/files/patch-src__radeon_dri2.c (revision 0) +++ x11-drivers/xf86-video-ati/files/patch-src__radeon_dri2.c (working copy) @@ -0,0 +1,11 @@ +--- src/radeon_dri2.c.orig 2013-02-22 19:31:34.000000000 +0000 ++++ src/radeon_dri2.c 2013-02-22 19:31:47.000000000 +0000 +@@ -578,7 +578,7 @@ + radeon_dri2_client_state_changed(CallbackListPtr *ClientStateCallback, pointer data, pointer calldata) + { + DRI2ClientEventsPtr pClientEventsPriv; +- DRI2FrameEventPtr ref; ++ DRI2FrameEventPtr ref = NULL; + NewClientInfoRec *clientinfo = calldata; + ClientPtr pClient = clientinfo->client; + pClientEventsPriv = GetDRI2ClientEvents(pClient); Property changes on: x11-drivers/xf86-video-ati/files/patch-src__radeon_dri2.c ___________________________________________________________________ Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: x11-drivers/xf86-video-ati/pkg-plist =================================================================== --- x11-drivers/xf86-video-ati/pkg-plist (revision 328562) +++ x11-drivers/xf86-video-ati/pkg-plist (working copy) @@ -2,13 +2,13 @@ lib/xorg/modules/drivers/ati_drv.so lib/xorg/modules/drivers/radeon_drv.la lib/xorg/modules/drivers/radeon_drv.so -lib/xorg/modules/multimedia/theatre200_drv.la -lib/xorg/modules/multimedia/theatre200_drv.so -lib/xorg/modules/multimedia/theatre_detect_drv.la -lib/xorg/modules/multimedia/theatre_detect_drv.so -lib/xorg/modules/multimedia/theatre_drv.la -lib/xorg/modules/multimedia/theatre_drv.so +%%OLD%%lib/xorg/modules/multimedia/theatre200_drv.la +%%OLD%%lib/xorg/modules/multimedia/theatre200_drv.so +%%OLD%%lib/xorg/modules/multimedia/theatre_detect_drv.la +%%OLD%%lib/xorg/modules/multimedia/theatre_detect_drv.so +%%OLD%%lib/xorg/modules/multimedia/theatre_drv.la +%%OLD%%lib/xorg/modules/multimedia/theatre_drv.so @dirrmtry lib/xorg/modules/drivers -@dirrmtry lib/xorg/modules/multimedia +%%OLD%%@dirrmtry lib/xorg/modules/multimedia @dirrmtry lib/xorg/modules @dirrmtry lib/xorg Index: x11-drivers/xf86-video-fbdev/Makefile =================================================================== --- x11-drivers/xf86-video-fbdev/Makefile (revision 328562) +++ x11-drivers/xf86-video-fbdev/Makefile (working copy) @@ -1,7 +1,7 @@ # $FreeBSD$ PORTNAME= xf86-video-fbdev -PORTVERSION= 0.4.3 +PORTVERSION= 0.4.4 PORTREVISION= 1 CATEGORIES= x11-drivers Index: x11-drivers/xf86-video-fbdev/distinfo =================================================================== --- x11-drivers/xf86-video-fbdev/distinfo (revision 328562) +++ x11-drivers/xf86-video-fbdev/distinfo (working copy) @@ -1,2 +1,2 @@ -SHA256 (xorg/driver/xf86-video-fbdev-0.4.3.tar.bz2) = ff7b037ad110040a4e2db5c84e9741125dbbaf3a08107db47760f3e11f9c4831 -SIZE (xorg/driver/xf86-video-fbdev-0.4.3.tar.bz2) = 289056 +SHA256 (xorg/driver/xf86-video-fbdev-0.4.4.tar.bz2) = 9dd4b326498223abbfdf786089a46ea3db4fa6bbd341308eb48a9e00bc3fd51b +SIZE (xorg/driver/xf86-video-fbdev-0.4.4.tar.bz2) = 293545 Index: x11-drivers/xf86-video-intel/Makefile =================================================================== --- x11-drivers/xf86-video-intel/Makefile (revision 328562) +++ x11-drivers/xf86-video-intel/Makefile (working copy) @@ -29,20 +29,20 @@ .include .if defined(WITH_NEW_XORG) -INTEL_VERSION= 2.21.9 +INTEL_VERSION= 2.21.15 INTEL_REVISION= 0 +CONFIGURE_ENV+= xorg_cv_cc_flag__Wno_maybe_uninitialized=no CONFIGURE_ARGS+= --enable-sna MAKE_JOBS_UNSAFE=yes PLIST_SUB+= OLD="@comment " -EXTRA_PATCHES+= ${PATCHDIR}/extra-clang \ - ${PATCHDIR}/extra-src_sna_compiler.h \ +EXTRA_PATCHES+= ${PATCHDIR}/extra-src__sna__sna_threads.c \ ${PATCHDIR}/extra-src_sna_kgem.c \ - ${PATCHDIR}/extra-src__sna__sna_threads.c \ + ${PATCHDIR}/extra-clang \ ${PATCHDIR}/extra-i915kms LIB_DEPENDS+= xcb-util:${PORTSDIR}/x11/xcb-util .else INTEL_VERSION= 2.7.1 -INTEL_REVISION= 4 +INTEL_REVISION= 5 PLIST_SUB+= OLD="" EXTRA_PATCHES+= ${PATCHDIR}/extra-src_ch7017_ch7017.c \ Index: x11-drivers/xf86-video-intel/distinfo =================================================================== --- x11-drivers/xf86-video-intel/distinfo (revision 328562) +++ x11-drivers/xf86-video-intel/distinfo (working copy) @@ -1,4 +1,4 @@ SHA256 (xorg/driver/xf86-video-intel-2.7.1.tar.bz2) = 255c0d54249cc0132f743254a43c21fac695fab2139c8ed96a07cf3c628e5f42 SIZE (xorg/driver/xf86-video-intel-2.7.1.tar.bz2) = 780625 -SHA256 (xorg/driver/xf86-video-intel-2.21.9.tar.bz2) = 1359cbc9e494a284faa52d1db83e7388cb8ab590b660e29e78e6e7f5ee7ff189 -SIZE (xorg/driver/xf86-video-intel-2.21.9.tar.bz2) = 1735037 +SHA256 (xorg/driver/xf86-video-intel-2.21.15.tar.bz2) = 7d5a140f82a72fd1cbc8a664d66c3d4eca47ee240ca4927b8a98d7af6f65d6fc +SIZE (xorg/driver/xf86-video-intel-2.21.15.tar.bz2) = 1977431 Index: x11-drivers/xf86-video-intel/files/extra-clang =================================================================== --- x11-drivers/xf86-video-intel/files/extra-clang (revision 328562) +++ x11-drivers/xf86-video-intel/files/extra-clang (working copy) @@ -1,27 +1,15 @@ ---- src/intel_display.c.orig 2012-12-11 20:33:06.000000000 +0100 -+++ src/intel_display.c 2012-12-11 20:33:45.000000000 +0100 -@@ -1691,7 +1691,7 @@ - static drmModeEncoderPtr - intel_get_kencoder(struct intel_mode *mode, int num) +--- src/sna/sna_cpu.c.orig 2013-08-14 12:04:40.231041285 +0200 ++++ src/sna/sna_cpu.c 2013-08-14 12:05:51.237030719 +0200 +@@ -41,6 +41,7 @@ { -- struct intel_output *iterator; -+ struct intel_output *iterator = NULL; - int id = mode->mode_res->encoders[num]; + unsigned max = __get_cpuid_max(BASIC_CPUID, NULL); + unsigned int eax, ebx, ecx, edx; ++ eax = ebx = ecx = edx = 0; + unsigned features = 0; + unsigned extra = 0; - list_for_each_entry(iterator, &mode->outputs, link) ---- src/intel_batchbuffer.c.orig 2012-12-11 20:34:55.000000000 +0100 -+++ src/intel_batchbuffer.c 2012-12-11 20:35:19.000000000 +0100 -@@ -119,7 +119,7 @@ - static void intel_batch_do_flush(ScrnInfoPtr scrn) - { - intel_screen_private *intel = intel_get_screen_private(scrn); -- struct intel_pixmap *priv; -+ struct intel_pixmap *priv = NULL; - - list_for_each_entry(priv, &intel->batch_pixmaps, batch) - priv->dirty = 0; ---- src/sna/sna_damage.c.orig 2012-12-11 20:41:38.000000000 +0100 -+++ src/sna/sna_damage.c 2012-12-11 20:42:23.000000000 +0100 +--- src/sna/sna_damage.c.orig 2013-08-14 12:06:26.381036854 +0200 ++++ src/sna/sna_damage.c 2013-08-14 12:07:23.684023065 +0200 @@ -410,7 +410,7 @@ int n, nboxes; BoxPtr boxes, free_boxes = NULL; @@ -31,7 +19,7 @@ assert(damage->mode != DAMAGE_ALL); assert(damage->dirty); -@@ -1671,7 +1671,7 @@ +@@ -1709,7 +1709,7 @@ { int n, nboxes; BoxPtr boxes; @@ -40,8 +28,30 @@ RegionCopy(r, &damage->region); if (!damage->dirty) ---- uxa/uxa-accel.c.orig 2012-12-11 20:50:56.000000000 +0100 -+++ uxa/uxa-accel.c 2012-12-11 20:51:14.000000000 +0100 +--- src/uxa/intel_batchbuffer.c.orig 2013-08-14 12:08:14.323028320 +0200 ++++ src/uxa/intel_batchbuffer.c 2013-08-14 12:08:37.202016923 +0200 +@@ -141,7 +141,7 @@ + static void intel_batch_do_flush(ScrnInfoPtr scrn) + { + intel_screen_private *intel = intel_get_screen_private(scrn); +- struct intel_pixmap *priv; ++ struct intel_pixmap *priv = NULL; + + list_for_each_entry(priv, &intel->batch_pixmaps, batch) + priv->dirty = 0; +--- src/uxa/intel_display.c.orig 2013-08-14 12:09:25.802015629 +0200 ++++ src/uxa/intel_display.c 2013-08-14 12:09:51.034009844 +0200 +@@ -1753,7 +1753,7 @@ + static drmModeEncoderPtr + intel_get_kencoder(struct intel_mode *mode, int num) + { +- struct intel_output *iterator; ++ struct intel_output *iterator = NULL; + int id = mode->mode_res->encoders[num]; + + list_for_each_entry(iterator, &mode->outputs, link) +--- src/uxa/uxa-accel.c.orig 2013-08-14 12:02:11.898048975 +0200 ++++ src/uxa/uxa-accel.c 2013-08-14 12:03:39.336042139 +0200 @@ -944,7 +944,7 @@ if (uxa_screen->info->flags & UXA_USE_GLAMOR) { Index: x11-drivers/xf86-video-intel/files/extra-i915kms =================================================================== --- x11-drivers/xf86-video-intel/files/extra-i915kms (revision 328562) +++ x11-drivers/xf86-video-intel/files/extra-i915kms (working copy) @@ -1,13 +1,13 @@ ---- src/intel_module.c.orig 2012-09-27 23:31:20.000000000 +0300 -+++ src/intel_module.c 2012-11-02 17:32:00.819723398 +0200 -@@ -393,8 +393,8 @@ - dev->domain, dev->bus, dev->dev, dev->func); +--- src/intel_device.c.orig 2013-06-30 16:03:51.000000000 +0200 ++++ src/intel_device.c 2013-07-02 14:08:34.903060688 +0200 +@@ -94,8 +94,8 @@ + pci->domain, pci->bus, pci->dev, pci->func); - ret = drmCheckModesettingSupported(id); -- if (ret) { -- if (xf86LoadKernelModule("i915")) -+ if (ret || 1) { -+ if (xf86LoadKernelModule("i915kms")) - ret = drmCheckModesettingSupported(id); - if (ret) - return FALSE; + ret = drmCheckModesettingSupported(id); +- if (ret) { +- if (xf86LoadKernelModule("i915")) ++ if (ret || 1) { ++ if (xf86LoadKernelModule("i915kms")) + ret = drmCheckModesettingSupported(id); + if (ret) + return -1; Index: x11-drivers/xf86-video-intel/files/extra-src_sna_compiler.h =================================================================== --- x11-drivers/xf86-video-intel/files/extra-src_sna_compiler.h (revision 328562) +++ x11-drivers/xf86-video-intel/files/extra-src_sna_compiler.h (working copy) @@ -1,18 +0,0 @@ ---- src/sna/compiler.h.orig 2013-03-12 12:48:29.745101779 +0100 -+++ src/sna/compiler.h 2013-03-12 12:48:52.857102997 +0100 -@@ -37,7 +37,6 @@ - #define must_check __attribute__((warn_unused_result)) - #define constant __attribute__((const)) - #define pure __attribute__((pure)) --#define __packed__ __attribute__((__packed__)) - #define flatten __attribute__((flatten)) - #else - #define likely(expr) (expr) -@@ -48,7 +47,6 @@ - #define must_check - #define constant - #define pure --#define __packed__ - #define flatten - #endif - Index: x11-drivers/xf86-video-intel/files/extra-src_sna_kgem.c =================================================================== --- x11-drivers/xf86-video-intel/files/extra-src_sna_kgem.c (revision 328562) +++ x11-drivers/xf86-video-intel/files/extra-src_sna_kgem.c (working copy) @@ -1,18 +1,14 @@ ---- src/sna/kgem.c.orig 2013-03-11 11:19:02.000000000 +0100 -+++ src/sna/kgem.c 2013-03-12 12:56:49.452065668 +0100 -@@ -658,7 +658,11 @@ - if (file) { - size_t len = 0; - char *line = NULL; -+#ifdef __GLIBC__ - while (getline(&line, &len, file) != -1) { -+#else -+ while ((line = fgetln(file, &len)) != (char *) NULL) { -+#endif - int mb; - if (sscanf(line, "cache size : %d KB", &mb) == 1) { - /* Paranoid check against gargantuan caches */ -@@ -1666,7 +1670,8 @@ +--- src/sna/kgem.c.orig 2013-08-04 11:10:59.000000000 +0200 ++++ src/sna/kgem.c 2013-08-14 11:59:14.787060294 +0200 +@@ -25,6 +25,7 @@ + * + */ + ++#define _WITH_GETLINE + #ifdef HAVE_CONFIG_H + #include "config.h" + #endif +@@ -1890,7 +1891,8 @@ static struct kgem_bo * search_snoop_cache(struct kgem *kgem, unsigned int num_pages, unsigned flags) { @@ -22,7 +18,7 @@ DBG(("%s: num_pages=%d, flags=%x\n", __FUNCTION__, num_pages, flags)); -@@ -1868,7 +1873,8 @@ +@@ -2104,7 +2106,8 @@ static bool kgem_retire__flushing(struct kgem *kgem) { @@ -32,7 +28,7 @@ bool retired = false; list_for_each_entry_safe(bo, next, &kgem->flushing, request) { -@@ -2073,7 +2079,8 @@ +@@ -2309,7 +2312,8 @@ static void kgem_commit(struct kgem *kgem) { struct kgem_request *rq = kgem->next_request; @@ -42,7 +38,7 @@ list_for_each_entry_safe(bo, next, &rq->buffers, request) { assert(next->request.prev == &bo->request); -@@ -2154,7 +2161,8 @@ +@@ -2390,7 +2394,8 @@ static void kgem_finish_buffers(struct kgem *kgem) { @@ -51,8 +47,8 @@ + struct kgem_buffer *next; list_for_each_entry_safe(bo, next, &kgem->batch_buffers, base.list) { - DBG(("%s: buffer handle=%d, used=%d, exec?=%d, write=%d, mmapped=%d\n", -@@ -2963,7 +2971,8 @@ + DBG(("%s: buffer handle=%d, used=%d, exec?=%d, write=%d, mmapped=%s\n", +@@ -3252,7 +3257,8 @@ static struct kgem_bo * search_linear_cache(struct kgem *kgem, unsigned int num_pages, unsigned flags) { @@ -62,7 +58,7 @@ bool use_active = (flags & CREATE_INACTIVE) == 0; struct list *cache; -@@ -3521,7 +3530,7 @@ +@@ -3855,7 +3861,7 @@ uint32_t flags) { struct list *cache; @@ -71,7 +67,7 @@ uint32_t pitch, tiled_height, size; uint32_t handle; int i, bucket, retry; -@@ -4834,7 +4843,7 @@ +@@ -5302,7 +5308,7 @@ void kgem_clear_dirty(struct kgem *kgem) { struct list * const buffers = &kgem->next_request->buffers; @@ -79,8 +75,8 @@ + struct kgem_bo *bo = NULL; list_for_each_entry(bo, buffers, request) { - if (!bo->dirty) -@@ -5072,7 +5081,7 @@ + if (!bo->gpu_dirty) +@@ -5578,7 +5584,7 @@ uint32_t size, uint32_t flags, void **ret) { Index: x11-drivers/xf86-video-vesa/Makefile =================================================================== --- x11-drivers/xf86-video-vesa/Makefile (revision 328562) +++ x11-drivers/xf86-video-vesa/Makefile (working copy) @@ -1,7 +1,7 @@ # $FreeBSD$ PORTNAME= xf86-video-vesa -PORTVERSION= 2.3.2 +PORTVERSION= 2.3.3 CATEGORIES= x11-drivers MAINTAINER= x11@FreeBSD.org Index: x11-drivers/xf86-video-vesa/distinfo =================================================================== --- x11-drivers/xf86-video-vesa/distinfo (revision 328562) +++ x11-drivers/xf86-video-vesa/distinfo (working copy) @@ -1,2 +1,2 @@ -SHA256 (xorg/driver/xf86-video-vesa-2.3.2.tar.bz2) = 144a17ffae3c86603ddc4ae33521a52813498ee1f8213faa662dc4a8d6490ee3 -SIZE (xorg/driver/xf86-video-vesa-2.3.2.tar.bz2) = 298186 +SHA256 (xorg/driver/xf86-video-vesa-2.3.3.tar.bz2) = ce8b75e5a40e9dae76f2ac9e2880f7f73a848653ca2eed5880f52dc2c0d3aef8 +SIZE (xorg/driver/xf86-video-vesa-2.3.3.tar.bz2) = 300571 Index: x11-drivers/xorg-drivers/Makefile =================================================================== --- x11-drivers/xorg-drivers/Makefile (revision 328562) +++ x11-drivers/xorg-drivers/Makefile (working copy) @@ -10,7 +10,7 @@ MAINTAINER= x11@FreeBSD.org COMMENT= X.org drivers meta-port -.MAKE.FreeBSD_UL= yes +.MAKE.FreeBSD_UL= yes VIDEODIR= ${PREFIX}/lib/xorg/modules/drivers INPUTDIR= ${PREFIX}/lib/xorg/modules/input Index: x11-fonts/xfs/Makefile =================================================================== --- x11-fonts/xfs/Makefile (revision 328562) +++ x11-fonts/xfs/Makefile (working copy) @@ -9,7 +9,7 @@ COMMENT= X.Org font server XORG_CAT= app -USE_GMAKE= yes +USES= gmake USE_XORG= libfs xfont xtrans USE_RC_SUBR= xfs CONFIGURE_ARGS= --without-xmlto --without-fop Index: x11-servers/xephyr/Makefile =================================================================== --- x11-servers/xephyr/Makefile (revision 328562) +++ x11-servers/xephyr/Makefile (working copy) @@ -1,7 +1,6 @@ # $FreeBSD$ PORTNAME= xephyr -PORTREVISION= 0 COMMENT= X server from X.Org based on kdrive Index: x11-servers/xorg-dmx/Makefile =================================================================== --- x11-servers/xorg-dmx/Makefile (revision 328562) +++ x11-servers/xorg-dmx/Makefile (working copy) @@ -2,7 +2,6 @@ # $FreeBSD$ PORTNAME= xorg-dmx -PORTREVISION= 0 COMMENT= Distributed Multihead X from X.Org Index: x11-servers/xorg-nestserver/Makefile =================================================================== --- x11-servers/xorg-nestserver/Makefile (revision 328562) +++ x11-servers/xorg-nestserver/Makefile (working copy) @@ -24,6 +24,8 @@ MAN1= Xnest.1 NO_STAGE= yes +.include + do-install: ${INSTALL_PROGRAM} ${WRKSRC}/hw/xnest/Xnest ${PREFIX}/bin/ .if defined(WITH_NEW_XORG) Index: x11-servers/xorg-server/Makefile =================================================================== --- x11-servers/xorg-server/Makefile (revision 328562) +++ x11-servers/xorg-server/Makefile (working copy) @@ -20,14 +20,28 @@ XORG_CAT= xserver SLAVE_PORT?= no +OPTIONS_DEFINE= AIGLX SUID +OPTIONS_RADIO= CONF +OPTIONS_RADIO_CONF= HAL DEVD +AIGLX_DESC= Compile with Accelerated Indirect GLX support +SUID_DESC= Install the Xorg server with setuid bit set +HAL_DESC= Compile with HAL config support +DEVD_DESC= Use devd for autoconfiguration of input devices (experimental) +OPTIONS_DEFAULT=AIGLX SUID HAL + +OPTIONS_EXCLUDE_sparc64= HAL + +.include + .if defined(WITH_NEW_XORG) XORG_VERSION= 1.12.4 -XORG_REVISION= 1 +XORG_REVISION= 2 PLIST_SUB+= OLD="@comment " NEW="" -EXTRA_PATCHES+= ${FILESDIR}/extra-clang +EXTRA_PATCHES+= ${FILESDIR}/extra-clang \ + ${FILESDIR}/extra-configure .else XORG_VERSION= 1.7.7 -XORG_REVISION= 8 +XORG_REVISION= 9 PLIST_SUB+= OLD="" NEW="@comment " EXTRA_PATCHES+= ${FILESDIR}/extra-Xext-xace.c \ ${FILESDIR}/extra-Xserver-hw-xfree86-os-support-bsd-sparc64_video.c \ @@ -39,10 +53,8 @@ ${FILESDIR}/extra-Xserver-hw-xfree86-common-xf86Config.c .endif -USES= perl5 -USE_PERL5= build USE_BZIP2= yes -USE_GMAKE= yes +USES= gmake USE_GL= gl USE_XORG?= xf86driproto glproto xdmcp x11 xkbfile xxf86misc xxf86vm xaw7 \ xmu xt xpm xext randrproto renderproto fixesproto damageproto \ @@ -54,6 +66,7 @@ MAKE_JOBS_UNSAFE= yes USE_OPENSSL= yes +USE_PERL5_BUILD=yes CONFIGURE_ARGS?=--disable-dmx --disable-xvfb --disable-xnest \ --without-xmlto --disable-docs --disable-devel-docs \ --localstatedir=/var --without-dtrace --disable-xephyr \ @@ -78,14 +91,6 @@ PLIST= ${.CURDIR}/pkg-plist .endif -OPTIONS_DEFINE= AIGLX SUID HAL -AIGLX_DESC= Compile with Accelerated Indirect GLX support -SUID_DESC= Install the Xorg server with setuid bit set -HAL_DESC= Compile with HAL config support -OPTIONS_DEFAULT= AIGLX SUID HAL - -OPTIONS_EXCLUDE_sparc64= HAL - NO_STAGE= yes .include @@ -103,6 +108,10 @@ CONFIGURE_ARGS+= --enable-config-hal=no .endif +.if ${PORT_OPTIONS:MDEVD} +EXTRA_PATCHES+= ${FILESDIR}/extra-config_devd.c +.endif + .if ${PORT_OPTIONS:MAIGLX} CONFIGURE_ARGS+= --enable-aiglx=yes .else @@ -172,6 +181,17 @@ @${REINPLACE_CMD} -e 's|@GLX_TRUE@GLXMODS =|@GLX_BOGUS@GLXMODS =|g' \ -e 's|^LTLIBRARIES = |LTLIBRARIES = libglx.la |g' \ ${WRKSRC}/hw/xfree86/dixmods/Makefile.in +.if ${PORT_OPTIONS:MDEVD} + @${ECHO_CMD} -e "\nint config_devd_init(void);\nvoid config_devd_fini(void);" \ + >> ${WRKSRC}/config/config-backends.h +.endif + +post-configure: +.if ${PORT_OPTIONS:MDEVD} + @${REINPLACE_CMD} -e 's|config\.c|config.c devd.c|g' \ + -e 's|config\.lo|config.lo devd.lo|g' \ + ${WRKSRC}/config/Makefile +.endif .if ${SLAVE_PORT} == "no" pre-su-install: Index: x11-servers/xorg-server/files/extra-config_devd.c =================================================================== --- x11-servers/xorg-server/files/extra-config_devd.c (revision 0) +++ x11-servers/xorg-server/files/extra-config_devd.c (working copy) @@ -0,0 +1,481 @@ +--- /dev/null 2013-08-03 00:44:23.000000000 +0200 ++++ config/devd.c 2013-08-03 00:45:15.162836806 +0200 +@@ -0,0 +1,478 @@ ++/* ++ * Copyright © 2012 Baptiste Daroussin ++ * ++ * Permission is hereby granted, free of charge, to any person obtaining a ++ * copy of this software and associated documentation files (the "Software"), ++ * to deal in the Software without restriction, including without limitation ++ * the rights to use, copy, modify, merge, publish, distribute, sublicense, ++ * and/or sell copies of the Software, and to permit persons to whom the ++ * Software is furnished to do so, subject to the following conditions: ++ * ++ * The above copyright notice and this permission notice (including the next ++ * paragraph) shall be included in all copies or substantial portions of the ++ * Software. ++ * ++ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR ++ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, ++ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL ++ * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER ++ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING ++ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER ++ * DEALINGS IN THE SOFTWARE. ++ * ++ * Author: Baptiste Daroussin ++ */ ++ ++#ifdef HAVE_DIX_CONFIG_H ++#include ++#endif ++ ++#include ++#include ++#include ++#include ++ ++#include ++#include ++#include ++#include ++#include ++#include ++ ++#include "input.h" ++#include "inputstr.h" ++#include "hotplug.h" ++#include "config-backends.h" ++#include "os.h" ++ ++#define DEVD_SOCK_PATH "/var/run/devd.pipe" ++ ++#define DEVD_EVENT_ADD '+' ++#define DEVD_EVENT_REMOVE '-' ++ ++static int sock_devd = -1; ++ ++#if XORG_VERSION_CURRENT < 10800000 ++enum { ++ ATTR_KEYBOARD, ++ ATTR_POINTER, ++ ATTR_JOYSTICK, ++ ATTR_TOUCHPAD, ++ ATTR_TOUCHSCREEN, ++}; ++#endif ++ ++struct hw_type { ++ const char *driver; ++ int flag; ++ const char *xdriver; ++}; ++ ++static struct hw_type hw_types[] = { ++ { "ukbd", ATTR_KEYBOARD, "kdb" }, ++ { "atkbd", ATTR_KEYBOARD, "kdb" }, ++ { "ums", ATTR_POINTER, "mouse" }, ++ { "psm", ATTR_POINTER, "mouse" }, ++ { "uhid", ATTR_POINTER, "mouse" }, ++ { "joy", ATTR_JOYSTICK, NULL }, ++ { "atp", ATTR_TOUCHPAD, NULL }, ++ { "uep", ATTR_TOUCHSCREEN, NULL }, ++ { NULL, -1, NULL }, ++}; ++ ++#if XORG_VERSION_CURRENT < 10800000 ++static void ++add_option(InputOption **options, const char *key, const char *value) ++{ ++ if (!value || *value == '\0') ++ return; ++ ++ for (; *options; options = &(*options)->next) ++ ; ++ *options = calloc(sizeof(**options), 1); ++ if (!*options) /* Yeesh. */ ++ return; ++ (*options)->key = xstrdup(key); ++ (*options)->value = xstrdup(value); ++ (*options)->next = NULL; ++} ++ ++static void ++remove_device(DeviceIntPtr dev) ++{ ++ /* this only gets called for devices that have already been added */ ++ LogMessage(X_INFO, "config/devd: removing device %s\n", dev->name); ++ ++ /* Call PIE here so we don't try to dereference a device that's ++ * already been removed. */ ++ OsBlockSignals(); ++ ProcessInputEvents(); ++ DeleteInputDeviceRequest(dev); ++ OsReleaseSignals(); ++} ++ ++static bool ++device_is_duplicate(char *config_info) ++{ ++ DeviceIntPtr dev; ++ ++ for (dev = inputInfo.devices; dev; dev = dev->next) ++ if (dev->config_info && (strcmp(dev->config_info, config_info) == 0)) ++ return true; ++ ++ for (dev = inputInfo.off_devices; dev; dev = dev->next) ++ if (dev->config_info && (strcmp(dev->config_info, config_info) == 0)) ++ return true; ++ ++ return false; ++} ++ ++#endif ++ ++static bool ++sysctl_exists(const char *format, ...) ++{ ++ va_list args; ++ char *name = NULL; ++ size_t len; ++ int ret; ++ ++ if (format == NULL) ++ return false; ++ ++ va_start(args, format); ++ vasprintf(&name, format, args); ++ va_end(args); ++ ++ ret = sysctlbyname(name, NULL, &len, NULL, 0); ++ ++ if (ret == -1) ++ len = 0; ++ ++ free(name); ++ return (len > 0); ++} ++ ++static char * ++sysctl_get_str(const char *format, ...) ++{ ++ va_list args; ++ char *name = NULL; ++ char *dest = NULL; ++ size_t len; ++ ++ if (format == NULL) ++ return NULL; ++ ++ va_start(args, format); ++ vasprintf(&name, format, args); ++ va_end(args); ++ ++ if (sysctlbyname(name, NULL, &len, NULL, 0) == 0) { ++ dest = malloc(len + 1); ++ if (sysctlbyname(name, dest, &len, NULL, 0) == 0) ++ dest[len] = '\0'; ++ else { ++ free(dest); ++ dest = NULL; ++ } ++ } ++ ++ free(name); ++ return dest; ++} ++ ++static void ++device_added(char *line) ++{ ++ char *walk; ++ char *path; ++ char *vendor; ++ char *product = NULL; ++ char *config_info = NULL; ++ InputOption *options = NULL; ++#if XORG_VERSION_CURRENT > 10800000 ++ InputAttributes attrs = {}; ++#else ++ InputOption *tmpo; ++#endif ++ DeviceIntPtr dev = NULL; ++ int i, rc; ++ ++ walk = strchr(line, ' '); ++ if (walk != NULL) ++ walk[0] = '\0'; ++ ++ for (i = 0; hw_types[i].driver != NULL; i++) { ++ if (strncmp(line, hw_types[i].driver, ++ strlen(hw_types[i].driver)) == 0 && ++ isnumber(*(line + strlen(hw_types[i].driver)))) { ++#if XORG_VERSION_CURRENT > 10800000 ++ attrs.flags |= hw_types[i].flag; ++#endif ++ break; ++ } ++ } ++ if (hw_types[i].driver == NULL) { ++ LogMessageVerb(X_INFO, 10, "config/devd: ignoring device %s\n", line); ++ return; ++ } ++ ++#if XORG_VERSION_CURRENT < 10800000 ++ if (hw_types[i].xdriver == NULL) { ++ LogMessageVerb(X_INFO, 10, "config/devd: ignoring device %s\n", line); ++ return; ++ } ++#endif ++ if (asprintf(&path, "/dev/%s", line) == -1) ++ return; ++ ++#if XORG_VERSION_CURRENT < 10800000 ++ options = calloc(sizeof(*options), 1); ++ if (!options) ++ return; ++ ++ add_option(&options, "_source", "server/devd"); ++#else ++ options = input_option_new(NULL, "_source", "server/devd"); ++ if (!options) ++ return; ++#endif ++ ++ vendor = sysctl_get_str("dev.%s.%s.%%desc", hw_types[i].driver, line + strlen(hw_types[i].driver)); ++ if (vendor == NULL) { ++#if XORG_VERSION_CURRENT > 10800000 ++ attrs.vendor = strdup("(unnamed)"); ++#endif ++ } else { ++ if ((product = strchr(vendor, ' ')) != NULL) { ++ product[0] = '\0'; ++ product++; ++ } ++#if XORG_VERSION_CURRENT > 10800000 ++ attrs.vendor = strdup(vendor); ++#endif ++ if (product != NULL && (walk = strchr(product, ',')) != NULL) ++ walk[0] = '\0'; ++#if XORG_VERSION_CURRENT > 10800000 ++ attrs.product = strdup(product != NULL ? product : "(unnamed)"); ++ options = input_option_new(options, "name", product != NULL ? product : "(unnamed)"); ++#else ++ add_option(&options, "name", product != NULL ? product : "(unnamed)"); ++#endif ++ } ++#if XORG_VERSION_CURRENT > 10800000 ++ attrs.usb_id = NULL; ++ options = input_option_new(options, "path", path); ++ options = input_option_new(options, "device", path); ++#else ++ add_option(&options, "path", path); ++ add_option(&options, "device", path); ++#endif ++ ++#if XORG_VERSION_CURRENT < 10800000 ++ add_option(&options, "driver", hw_types[i].xdriver); ++#endif ++ ++ if (asprintf(&config_info, "devd:%s", line) == -1) { ++ config_info = NULL; ++ goto unwind; ++ } ++ ++ if (device_is_duplicate(config_info)) { ++ LogMessage(X_WARNING, "config/devd: device %s already added. " ++ "Ignoring.\n", product != NULL ? product : "(unnamed)"); ++ goto unwind; ++ } ++ ++#if XORG_VERSION_CURRENT < 10800000 ++ add_option(&options, "config_info", config_info); ++#else ++ options = input_option_new(options, "config_info", config_info); ++#endif ++ LogMessage(X_INFO, "config/devd: Adding input device %s (%s)\n", ++ product != NULL ? product : "(unnamed)", path); ++ ++#if XORG_VERSION_CURRENT > 10800000 ++ rc = NewInputDeviceRequest(options, &attrs, &dev); ++#else ++ rc = NewInputDeviceRequest(options, &dev); ++#endif ++ ++ if (rc != Success) ++ goto unwind; ++ ++ unwind: ++ free(config_info); ++#if XORG_VERSION_CURRENT < 10800000 ++ while ((tmpo = options)) { ++ options = tmpo->next; ++ free(tmpo->key); /* NULL if dev != NULL */ ++ free(tmpo->value); /* NULL if dev != NULL */ ++ free(tmpo); ++ } ++#else ++ input_option_free_list(&options); ++#endif ++ ++#if XORG_VERSION_CURRENT > 10800000 ++ free(attrs.usb_id); ++ free(attrs.product); ++ free(attrs.device); ++ free(attrs.vendor); ++#endif ++ ++ return; ++} ++ ++static void ++device_removed(char *line) ++{ ++ char *walk; ++ char *value; ++#if XORG_VERSION_CURRENT < 10800000 ++ DeviceIntPtr dev, next; ++#endif ++ ++ walk = strchr(line, ' '); ++ if (walk != NULL) ++ walk[0] = '\0'; ++ ++ if (asprintf(&value, "devd:%s", line) == -1) ++ return; ++ ++#if XORG_VERSION_CURRENT > 10800000 ++ remove_devices("dev", value); ++#else ++ for (dev = inputInfo.devices; dev; dev = next) { ++ next = dev->next; ++ if (dev->config_info && strcmp(dev->config_info, value) == 0) ++ remove_device(dev); ++ } ++ for (dev = inputInfo.off_devices; dev; dev = next) { ++ next = dev->next; ++ if (dev->config_info && strcmp(dev->config_info, value) == 0) ++ remove_device(dev); ++ } ++#endif ++ ++ free(value); ++} ++ ++static ssize_t ++socket_getline(int fd, char **out) ++{ ++ char *buf; ++ ssize_t ret, cap, sz = 0; ++ char c; ++ ++ cap = 1024; ++ buf = malloc(cap * sizeof(char)); ++ if (!buf) ++ return -1; ++ ++ for (;;) { ++ ret = read(sock_devd, &c, 1); ++ if (ret < 1) { ++ free(buf); ++ return -1; ++ } ++ ++ if (c == '\n') ++ break; ++ ++ if (sz + 1 >= cap) { ++ cap *= 2; ++ buf = realloc(buf, cap *sizeof(char)); ++ } ++ buf[sz] = c; ++ sz++; ++ } ++ ++ buf[sz] = '\0'; ++ if (sz > 0) ++ *out = buf; ++ else ++ free(buf); ++ ++ return sz; /* number of bytes in the line, not counting the line break*/ ++} ++ ++static void ++wakeup_handler(pointer data, int err, pointer read_mask) ++{ ++ char *line = NULL; ++ ++ if (err < 0) ++ return; ++ ++ if (FD_ISSET(sock_devd, (fd_set *)read_mask)) { ++ if (socket_getline(sock_devd, &line) < 0) ++ return; ++ ++ switch(*line) { ++ case DEVD_EVENT_ADD: ++ device_added(line++); ++ break; ++ case DEVD_EVENT_REMOVE: ++ device_removed(line++); ++ break; ++ default: ++ break; ++ } ++ free(line); ++ } ++} ++ ++static void ++block_handler(pointer data, struct timeval **tv, pointer read_mask) ++{ ++} ++ ++int ++config_devd_init(void) ++{ ++ struct sockaddr_un devd; ++ char devicename[1024]; ++ int i, j; ++ ++ /* first scan the sysctl to determine the hardware if needed */ ++ ++ for (i = 0; hw_types[i].driver != NULL; i++) { ++ for (j = 0; sysctl_exists("dev.%s.%i.%%desc", hw_types[i].driver, j); j++) { ++ snprintf(devicename, 1024, "%s%i", hw_types[i].driver, j); ++ device_added(devicename); ++ } ++ ++ } ++ sock_devd = socket(AF_UNIX, SOCK_STREAM, 0); ++ if (sock_devd < 0) { ++ ErrorF("config/devd: Fail opening stream socket"); ++ return 0; ++ } ++ ++ devd.sun_family = AF_UNIX; ++ strlcpy(devd.sun_path, DEVD_SOCK_PATH, sizeof(devd.sun_path)); ++ ++ if (connect(sock_devd, (struct sockaddr *) &devd, sizeof(struct sockaddr_un)) < 0) { ++ close(sock_devd); ++ ErrorF("config/devd: Fail to connect to devd"); ++ return 0; ++ } ++ ++ RegisterBlockAndWakeupHandlers(block_handler, wakeup_handler, NULL); ++ AddGeneralSocket(sock_devd); ++ ++ return 1; ++} ++ ++void ++config_devd_fini(void) ++{ ++ if (sock_devd < 0) ++ return; ++ ++ RemoveGeneralSocket(sock_devd); ++ RemoveBlockAndWakeupHandlers(block_handler, wakeup_handler, NULL); ++ close(sock_devd); ++} Property changes on: x11-servers/xorg-server/files/extra-config_devd.c ___________________________________________________________________ Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +FreeBSD=%H \ No newline at end of property Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Index: x11-servers/xorg-server/files/extra-configure =================================================================== --- x11-servers/xorg-server/files/extra-configure (revision 0) +++ x11-servers/xorg-server/files/extra-configure (working copy) @@ -0,0 +1,11 @@ +--- configure.orig 2013-09-07 22:11:27.210621324 +0200 ++++ configure 2013-09-07 22:11:52.912624338 +0200 +@@ -22839,7 +22839,7 @@ + } + _ACEOF + if ac_fn_c_try_compile "$LINENO"; then : +- ac_cv_tls=$kw ++ ac_cv_tls=$kw; break ; + fi + rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + done Property changes on: x11-servers/xorg-server/files/extra-configure ___________________________________________________________________ Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: x11-themes/gtk-murrine-engine/Makefile =================================================================== --- x11-themes/gtk-murrine-engine/Makefile (revision 328562) +++ x11-themes/gtk-murrine-engine/Makefile (working copy) @@ -3,6 +3,7 @@ PORTNAME= murrine PORTVERSION= 0.98.2 +PORTREVISION= 1 CATEGORIES= x11-themes MASTER_SITES= GNOME PKGNAMEPREFIX= gtk- @@ -11,14 +12,12 @@ MAINTAINER= pneumann@gmail.com COMMENT= Murrine GTK+ 2.x cairo based engine -LIB_DEPENDS= pixman-1:${PORTSDIR}/x11/pixman - USE_XZ= yes -USE_GMAKE= yes +USE_XORG= pixman USE_GNOME= gtk20 intltool intlhack USE_LDCONFIG= yes GNU_CONFIGURE= yes -USES= pkgconfig +USES= gmake pkgconfig OPTIONS_DEFINE= ANIMATION ANIMATION_DESC= Animation support Index: x11-toolkits/gtkglext/Makefile =================================================================== --- x11-toolkits/gtkglext/Makefile (revision 328562) +++ x11-toolkits/gtkglext/Makefile (working copy) @@ -3,7 +3,7 @@ PORTNAME= gtkglext PORTVERSION= 1.2.0 -PORTREVISION= 11 +PORTREVISION= 12 CATEGORIES= x11-toolkits MASTER_SITES= SF DIST_SUBDIR= gnome2 @@ -25,12 +25,11 @@ OPTIONS_DEFINE= DOCS USE_BZIP2= yes -USE_GMAKE= yes USE_AUTOTOOLS= libtool USE_XORG= ice pixman sm x11 xau xcb xcomposite xcursor xdamage xdmcp \ xext xfixes xi xinerama xmu xrandr xrender xt xxf86vm USE_GL= glu -USES= gettext iconv pathfix pkgconfig +USES= gettext gmake iconv pathfix pkgconfig USE_GNOME= gdkpixbuf2 gtk20 pangox-compat USE_LDCONFIG= yes Index: x11-toolkits/libXaw/Makefile =================================================================== --- x11-toolkits/libXaw/Makefile (revision 328562) +++ x11-toolkits/libXaw/Makefile (working copy) @@ -2,7 +2,7 @@ # $FreeBSD$ PORTNAME= libXaw -PORTVERSION= 1.0.11 +PORTVERSION= 1.0.12 PORTEPOCH= 2 CATEGORIES= x11-toolkits @@ -11,7 +11,7 @@ XORG_CAT= lib USE_XORG= printproto:both x11 xau xext xextproto xmu xp xpm xproto:both xt -USE_GMAKE= yes +USES= gmake CONFIGURE_ARGS+=--without-xmlto MAN3= Xaw.3 Index: x11-toolkits/libXaw/distinfo =================================================================== --- x11-toolkits/libXaw/distinfo (revision 328562) +++ x11-toolkits/libXaw/distinfo (working copy) @@ -1,2 +1,2 @@ -SHA256 (xorg/lib/libXaw-1.0.11.tar.bz2) = 87a874acbb71d1ee59b8047312fc91d89dcb373e2970f121184cdae29a3d9492 -SIZE (xorg/lib/libXaw-1.0.11.tar.bz2) = 649633 +SHA256 (xorg/lib/libXaw-1.0.12.tar.bz2) = 96fc314874fce9979556321d1d6ee00b5baf32fb333b7278853b4983bc3cdbf6 +SIZE (xorg/lib/libXaw-1.0.12.tar.bz2) = 677147 Index: x11-toolkits/libXmu/Makefile =================================================================== --- x11-toolkits/libXmu/Makefile (revision 328562) +++ x11-toolkits/libXmu/Makefile (working copy) @@ -2,7 +2,7 @@ # $FreeBSD$ PORTNAME= libXmu -PORTVERSION= 1.1.1 +PORTVERSION= 1.1.2 PORTEPOCH= 1 CATEGORIES= x11-toolkits Index: x11-toolkits/libXmu/distinfo =================================================================== --- x11-toolkits/libXmu/distinfo (revision 328562) +++ x11-toolkits/libXmu/distinfo (working copy) @@ -1,2 +1,2 @@ -SHA256 (xorg/lib/libXmu-1.1.1.tar.bz2) = 709081c550cc3a866d7c760a3f97384a1fe16e27fc38fe8169b8db9f33aa7edd -SIZE (xorg/lib/libXmu-1.1.1.tar.bz2) = 383473 +SHA256 (xorg/lib/libXmu-1.1.2.tar.bz2) = 756edc7c383254eef8b4e1b733c3bf1dc061b523c9f9833ac7058378b8349d0b +SIZE (xorg/lib/libXmu-1.1.2.tar.bz2) = 396230 Index: x11-wm/awesome/Makefile =================================================================== --- x11-wm/awesome/Makefile (revision 328562) +++ x11-wm/awesome/Makefile (working copy) @@ -3,7 +3,7 @@ PORTNAME= awesome PORTVERSION= 3.5.1 -PORTREVISION= 2 +PORTREVISION= 3 PORTEPOCH= 1 CATEGORIES= x11-wm MASTER_SITES= http://awesome.naquadah.org/download/