summaryrefslogtreecommitdiff
path: root/graphics/py-paint
diff options
context:
space:
mode:
authorKevin Lo <kevlo@FreeBSD.org>2001-07-08 16:47:15 +0000
committerKevin Lo <kevlo@FreeBSD.org>2001-07-08 16:47:15 +0000
commitbb8b021e51c49dc5abd9c24ca914766520641026 (patch)
tree966b9ea93f69d08ca05b5ed80cb562fe9c96c1f1 /graphics/py-paint
parentInitial import of libart-2.3.3. (diff)
Initial import of py-paint 0.1.
The paint module provides a simple and flexible facility for painting PNG images files. The paint module depends upon three free libraries: freetype, libart, libpng. PR: 28819 Submitted by: Hye-Shik Chang <perky@python.or.kr>
Notes
Notes: svn path=/head/; revision=44934
Diffstat (limited to 'graphics/py-paint')
-rw-r--r--graphics/py-paint/Makefile57
-rw-r--r--graphics/py-paint/distinfo1
-rw-r--r--graphics/py-paint/files/optpatch-aa12
-rw-r--r--graphics/py-paint/pkg-comment1
-rw-r--r--graphics/py-paint/pkg-descr5
-rw-r--r--graphics/py-paint/pkg-plist5
6 files changed, 81 insertions, 0 deletions
diff --git a/graphics/py-paint/Makefile b/graphics/py-paint/Makefile
new file mode 100644
index 000000000000..ec391c0a3c55
--- /dev/null
+++ b/graphics/py-paint/Makefile
@@ -0,0 +1,57 @@
+# New ports collection makefile for: py-paint
+# Date created: 8 July 2001
+# Whom: Hye-Shik Chang <perky@python.or.kr>
+#
+# $FreeBSD$
+#
+
+PORTNAME= paint
+PORTVERSION= 0.1
+CATEGORIES= graphics python
+MASTER_SITES= http://object-craft.com.au/projects/paint/
+PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
+
+MAINTAINER= perky@python.or.kr
+
+BUILD_DEPENDS= ${PYDISTUTILS}
+LIB_DEPENDS= ttf.4:${PORTSDIR}/print/freetype \
+ png.4:${PORTSDIR}/graphics/png \
+ art_lgpl.5:${PORTSDIR}/graphics/libart
+
+USE_PYTHON= yes
+PLIST_SUB+= PYTHON_SITELIBDIR=${PYTHON_SITELIBDIR:S,^${LOCALBASE}/,,g} \
+ SHARE_SUBDIR=${SHARE_SUBDIR}
+WRKSRC= ${WRKDIR}/${PORTNAME}
+SHARE_SUBDIR= ${PKGNAMEPREFIX}${PORTNAME}
+PYDIST_SETUP= cd ${WRKSRC} && ${PYTHON_CMD} setup.py
+
+INC_DIRS= ["${LOCALBASE}/include","${LOCALBASE}/include/freetype"]
+LIB_DIRS= ["${LOCALBASE}/lib"]
+REPATCH= cd ${WRKSRC} && ${SED}
+REPATCHSUBST= -e 's@^\(.*libraries.*\)$$@\1include_dirs=${INC_DIRS},library_dirs=${LIB_DIRS},@g'
+REPATCHFILES= setup.py
+TMPSUFFIX= .temp
+EXAMPLES= test_bar.py test_paint.py testpie.py
+
+.include <bsd.port.pre.mk>
+
+post-patch:
+.if ${PYTHON_REL} >= 160
+ cd ${WRKSRC} && ${PATCH} -s <${PATCHDIR}/optpatch-aa
+.endif
+.for file in ${REPATCHFILES}
+ ${REPATCH} ${REPATCHSUBST} ${file} > ${file}${TMPSUFFIX} && \
+ ${CAT} ${file}${TMPSUFFIX} > ${file}
+.endfor
+
+do-build:
+ ${PYDIST_SETUP} build
+
+do-install:
+ ${PYDIST_SETUP} install
+.if !defined(NOPORTDOCS)
+ ${MKDIR} ${PREFIX}/share/examples/${SHARE_SUBDIR}
+ cd ${WRKSRC} && ${INSTALL_DATA} ${EXAMPLES} ${PREFIX}/share/examples/${SHARE_SUBDIR}
+.endif
+
+.include <bsd.port.post.mk>
diff --git a/graphics/py-paint/distinfo b/graphics/py-paint/distinfo
new file mode 100644
index 000000000000..f5cb901b8de5
--- /dev/null
+++ b/graphics/py-paint/distinfo
@@ -0,0 +1 @@
+MD5 (paint-0.1.tar.gz) = 0021c2e7bbbe82ba2f31e44192b1abfb
diff --git a/graphics/py-paint/files/optpatch-aa b/graphics/py-paint/files/optpatch-aa
new file mode 100644
index 000000000000..2fadcd45df3a
--- /dev/null
+++ b/graphics/py-paint/files/optpatch-aa
@@ -0,0 +1,12 @@
+--- paint.h.orig Thu May 10 10:12:07 2001
++++ paint.h Mon Jul 9 00:01:22 2001
+@@ -39,6 +39,9 @@
+ #include <libart_lgpl/art_svp_vpath_stroke.h>
+
+ #include "Python.h"
++#define Py_Malloc(n) PyMem_Malloc(n)
++#define Py_Realloc(p, n) PyMem_Realloc((p), (n))
++#define Py_Free(p) PyMem_Free(p)
+
+ typedef struct {
+ PyObject_HEAD
diff --git a/graphics/py-paint/pkg-comment b/graphics/py-paint/pkg-comment
new file mode 100644
index 000000000000..e624d200c72f
--- /dev/null
+++ b/graphics/py-paint/pkg-comment
@@ -0,0 +1 @@
+Simple and flexible painting adaptor to libart for Python
diff --git a/graphics/py-paint/pkg-descr b/graphics/py-paint/pkg-descr
new file mode 100644
index 000000000000..1710ae72e0e3
--- /dev/null
+++ b/graphics/py-paint/pkg-descr
@@ -0,0 +1,5 @@
+The paint module provides a simple and flexible facility for
+painting PNG images files. The paint module depends upon
+three free libraries: freetype, libart, libpng.
+
+WWW: http://object-craft.com.au/projects/paint/
diff --git a/graphics/py-paint/pkg-plist b/graphics/py-paint/pkg-plist
new file mode 100644
index 000000000000..c6b01fa807aa
--- /dev/null
+++ b/graphics/py-paint/pkg-plist
@@ -0,0 +1,5 @@
+%%PYTHON_SITELIBDIR%%/paint.so
+%%PORTDOCS%%share/examples/%%SHARE_SUBDIR%%/test_bar.py
+%%PORTDOCS%%share/examples/%%SHARE_SUBDIR%%/test_paint.py
+%%PORTDOCS%%share/examples/%%SHARE_SUBDIR%%/testpie.py
+%%PORTDOCS%%@dirrm share/examples/%%SHARE_SUBDIR%%