update to 1.8.8
relax python 2.6 dependency fix regress prodded by and ok jasper@
This commit is contained in:
parent
d1ed51c9e8
commit
e74bb2d7f0
@ -1,17 +1,17 @@
|
||||
# $OpenBSD: Makefile,v 1.18 2009/08/10 06:31:45 kili Exp $
|
||||
# $OpenBSD: Makefile,v 1.19 2009/09/04 11:44:00 eric Exp $
|
||||
|
||||
COMMENT= cairo bindings for Python
|
||||
|
||||
VERSION= 1.8.2
|
||||
VERSION= 1.8.8
|
||||
DISTNAME= pycairo-${VERSION}
|
||||
PKGNAME= py-cairo-${VERSION}p1
|
||||
PKGNAME= py-cairo-${VERSION}
|
||||
CATEGORIES= graphics
|
||||
|
||||
HOMEPAGE= http://cairographics.org/pycairo/
|
||||
|
||||
MAINTAINER= Eric Faurot <eric@openbsd.org>
|
||||
|
||||
# LGPL
|
||||
# LGPLv2.1
|
||||
PERMIT_PACKAGE_CDROM= Yes
|
||||
PERMIT_PACKAGE_FTP= Yes
|
||||
PERMIT_DISTFILES_CDROM= Yes
|
||||
@ -19,21 +19,21 @@ PERMIT_DISTFILES_FTP= Yes
|
||||
|
||||
MASTER_SITES= http://cairographics.org/releases/
|
||||
|
||||
WANTLIB= X11 Xrender Xau Xdmcp expat fontconfig freetype glitz m \
|
||||
pixman-1 png pthread-stubs xcb z
|
||||
WANTLIB= X11 Xau Xdmcp Xrender expat fontconfig freetype glitz
|
||||
WANTLIB+= m pixman-1 png pthread-stubs xcb z
|
||||
|
||||
MODULES= lang/python
|
||||
LIB_DEPENDS= cairo.>=6::graphics/cairo
|
||||
LIB_DEPENDS= cairo::graphics/cairo
|
||||
USE_LIBTOOL= Yes
|
||||
USE_X11= Yes
|
||||
|
||||
CONFIGURE_STYLE=gnu
|
||||
|
||||
pre-install:
|
||||
perl -pi -e "s,!!MODPY_BIN!!,${MODPY_BIN}," ${WRKSRC}/test/test.test
|
||||
${SUBST_CMD} ${WRKSRC}/test/examples_test.py
|
||||
|
||||
do-regress: fake
|
||||
cd ${WRKSRC}/test && env PYTHONPATH=${WRKINST}${MODPY_SITEPKG} \
|
||||
${MODPY_BIN} ./test.py
|
||||
${MODPY_BIN} ./examples_test.py
|
||||
|
||||
.include <bsd.port.mk>
|
||||
|
@ -1,5 +1,5 @@
|
||||
MD5 (pycairo-1.8.2.tar.gz) = u/wML+8I37DFuLql8LZ6hw==
|
||||
RMD160 (pycairo-1.8.2.tar.gz) = zkimtxuALwfQ4NPPoUD9Oatf5Nc=
|
||||
SHA1 (pycairo-1.8.2.tar.gz) = tFeUnM+jr4Kvz/roo5ahyECpQoo=
|
||||
SHA256 (pycairo-1.8.2.tar.gz) = d6jL44j9ZoJQVnRPL8XFizr8JHdIvCx3d1HMDC6zCi8=
|
||||
SIZE (pycairo-1.8.2.tar.gz) = 519064
|
||||
MD5 (pycairo-1.8.8.tar.gz) = BU2mwSXLQnoAP1/WxU+FPg==
|
||||
RMD160 (pycairo-1.8.8.tar.gz) = 1+QL4GEUCZLgX3FLRRgsSYrhkxE=
|
||||
SHA1 (pycairo-1.8.8.tar.gz) = sSftWb2HbKD+XQzw9pc1g1xZnps=
|
||||
SHA256 (pycairo-1.8.8.tar.gz) = L1JZmUPKA8j/M2oOhLHIt08w4qPenLappCqTqEiDKGA=
|
||||
SIZE (pycairo-1.8.8.tar.gz) = 475651
|
||||
|
@ -1,7 +1,44 @@
|
||||
$OpenBSD: patch-configure,v 1.3 2009/02/16 14:48:53 eric Exp $
|
||||
--- configure.orig Thu Jan 15 10:37:36 2009
|
||||
+++ configure Tue Jan 20 10:53:17 2009
|
||||
@@ -20125,7 +20125,7 @@ $as_echo "$am_cv_python_pyexecdir" >&6; }
|
||||
$OpenBSD: patch-configure,v 1.4 2009/09/04 11:44:00 eric Exp $
|
||||
--- configure.orig Wed Aug 26 13:04:28 2009
|
||||
+++ configure Fri Sep 4 10:48:36 2009
|
||||
@@ -11107,13 +11107,13 @@ CC="$lt_save_CC"
|
||||
|
||||
if test -n "$PYTHON"; then
|
||||
# If the user set $PYTHON, use it and don't search something else.
|
||||
- { $as_echo "$as_me:$LINENO: checking whether $PYTHON version >= 2.6" >&5
|
||||
-$as_echo_n "checking whether $PYTHON version >= 2.6... " >&6; }
|
||||
+ { $as_echo "$as_me:$LINENO: checking whether $PYTHON version >= 2.5" >&5
|
||||
+$as_echo_n "checking whether $PYTHON version >= 2.5... " >&6; }
|
||||
prog="import sys
|
||||
# split strings by '.' and convert to numeric. Append some zeros
|
||||
# because we need at least 4 digits for the hex conversion.
|
||||
# map returns an iterator in Python 3.0 and a list in 2.x
|
||||
-minver = list(map(int, '2.6'.split('.'))) + [0, 0, 0]
|
||||
+minver = list(map(int, '2.5'.split('.'))) + [0, 0, 0]
|
||||
minverhex = 0
|
||||
# xrange is not present in Python 3.0 and range returns an iterator
|
||||
for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
|
||||
@@ -11135,8 +11135,8 @@ fi
|
||||
else
|
||||
# Otherwise, try each interpreter until we find one that satisfies
|
||||
# VERSION.
|
||||
- { $as_echo "$as_me:$LINENO: checking for a Python interpreter with version >= 2.6" >&5
|
||||
-$as_echo_n "checking for a Python interpreter with version >= 2.6... " >&6; }
|
||||
+ { $as_echo "$as_me:$LINENO: checking for a Python interpreter with version >= 2.5" >&5
|
||||
+$as_echo_n "checking for a Python interpreter with version >= 2.5... " >&6; }
|
||||
if test "${am_cv_pathless_PYTHON+set}" = set; then
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
@@ -11147,7 +11147,7 @@ else
|
||||
# split strings by '.' and convert to numeric. Append some zeros
|
||||
# because we need at least 4 digits for the hex conversion.
|
||||
# map returns an iterator in Python 3.0 and a list in 2.x
|
||||
-minver = list(map(int, '2.6'.split('.'))) + [0, 0, 0]
|
||||
+minver = list(map(int, '2.5'.split('.'))) + [0, 0, 0]
|
||||
minverhex = 0
|
||||
# xrange is not present in Python 3.0 and range returns an iterator
|
||||
for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[i]
|
||||
@@ -11321,7 +11321,7 @@ $as_echo "$am_cv_python_pyexecdir" >&6; }
|
||||
# Checks for libraries ---
|
||||
|
||||
# get rid of the -export-dynamic stuff from the configure flags ...
|
||||
|
40
graphics/py-cairo/patches/patch-test_examples_test_py
Normal file
40
graphics/py-cairo/patches/patch-test_examples_test_py
Normal file
@ -0,0 +1,40 @@
|
||||
$OpenBSD: patch-test_examples_test_py,v 1.1 2009/09/04 11:44:00 eric Exp $
|
||||
--- test/examples_test.py.orig Thu Aug 6 14:47:41 2009
|
||||
+++ test/examples_test.py Fri Sep 4 13:32:03 2009
|
||||
@@ -1,12 +1,8 @@
|
||||
'''test by running example scripts
|
||||
'''
|
||||
-from __future__ import division # new in 2.2, redundant in 3.0
|
||||
-from __future__ import absolute_import # new in 2.5, redundant in 2.7/3.0
|
||||
-from __future__ import print_function # new in 2.6, redundant in 3.0
|
||||
|
||||
import os
|
||||
import os.path
|
||||
-import subprocess
|
||||
|
||||
#import py.test as test
|
||||
|
||||
@@ -16,14 +12,17 @@ def test_examples():
|
||||
'''
|
||||
os.chdir(os.path.join(os.path.dirname(__file__), '..', 'examples'))
|
||||
for f in (x for x in os.listdir('.') if x.endswith('.py')):
|
||||
- retcode = subprocess.call('python %s' % f, shell=True)
|
||||
- assert retcode == 0, 'Error: {0} retcode == {1}'.format(f, retcode)
|
||||
+ os.system('${MODPY_BIN} %s' % f)
|
||||
|
||||
-
|
||||
-def test_snippets_png():
|
||||
+def test_snippets():
|
||||
'''run all snippets in png mode and check they exit successfully.
|
||||
'''
|
||||
os.chdir(os.path.join(os.path.dirname(__file__), '..', 'examples',
|
||||
'cairo_snippets'))
|
||||
- retcode = subprocess.call('python snippets_png.py -s', shell=True)
|
||||
- assert retcode == 0, 'Error: retcode == {0}'.format(retcode)
|
||||
+ os.system('${MODPY_BIN} snippets_png.py')
|
||||
+ os.system('${MODPY_BIN} snippets_ps.py')
|
||||
+ os.system('${MODPY_BIN} snippets_pdf.py')
|
||||
+ os.system('${MODPY_BIN} snippets_svg.py')
|
||||
+
|
||||
+test_examples()
|
||||
+test_snippets()
|
@ -1,18 +0,0 @@
|
||||
$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)
|
Loading…
Reference in New Issue
Block a user