aboutsummaryrefslogtreecommitdiff
path: root/graphics
diff options
context:
space:
mode:
authorNicola Vitale <nivit@FreeBSD.org>2012-09-19 21:31:28 +0000
committerNicola Vitale <nivit@FreeBSD.org>2012-09-19 21:31:28 +0000
commit5305160a22515f778f53d1b41d78581271e7834e (patch)
treefa0d02f5273b59dd3e773ab4e33d6f988aa680e7 /graphics
parentf8a5c03fc80110c7ca49b67543d368d7f2d55ca2 (diff)
downloadports-5305160a22515f778f53d1b41d78581271e7834e.tar.gz
ports-5305160a22515f778f53d1b41d78581271e7834e.zip
Notes
Diffstat (limited to 'graphics')
-rw-r--r--graphics/py-stl/Makefile48
-rw-r--r--graphics/py-stl/distinfo4
-rw-r--r--graphics/py-stl/pkg-descr6
-rw-r--r--graphics/py-stl/pkg-plist2
4 files changed, 37 insertions, 23 deletions
diff --git a/graphics/py-stl/Makefile b/graphics/py-stl/Makefile
index 913e5ff518b3..02842f20a17b 100644
--- a/graphics/py-stl/Makefile
+++ b/graphics/py-stl/Makefile
@@ -1,41 +1,55 @@
-# New ports collection makefile for: py-stl
-# Date created: 28 Dec 2011
-# Whom: rsmith@xs4all.nl
-#
+# Created by: Roland Smith <rsmith@xs4all.nl>
# $FreeBSD$
PORTNAME= stl
-PORTVERSION= 3.0
+PORTVERSION= 3.1
CATEGORIES= graphics python
MASTER_SITES= http://rsmith.home.xs4all.nl/software/
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
-DISTNAME= py-${PORTNAME}-${GITVER}
+DISTNAME= py-${PORTNAME}-${PORTVERSION}
MAINTAINER= rsmith@xs4all.nl
COMMENT= Converts STL models to POV-Ray meshes or PostScript/PDF images
-RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}reportlab2>2:${PORTSDIR}/print/py-reportlab2
+LICENSE= BSD
-GITVER= 31a5b12
+# bypass infrastructure bug
+OPTIONSFILE= ${PORT_DBDIR}/py-${PORTNAME}/options
USE_ZIP= YES
USE_PYTHON= 2.5+
USE_PYDISTUTILS= YES
+PYDISTUTILS_EGGINFO= py_stl-${PORTVERSION}-py${PYTHON_VER}.egg-info
CONFLICTS= stl2pov-[0-9]*
-MAN1= stl2ps.1 stlinfo.1 stl2pdf.1
+MAN1= stl2ps.1 stlinfo.1 stl2pov.1
+
+OPTIONS_DEFINE= PYCAIRO
+PYCAIRO_DESC= Use (py)Cairo to enable stl2pdf
+
+.include <bsd.port.options.mk>
+
+STL_SCRIPTS= stl2pov stl2ps stlinfo
+
+.if ${PORT_OPTIONS:MPYCAIRO}
+RUN_DEPENDS+= ${PYTHON_PKGNAMEPREFIX}cairo>1.8:${PORTSDIR}/graphics/py-cairo
+MAN1+= stl2pdf.1
+PLIST_SUB= STL2PDF=""
+STL_SCRIPTS+= stl2pdf
+.else
+PLIST_SUB= STL2PDF="@comment "
+.endif
NO_BUILD= YES
post-install:
- @${INSTALL_MAN} ${WRKSRC}/stl2ps.1 ${MANPREFIX}/man/man1
- @${INSTALL_MAN} ${WRKSRC}/stlinfo.1 ${MANPREFIX}/man/man1
- @${INSTALL_MAN} ${WRKSRC}/stl2pdf.1 ${MANPREFIX}/man/man1
- @${MV} ${PREFIX}/bin/stl2ps.py ${PREFIX}/bin/stl2ps
- @${MV} ${PREFIX}/bin/stl2pov.py ${PREFIX}/bin/stl2pov
- @${MV} ${PREFIX}/bin/stlinfo.py ${PREFIX}/bin/stlinfo
- @${MV} ${PREFIX}/bin/stl2pdf.py ${PREFIX}/bin/stl2pdf
- @${MV} ${PYTHON_SITELIBDIR}/py_stl-${GITVER}-py${PYTHON_VER}.egg-info ${PYTHON_SITELIBDIR}/${PYDISTUTILS_EGGINFO}
+.if empty(PORT_OPTIONS:MPYCAIRO)
+ @${RM} -f ${PREFIX}/bin/stl2pdf.py
+.endif
+.for s in ${STL_SCRIPTS}
+ ${INSTALL_MAN} ${WRKSRC}/${s}.1 ${MANPREFIX}/man/man1
+ @${MV} ${PREFIX}/bin/${s}.py ${PREFIX}/bin/${s}
+.endfor
.include <bsd.port.mk>
diff --git a/graphics/py-stl/distinfo b/graphics/py-stl/distinfo
index 7d36a5e5ed74..bbc24adfd142 100644
--- a/graphics/py-stl/distinfo
+++ b/graphics/py-stl/distinfo
@@ -1,2 +1,2 @@
-SHA256 (py-stl-31a5b12.zip) = 117bd90aeea8aea6febe8b154b5ee9590cf0cec9a129023db31c122d7f595269
-SIZE (py-stl-31a5b12.zip) = 93478
+SHA256 (py-stl-3.1.zip) = d5a2eccbd627d05b28d3b6d619202d3a55b4d94dbf21a63b68109688ebc8e929
+SIZE (py-stl-3.1.zip) = 115488
diff --git a/graphics/py-stl/pkg-descr b/graphics/py-stl/pkg-descr
index 2dea5fd8243f..27b389161854 100644
--- a/graphics/py-stl/pkg-descr
+++ b/graphics/py-stl/pkg-descr
@@ -1,11 +1,11 @@
The python modules stl.py and xform.py are for reading, creating and
transforming STL (STereoLithography) files. These modules are used by the
-following scripts;
+following scripts:
stl2pov: Converts the STL model to a mesh usable with the POV-ray raytracer.
stl2ps: Creates a view of the STL model in scalable PostScript.
-stl2pdf: Creates a view of the STL model as a PDF. Requires print/py-reportlab2
+stl2pdf: Creates a view of the STL model as a PDF. Requires graphics/py-cairo
sltinfo: Either displays some information about a STL file or prints it in
- text format.
+text format.
WWW: http://rsmith.home.xs4all.nl/software/index.html
diff --git a/graphics/py-stl/pkg-plist b/graphics/py-stl/pkg-plist
index d13e79eee148..d28cb76238b3 100644
--- a/graphics/py-stl/pkg-plist
+++ b/graphics/py-stl/pkg-plist
@@ -4,7 +4,7 @@
%%PYTHON_SITELIBDIR%%/xform.py
%%PYTHON_SITELIBDIR%%/xform.pyc
%%PYTHON_SITELIBDIR%%/xform.pyo
-bin/stl2pdf
+%%STL2PDF%%bin/stl2pdf
bin/stl2pov
bin/stl2ps
bin/stlinfo