- update to 1.2.6; it seems that py-cairo version has to be in sync with

cairo's in order to work correctly
- use USE_LIBTOOL
- add do-regress target

ok maintainer
This commit is contained in:
alek 2007-03-26 20:32:11 +00:00
parent 76c417cc36
commit 2da69f2551
6 changed files with 45 additions and 20 deletions

View File

@ -1,11 +1,11 @@
# $OpenBSD: Makefile,v 1.8 2007/02/11 00:56:57 steven Exp $
# $OpenBSD: Makefile,v 1.9 2007/03/26 20:32:11 alek Exp $
SHARED_ONLY= Yes
COMMENT= "cairo bindings for Python"
DISTNAME= pycairo-1.0.2
PKGNAME= ${DISTNAME:S/py/py-/}p3
DISTNAME= pycairo-1.2.6
PKGNAME= ${DISTNAME:S/py/py-/}
CATEGORIES= graphics
HOMEPAGE= http://cairographics.org/introduction/
@ -26,11 +26,18 @@ MODULES= lang/python
LIB_DEPENDS= cairo.>=4::graphics/cairo
RUN_DEPENDS= :py-Numeric-*:math/py-Numeric
BUILD_DEPENDS= ${RUN_DEPENDS}
#USE_LIBTOOL= Yes
USE_LIBTOOL= Yes
USE_X11= Yes
CONFIGURE_STYLE=gnu
CONFIGURE_ARGS= --without-pygtk
CONFIGURE_ENV=PYTHON=${LOCALBASE}/bin/python${MODPY_VERSION}
CONFIGURE_ENV= PYTHON=${MODPY_BIN}
pre-install:
perl -pi -e "s,!!MODPY_BIN!!,${MODPY_BIN}," ${WRKSRC}/test/test.test
do-regress: fake
cd ${WRKSRC}/test && env PYTHONPATH=${WRKINST}${MODPY_SITEPKG} \
${MODPY_BIN} ./test.py
.include <bsd.port.mk>

View File

@ -1,4 +1,5 @@
MD5 (pycairo-1.0.2.tar.gz) = 5bb6a202ebc3990712bced1da6dfb7a8
RMD160 (pycairo-1.0.2.tar.gz) = d7e7db5271f756e045a9140389fe0b4136136d6a
SHA1 (pycairo-1.0.2.tar.gz) = 92b51f670aaba03ac372dc2999e715bc5281f5e5
SIZE (pycairo-1.0.2.tar.gz) = 469704
MD5 (pycairo-1.2.6.tar.gz) = 166b04c4800c01aba1a6c8b14e87e0bc
RMD160 (pycairo-1.2.6.tar.gz) = 7b46efa78fd3c303aa7a011bf5ecbe713255edac
SHA1 (pycairo-1.2.6.tar.gz) = 42e9ae64d2be59e46e503e52d35c71506527b3e9
SHA256 (pycairo-1.2.6.tar.gz) = 28f01729946721bec2361480f2802da5015e1271ce5cdbe6ff97a1442a19c595
SIZE (pycairo-1.2.6.tar.gz) = 480714

View File

@ -1,7 +1,7 @@
$OpenBSD: patch-cairo_pycairo-font_c,v 1.1 2006/02/05 01:59:03 pvalchev Exp $
--- cairo/pycairo-font.c.orig Sat Feb 4 17:10:21 2006
+++ cairo/pycairo-font.c Sat Feb 4 17:10:22 2006
@@ -196,6 +196,7 @@ scaled_font_new (PyTypeObject *type, PyO
$OpenBSD: patch-cairo_pycairo-font_c,v 1.2 2007/03/26 20:32:11 alek Exp $
--- cairo/pycairo-font.c.orig Sun Mar 25 21:17:08 2007
+++ cairo/pycairo-font.c Sun Mar 25 21:18:57 2007
@@ -197,6 +197,7 @@ scaled_font_new (PyTypeObject *type, PyO
PycairoFontFace *ff;
PycairoFontOptions *fo;
PycairoMatrix *mx1, *mx2;
@ -9,12 +9,12 @@ $OpenBSD: patch-cairo_pycairo-font_c,v 1.1 2006/02/05 01:59:03 pvalchev Exp $
if (!PyArg_ParseTuple(args, "O!O!O!O!:ScaledFont.__new__",
&PycairoFontFace_Type, &ff,
@@ -204,7 +205,7 @@ scaled_font_new (PyTypeObject *type, PyO
@@ -205,7 +206,7 @@ scaled_font_new (PyTypeObject *type, PyO
&PycairoFontOptions_Type, &fo))
return NULL;
- PyObject *o = type->tp_alloc(type, 0);
+ o = type->tp_alloc(type, 0);
if (o) {
if (o != NULL) {
cairo_scaled_font_t *scaled_font = cairo_scaled_font_create
(ff->font_face, &mx1->matrix, &mx2->matrix, fo->font_options);

View File

@ -0,0 +1,18 @@
$OpenBSD: patch-test_test_test,v 1.1 2007/03/26 20:32:11 alek Exp $
--- test/test.test.orig Sun Mar 25 19:33:35 2007
+++ test/test.test Sun Mar 25 19:33:54 2007
@@ -9,12 +9,12 @@
>>> os.chdir (_dir)
>>> files = [f for f in os.listdir('.') if f.endswith('.py')]
>>> for f in files:
-... ret = os.system ('python %s' % f) # return value is system dependent
+... ret = os.system ('!!MODPY_BIN!! %s' % f) # return value is system dependent
... if ret != 0 and sys.platform.startswith('linux'):
... print 'Error:', f, 'returned', ret
# run png snippets
->>> cmd = 'python snippets_png.py -s'
+>>> cmd = '!!MODPY_BIN!! snippets_png.py -s'
>>> _dir = os.path.join(cwd, '..', 'examples', 'cairo_snippets')
>>> os.chdir (_dir)
>>> ret = os.system (cmd)

View File

@ -1,3 +0,0 @@
@comment $OpenBSD: PFRAG.shared,v 1.2 2006/06/27 19:12:13 naddy Exp $
lib/python${MODPY_VERSION}/site-packages/cairo/_cairo.so
@comment lib/python${MODPY_VERSION}/site-packages/cairo/_cairo.la

View File

@ -1,5 +1,4 @@
@comment $OpenBSD: PLIST,v 1.2 2006/06/27 19:12:13 naddy Exp $
%%SHARED%%
@comment $OpenBSD: PLIST,v 1.3 2007/03/26 20:32:11 alek Exp $
include/pycairo/
include/pycairo/pycairo.h
lib/pkgconfig/pycairo.pc
@ -7,3 +6,6 @@ lib/python${MODPY_VERSION}/site-packages/cairo/
lib/python${MODPY_VERSION}/site-packages/cairo/__init__.py
lib/python${MODPY_VERSION}/site-packages/cairo/__init__.pyc
lib/python${MODPY_VERSION}/site-packages/cairo/__init__.pyo
@comment lib/python${MODPY_VERSION}/site-packages/cairo/_cairo.a
@comment lib/python${MODPY_VERSION}/site-packages/cairo/_cairo.la
lib/python${MODPY_VERSION}/site-packages/cairo/_cairo.so