aboutsummaryrefslogtreecommitdiffstats
path: root/graphics
diff options
context:
space:
mode:
authorpetef <petef@FreeBSD.org>2002-03-19 14:35:34 +0800
committerpetef <petef@FreeBSD.org>2002-03-19 14:35:34 +0800
commite9540688b353cd96cfcc0d16f7ddfb7f5da4f05a (patch)
treed35e8df83ab203a5199977e296e4acccd297ce12 /graphics
parentae3041359ba3d5f70096dcff4691a6e0cae09351 (diff)
downloadfreebsd-ports-gnome-e9540688b353cd96cfcc0d16f7ddfb7f5da4f05a.tar.gz
freebsd-ports-gnome-e9540688b353cd96cfcc0d16f7ddfb7f5da4f05a.tar.zst
freebsd-ports-gnome-e9540688b353cd96cfcc0d16f7ddfb7f5da4f05a.zip
Add py-graphviz 0.1, python interface to GraphViz agraph.
PR: 33159 Submitted by: Hye-Shik Chang <perky@fallin.lv>
Diffstat (limited to 'graphics')
-rw-r--r--graphics/Makefile1
-rw-r--r--graphics/py-graphviz/Makefile45
-rw-r--r--graphics/py-graphviz/distinfo3
-rw-r--r--graphics/py-graphviz/files/setup.py27
-rw-r--r--graphics/py-graphviz/pkg-comment1
-rw-r--r--graphics/py-graphviz/pkg-descr4
-rw-r--r--graphics/py-graphviz/pkg-plist4
7 files changed, 85 insertions, 0 deletions
diff --git a/graphics/Makefile b/graphics/Makefile
index 5f96fadc03a8..f641fe2e94af 100644
--- a/graphics/Makefile
+++ b/graphics/Makefile
@@ -255,6 +255,7 @@
SUBDIR += py-exif
SUBDIR += py-gd
SUBDIR += py-gdchart
+ SUBDIR += py-graphviz
SUBDIR += py-imaging
SUBDIR += py-imaging-handbook
SUBDIR += py-ming
diff --git a/graphics/py-graphviz/Makefile b/graphics/py-graphviz/Makefile
new file mode 100644
index 000000000000..d7fdce2c4315
--- /dev/null
+++ b/graphics/py-graphviz/Makefile
@@ -0,0 +1,45 @@
+# New ports collection makefile for: py-graphviz
+# Date created: 25 December 2001
+# Whom: Hye-Shik Chang <perky@fallin.lv>
+#
+# $FreeBSD$
+
+PORTNAME= graphviz
+PORTVERSION= 0.1
+CATEGORIES= graphics python
+MASTER_SITES= http://www.cs.brown.edu/~er/software/Agraph.py/ \
+ http://www.research.att.com/sw/tools/graphviz/dist/:gv
+PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
+DISTFILES= ${MODFILES} ${PORTNAME}-${GV_VERSION}.tgz:gv
+DIST_SUBDIR= ${PORTNAME}
+EXTRACT_ONLY= ${PORTNAME}-${GV_VERSION}.tgz
+
+MAINTAINER= perky@fallin.lv
+
+BUILD_DEPENDS= ${SWIG_CMD}:${PORTSDIR}/devel/SWIG
+
+NO_CDROM= "Can't be included in a commercial product"
+
+MODFILES= gv.i __init__.py
+WRKSRC= ${WRKDIR}/graphviz-${GV_VERSION}/agraph
+GV_VERSION?= 1.7.7
+
+USE_PYTHON= yes
+SWIG_CMD= ${LOCALBASE}/bin/swig
+PLIST_SUB= PYTHON_SITELIBDIR=${PYTHON_SITELIBDIR:S,^${LOCALBASE}/,,g}
+
+post-patch:
+ @${CP} ${DISTDIR}/graphviz/gv.i ${FILESDIR}/setup.py ${WRKSRC}
+ @${MKDIR} ${WRKSRC}/graphviz
+ @${CP} ${DISTDIR}/graphviz/__init__.py ${WRKSRC}/graphviz
+
+do-build:
+ @cd ${WRKSRC} && ( \
+ ${SWIG_CMD} -python gv.i; \
+ ${PYTHON_CMD} setup.py build; \
+ )
+
+do-install:
+ @cd ${WRKSRC} && ${PYTHON_CMD} setup.py install
+
+.include <bsd.port.mk>
diff --git a/graphics/py-graphviz/distinfo b/graphics/py-graphviz/distinfo
new file mode 100644
index 000000000000..3d1af5d81a17
--- /dev/null
+++ b/graphics/py-graphviz/distinfo
@@ -0,0 +1,3 @@
+MD5 (graphviz/gv.i) = d1aa60d521c7b80d2af05aa24189923b
+MD5 (graphviz/__init__.py) = a6338b4692d49ffff0635357a158714b
+MD5 (graphviz/graphviz-1.7.7.tgz) = e04a6031b34d07ebceacc6ccb0745eb5
diff --git a/graphics/py-graphviz/files/setup.py b/graphics/py-graphviz/files/setup.py
new file mode 100644
index 000000000000..8ffd3cea8a0a
--- /dev/null
+++ b/graphics/py-graphviz/files/setup.py
@@ -0,0 +1,27 @@
+# $FreeBSD$
+
+from distutils.core import setup, Extension
+
+VERSION = '"py-agraph 1.0"'
+agraph_srcs = [
+ 'apply.c', 'attr.c', 'edge.c', 'agerror.c', 'flatten.c',
+ 'grammar.c', 'graph.c', 'id.c', 'imap.c', 'io.c', 'mem.c',
+ 'node.c', 'obj.c', 'pend.c', 'rec.c', 'refstr.c', 'scan.c',
+ 'subg.c', 'utils.c', 'write.c'
+]
+cdt_srcs = [
+ 'dtclose.c', 'dtdisc.c', 'dtflatten.c', 'dthash.c', 'dtmethod.c',
+ 'dtopen.c', 'dtsize.c', 'dtextract.c', 'dtrestore.c', 'dtlist.c',
+ 'dtstat.c', 'dttree.c', 'dtview.c', 'dtrenew.c', 'dtwalk.c', 'dtstrhash.c'
+]
+cdt_srcs = ['../cdt/'+f for f in cdt_srcs]
+
+setup(name = 'graphviz',
+ version = '0.1',
+ description = 'Python Interface to GraphViz',
+ author = 'Manos Renieris',
+ packages = ['graphviz'],
+ ext_modules = [Extension('graphviz.graphviz', ['gv_wrap.c'] + cdt_srcs + agraph_srcs,
+ include_dirs=['../cdt', '.'],
+ define_macros=[('ulong','u_long'), ('VERSION', VERSION)])]
+)
diff --git a/graphics/py-graphviz/pkg-comment b/graphics/py-graphviz/pkg-comment
new file mode 100644
index 000000000000..beaa48446f3b
--- /dev/null
+++ b/graphics/py-graphviz/pkg-comment
@@ -0,0 +1 @@
+Python interface to GraphViz agraph
diff --git a/graphics/py-graphviz/pkg-descr b/graphics/py-graphviz/pkg-descr
new file mode 100644
index 000000000000..67d7eea04334
--- /dev/null
+++ b/graphics/py-graphviz/pkg-descr
@@ -0,0 +1,4 @@
+A Python interface to the agraph component of graphviz. This code is
+covered by the Brown Copyright.
+
+WWW: http://www.cs.brown.edu/~er/software/
diff --git a/graphics/py-graphviz/pkg-plist b/graphics/py-graphviz/pkg-plist
new file mode 100644
index 000000000000..2459e754815a
--- /dev/null
+++ b/graphics/py-graphviz/pkg-plist
@@ -0,0 +1,4 @@
+%%PYTHON_SITELIBDIR%%/graphviz/__init__.py
+%%PYTHON_SITELIBDIR%%/graphviz/__init__.pyc
+%%PYTHON_SITELIBDIR%%/graphviz/graphviz.so
+@dirrm %%PYTHON_SITELIBDIR%%/graphviz