aboutsummaryrefslogtreecommitdiffstats
path: root/graphics
diff options
context:
space:
mode:
authorgahr <gahr@FreeBSD.org>2013-01-15 00:39:46 +0800
committergahr <gahr@FreeBSD.org>2013-01-15 00:39:46 +0800
commit1049fb8c1dbff2767c954c270e58b2edfa6f1421 (patch)
treef070931fb6f6714a76c6025dc9fda885710424d0 /graphics
parent1d56e42c949af6140a51fd27176639f243812842 (diff)
downloadfreebsd-ports-gnome-1049fb8c1dbff2767c954c270e58b2edfa6f1421.tar.gz
freebsd-ports-gnome-1049fb8c1dbff2767c954c270e58b2edfa6f1421.tar.zst
freebsd-ports-gnome-1049fb8c1dbff2767c954c270e58b2edfa6f1421.zip
- Update to 9.0.1
Release notes: * 9.0 http://www.mesa3d.org/relnotes-9.0.html * 9.0.1 http://www.mesa3d.org/relnotes-9.0.1.html - This update includes the switch from autotools to SCons
Diffstat (limited to 'graphics')
-rw-r--r--graphics/libosmesa/Makefile68
-rw-r--r--graphics/libosmesa/distinfo4
-rw-r--r--graphics/libosmesa/files/patch-configure20
-rw-r--r--graphics/libosmesa/files/patch-scons_custom.py11
-rw-r--r--graphics/libosmesa/files/patch-scons_gallium.py30
-rw-r--r--graphics/libosmesa/files/patch-src-glu_Makefile14
-rw-r--r--graphics/libosmesa/files/patch-src-mesa_Makefile15
-rw-r--r--graphics/libosmesa/pkg-plist10
8 files changed, 93 insertions, 79 deletions
diff --git a/graphics/libosmesa/Makefile b/graphics/libosmesa/Makefile
index 1a333ed2fc86..cbd15b385b16 100644
--- a/graphics/libosmesa/Makefile
+++ b/graphics/libosmesa/Makefile
@@ -1,12 +1,8 @@
-# New ports collection makefile for: libosmesa
-# Date created: 9 April 2010
-# Whom: gahr
-#
+# Created by: gahr
# $FreeBSD$
-#
PORTNAME= libosmesa
-PORTVERSION= 8.0.4
+PORTVERSION= 9.0.1
CATEGORIES= graphics
MASTER_SITES= ftp://ftp.freedesktop.org/pub/mesa/${PORTVERSION}/
DISTNAME= MesaLib-${PORTVERSION}
@@ -14,28 +10,60 @@ DISTNAME= MesaLib-${PORTVERSION}
MAINTAINER= gahr@FreeBSD.org
COMMENT= Off-Screen Mesa implementation of the OpenGL API
-LIB_DEPENDS= expat.6:${PORTSDIR}/textproc/expat2 \
- talloc.2:${PORTSDIR}/devel/talloc
-BUILD_DEPENDS= makedepend:${PORTSDIR}/devel/makedepend \
- bison:${PORTSDIR}/devel/bison \
+LIB_DEPENDS= expat:${PORTSDIR}/textproc/expat2 \
+ talloc:${PORTSDIR}/devel/talloc
+BUILD_DEPENDS= bison:${PORTSDIR}/devel/bison \
+ ${LOCALBASE}/bin/flex:${PORTSDIR}/textproc/flex \
${PYTHON_SITELIBDIR}/libxml2mod.so:${PORTSDIR}/textproc/py-libxml2
CONFLICTS= mesagl-mangled-*
USE_BZIP2= yes
-USE_GCC= 4.2+
USE_LDCONFIG= yes
USE_GMAKE= yes
-USE_GNOME= pkgconfig gnomehack
USE_PYTHON= yes
-GNU_CONFIGURE= yes
-CONFIGURE_ARGS+=--with-driver=osmesa --with-osmesa-bits=32 \
- --with-gallium-drivers= --disable-asm \
- --disable-egl \
- --includedir=${PREFIX}/include/Mesa
-CFLAGS+= -I${LOCALBASE}/include -fPIC
-CPPFLAGS= ${CFLAGS}
+USE_SCONS= yes
+SCONS_TARGET= osmesa
+SCONS_ARGS+= build=release \
+ verbose=yes
+CCFLAGS+= -I${LOCALBASE}/include
+
+MAKE_JOBS_UNSAFE=
WRKSRC= ${WRKDIR}/Mesa-${PORTVERSION}
-.include <bsd.port.mk>
+.include <bsd.port.pre.mk>
+
+.if ${ARCH} == "i386"
+SCONS_ARGS+= machine=x86
+SCONS_BUILD_DIR=${WRKSRC}/build/freebsd-x86
+.elif ${ARCH} == "amd64"
+SCONS_ARGS+= machine=x86_64
+SCONS_BUILD_DIR=${WRKSRC}/build/freebsd-x86_64
+.endif
+
+INCLUDES= gl.h gl_mangle.h glext.h glx.h glx_mangle.h \
+ glxext.h osmesa.h wglext.h wmesa.h
+
+post-patch:
+ ${REINPLACE_CMD} -e 's|%%LOCALBASE%%|${LOCALBASE}|' ${WRKSRC}/scons/custom.py
+ ${REINPLACE_CMD} -e \
+ 's|@prefix@|${PREFIX}|; \
+ s|@libdir@|${PREFIX}/lib|; \
+ s|@includedir@|${PREFIX}/include/Mesa|; \
+ s|@OSMESA_VERSION@|${PORTVERSION}|; \
+ s|@OSMESA_LIB@|OSMesa|; \
+ s|@OSMESA_PC_REQ@||; \
+ s|@OSMESA_PC_LIB_PRIV@|-lm -pthread|' \
+ ${WRKSRC}/src/mesa/drivers/osmesa/osmesa.pc.in
+
+do-install:
+ ${MKDIR} ${PREFIX}/include/Mesa/GL
+.for inc in ${INCLUDES}
+ ${INSTALL_DATA} ${WRKSRC}/include/GL/${inc} ${PREFIX}/include/Mesa/GL/
+.endfor
+ ${INSTALL_DATA} ${SCONS_BUILD_DIR}/mesa/drivers/osmesa/libosmesa.so ${PREFIX}/lib/libOSMesa.so.9
+ ${LN} -sf libOSMesa.so.9 ${PREFIX}/lib/libOSMesa.so
+ ${INSTALL_DATA} ${WRKSRC}/src/mesa/drivers/osmesa/osmesa.pc.in ${PREFIX}/libdata/pkgconfig/osmesa.pc
+
+.include <bsd.port.post.mk>
diff --git a/graphics/libosmesa/distinfo b/graphics/libosmesa/distinfo
index 5e1e37e259c8..2f1d4f2f27c2 100644
--- a/graphics/libosmesa/distinfo
+++ b/graphics/libosmesa/distinfo
@@ -1,2 +1,2 @@
-SHA256 (MesaLib-8.0.4.tar.bz2) = 02ed19f4f5f6535dda03a9932a81438aa78ea723ebba1f39a3d49a70a4e1d07e
-SIZE (MesaLib-8.0.4.tar.bz2) = 5737052
+SHA256 (MesaLib-9.0.1.tar.bz2) = 57a7ba83bace3f3a7dc0929fe026ef5f0ad454234ec4ad8a3e0d31650a75db6f
+SIZE (MesaLib-9.0.1.tar.bz2) = 6115959
diff --git a/graphics/libosmesa/files/patch-configure b/graphics/libosmesa/files/patch-configure
deleted file mode 100644
index 33e2f5c01951..000000000000
--- a/graphics/libosmesa/files/patch-configure
+++ /dev/null
@@ -1,20 +0,0 @@
---- configure.orig 2012-03-01 17:25:51.000000000 +0100
-+++ configure 2012-03-01 17:27:33.000000000 +0100
-@@ -6275,7 +6275,7 @@
- fi
-
- GL_LIB="GL"
--GLU_LIB="GLU"
-+GLU_LIB="OSGLU"
- OSMESA_LIB="OSMesa"
- if test "x${enable_mangling}" = "xyes" ; then
- DEFINES="${DEFINES} -DUSE_MGL_NAMESPACE"
-@@ -6384,7 +6384,7 @@
- ;;
- esac
- ;;
-- x86_64)
-+ amd64)
- case "$host_os" in
- linux* | *freebsd* | dragonfly* | *netbsd*)
- test "x$enable_32bit" = xyes && asm_arch=x86 || asm_arch=x86_64
diff --git a/graphics/libosmesa/files/patch-scons_custom.py b/graphics/libosmesa/files/patch-scons_custom.py
new file mode 100644
index 000000000000..1e7e2bc2cd63
--- /dev/null
+++ b/graphics/libosmesa/files/patch-scons_custom.py
@@ -0,0 +1,11 @@
+--- scons/custom.py.orig 2012-10-10 16:32:44.000000000 +0200
++++ scons/custom.py 2012-10-10 16:32:29.000000000 +0200
+@@ -301,6 +301,8 @@
+ createPkgConfigMethods(env)
+ createParseSourceListMethod(env)
+
++ env['LEX'] = '%%LOCALBASE%%/bin/flex'
++
+ # for debugging
+ #print env.Dump()
+
diff --git a/graphics/libosmesa/files/patch-scons_gallium.py b/graphics/libosmesa/files/patch-scons_gallium.py
new file mode 100644
index 000000000000..6d9dc0003e66
--- /dev/null
+++ b/graphics/libosmesa/files/patch-scons_gallium.py
@@ -0,0 +1,30 @@
+--- scons/gallium.py.orig 2012-11-09 19:16:31.000000000 +0100
++++ scons/gallium.py 2013-01-14 17:25:58.000000000 +0100
+@@ -246,11 +246,11 @@
+ cppdefines += ['PROFILE']
+ if env['platform'] in ('posix', 'linux', 'freebsd', 'darwin'):
+ cppdefines += [
+- '_POSIX_SOURCE',
+- ('_POSIX_C_SOURCE', '199309L'),
+- '_SVID_SOURCE',
+- '_BSD_SOURCE',
+- '_GNU_SOURCE',
++# '_POSIX_SOURCE',
++# ('_POSIX_C_SOURCE', '199309L'),
++# '_SVID_SOURCE',
++# '_BSD_SOURCE',
++# '_GNU_SOURCE',
+ 'HAVE_PTHREAD',
+ 'HAVE_POSIX_MEMALIGN',
+ ]
+@@ -499,7 +499,9 @@
+ # Default libs
+ libs = []
+ if env['platform'] in ('darwin', 'freebsd', 'linux', 'posix', 'sunos'):
+- libs += ['m', 'pthread', 'dl']
++ libs += ['m', 'pthread']
++ if env['platform'] != 'freebsd':
++ libs += ['dl']
+ env.Append(LIBS = libs)
+
+ # OpenMP
diff --git a/graphics/libosmesa/files/patch-src-glu_Makefile b/graphics/libosmesa/files/patch-src-glu_Makefile
deleted file mode 100644
index 6d9c1ecc8658..000000000000
--- a/graphics/libosmesa/files/patch-src-glu_Makefile
+++ /dev/null
@@ -1,14 +0,0 @@
---- src/glu/Makefile.orig 2010-02-05 01:10:40.000000000 +0100
-+++ src/glu/Makefile 2011-08-04 10:48:42.000000000 +0200
-@@ -29,9 +29,9 @@
-
- install: glu.pc
- $(INSTALL) -d $(DESTDIR)$(INSTALL_LIB_DIR)
-- $(INSTALL) -d $(DESTDIR)$(INSTALL_LIB_DIR)/pkgconfig
-+ $(INSTALL) -d $(DESTDIR)$(prefix)/libdata/pkgconfig
- $(MINSTALL) $(TOP)/$(LIB_DIR)/$(GLU_LIB_GLOB) $(DESTDIR)$(INSTALL_LIB_DIR)
-- $(INSTALL) -m 644 glu.pc $(DESTDIR)$(INSTALL_LIB_DIR)/pkgconfig
-+ $(INSTALL) -m 644 glu.pc $(DESTDIR)$(prefix)/libdata/pkgconfig/osglu.pc
-
- clean:
- -@for dir in $(SUBDIRS) ; do \
diff --git a/graphics/libosmesa/files/patch-src-mesa_Makefile b/graphics/libosmesa/files/patch-src-mesa_Makefile
deleted file mode 100644
index 816cbab18bad..000000000000
--- a/graphics/libosmesa/files/patch-src-mesa_Makefile
+++ /dev/null
@@ -1,15 +0,0 @@
---- src/mesa/Makefile.orig 2011-08-04 10:47:51.000000000 +0200
-+++ src/mesa/Makefile 2011-08-04 10:48:17.000000000 +0200
-@@ -191,10 +191,10 @@
-
- install-osmesa: default osmesa.pc
- $(INSTALL) -d $(DESTDIR)$(INSTALL_LIB_DIR)
-- $(INSTALL) -d $(DESTDIR)$(INSTALL_LIB_DIR)/pkgconfig
-+ $(INSTALL) -d $(DESTDIR)$(prefix)/libdata/pkgconfig
- $(MINSTALL) $(TOP)/$(LIB_DIR)/$(OSMESA_LIB_GLOB) \
- $(DESTDIR)$(INSTALL_LIB_DIR)
-- $(INSTALL) -m 644 osmesa.pc $(DESTDIR)$(INSTALL_LIB_DIR)/pkgconfig
-+ $(INSTALL) -m 644 osmesa.pc $(DESTDIR)$(prefix)/libdata/pkgconfig
-
- install-dri: default
- cd drivers/dri && $(MAKE) install
diff --git a/graphics/libosmesa/pkg-plist b/graphics/libosmesa/pkg-plist
index 1c109bd03157..8789853da87f 100644
--- a/graphics/libosmesa/pkg-plist
+++ b/graphics/libosmesa/pkg-plist
@@ -1,20 +1,14 @@
include/Mesa/GL/gl.h
include/Mesa/GL/gl_mangle.h
include/Mesa/GL/glext.h
-include/Mesa/GL/glu.h
-include/Mesa/GL/glu_mangle.h
include/Mesa/GL/glx.h
include/Mesa/GL/glx_mangle.h
include/Mesa/GL/glxext.h
include/Mesa/GL/osmesa.h
-include/Mesa/GL/vms_x_fix.h
include/Mesa/GL/wglext.h
include/Mesa/GL/wmesa.h
-lib/libOSGLU.so
-lib/libOSGLU.so.1
-lib/libOSMesa32.so
-lib/libOSMesa32.so.8
+lib/libOSMesa.so
+lib/libOSMesa.so.9
libdata/pkgconfig/osmesa.pc
-libdata/pkgconfig/osglu.pc
@dirrm include/Mesa/GL
@dirrm include/Mesa