diff options
Diffstat (limited to 'dev-python/apsw')
-rw-r--r-- | dev-python/apsw/Manifest | 1 | ||||
-rw-r--r-- | dev-python/apsw/apsw-3.8.7.1_p1.ebuild | 55 | ||||
-rw-r--r-- | dev-python/apsw/files/apsw-3.6.20.1-fix_tests.patch | 11 | ||||
-rw-r--r-- | dev-python/apsw/metadata.xml | 13 |
4 files changed, 80 insertions, 0 deletions
diff --git a/dev-python/apsw/Manifest b/dev-python/apsw/Manifest new file mode 100644 index 000000000000..fb4a27c5e044 --- /dev/null +++ b/dev-python/apsw/Manifest @@ -0,0 +1 @@ +DIST apsw-3.8.7.1_p1.tar.gz 303446 SHA256 7aee29cc170332aa1a16fb80753152e809208bbc91823f64178e4afc32526fec SHA512 104aad3a8cec07647b71c77814cc069587daf84450b41f992d0b3c752c476105351b28912768a29f7952bfd75e9b2d3fcd8e6ae758b3bab8b986bf8e1300c256 WHIRLPOOL cc95728b07e384ee88002afce4b68abcfb259a62188cc77bad1154a83bf3e1979fec8761fe8a3c9e5ae35d5027cdf42c1b4a4b7749ad76d7935e032e253c8167 diff --git a/dev-python/apsw/apsw-3.8.7.1_p1.ebuild b/dev-python/apsw/apsw-3.8.7.1_p1.ebuild new file mode 100644 index 000000000000..72df5b5e0b85 --- /dev/null +++ b/dev-python/apsw/apsw-3.8.7.1_p1.ebuild @@ -0,0 +1,55 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=5 +PYTHON_COMPAT=( python{2_7,3_3,3_4} ) + +inherit distutils-r1 + +MY_PV=${PV/_p/-r} +MY_P=${PN}-${MY_PV} + +DESCRIPTION="APSW - Another Python SQLite Wrapper" +HOMEPAGE="http://code.google.com/p/apsw/" +HOMEPAGE="https://github.com/rogerbinns/apsw/" +SRC_URI="https://github.com/rogerbinns/apsw/archive/${MY_PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="ZLIB" +SLOT="0" +KEYWORDS="amd64 ~arm ~ppc64 x86" +IUSE="doc" + +RDEPEND=">=dev-db/sqlite-${PV%_p*}" +DEPEND="${RDEPEND} + app-arch/unzip" + +S=${WORKDIR}/${MY_P} + +PATCHES=( "${FILESDIR}"/${PN}-3.6.20.1-fix_tests.patch ) + +python_compile() { + if ! python_is_python3; then + local CFLAGS="${CFLAGS} -fno-strict-aliasing" + export CFLAGS + fi + distutils-r1_python_compile --enable=load_extension +} + +src_test() { + # tests use overlapping database files + local DISTUTILS_NO_PARALLEL_BUILD=1 + distutils-r1_src_test +} + +python_test() { + "${PYTHON}" setup.py build_test_extension || die "Building of test loadable extension failed" + "${PYTHON}" tests.py -v || die +} + +python_install_all() { + distutils-r1_python_install_all + if use doc ; then + dohtml -r doc/* + fi +} diff --git a/dev-python/apsw/files/apsw-3.6.20.1-fix_tests.patch b/dev-python/apsw/files/apsw-3.6.20.1-fix_tests.patch new file mode 100644 index 000000000000..3bbce88500be --- /dev/null +++ b/dev-python/apsw/files/apsw-3.6.20.1-fix_tests.patch @@ -0,0 +1,11 @@ +--- tests.py ++++ tests.py +@@ -5480,7 +5480,7 @@ + testnasty() + + # What happens if db cannot be opened? +- s.process_args(args=["/"]) ++ s.process_args(args=["src"]) + reset() + cmd("select * from sqlite_master;\n.bail on\nselect 3;\n") + self.assertRaises(apsw.CantOpenError, s.cmdloop) diff --git a/dev-python/apsw/metadata.xml b/dev-python/apsw/metadata.xml new file mode 100644 index 000000000000..ede09cb0f62a --- /dev/null +++ b/dev-python/apsw/metadata.xml @@ -0,0 +1,13 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <herd>python</herd> + <longdescription>APSW provides an SQLite 3 wrapper that provides the thinnest layer over SQLite 3 possible. +Everything you can do from the C API to SQLite 3, you can do from Python. +Although APSW looks vaguely similar to the DBAPI, it is not compliant with that API and instead +works the way SQLite 3 does.</longdescription> + <upstream> + <remote-id type="google-code">apsw</remote-id> + <remote-id type="github">rogerbinns/apsw</remote-id> + </upstream> +</pkgmetadata> |