diff options
Diffstat (limited to 'dev-python/psycopg')
-rw-r--r-- | dev-python/psycopg/Manifest | 2 | ||||
-rw-r--r-- | dev-python/psycopg/psycopg-2.8.6.ebuild | 65 |
2 files changed, 67 insertions, 0 deletions
diff --git a/dev-python/psycopg/Manifest b/dev-python/psycopg/Manifest index 948be0c8d3a9..0d1e2a876f1b 100644 --- a/dev-python/psycopg/Manifest +++ b/dev-python/psycopg/Manifest @@ -2,6 +2,8 @@ AUX psycopg-2.7.3-avoid-mxdatetime.patch 1832 BLAKE2B dff21302f85dc05be27147d1a5 AUX psycopg-2.8.3-avoid-mxdatetime.patch 954 BLAKE2B 073eca8e49dd4d7fd2ec920dfe52e255d3fbb0e9975cd0378574d7c6f6f097c4b0bae0f4eba74e939b15c19ccab1dbe84d28f434830d38db6b59e18246c3f2c2 SHA512 9e0ac41a70002bdac03628ac15b84edd3e67e589f8ca145242018aab03fc42b8befc1c0330f0111d01b239dc00b6ffc29965ba3c18ce0965cbe9e7b31d1fef4d DIST psycopg2-2.7.7.tar.gz 427474 BLAKE2B bc721b721693bc5f560a4829e84715d15e8c14523ada00109c7d7ba916c91928082fff286bd3c2ff5987c0436443128d1408ac9de073ad538b1e356fc73aaf8f SHA512 032344957c00bf659ca5e46f54f827a6d79809e370d661cd349e2ce935873359bcc4f440b74c6f14658bf1cd9598b6d884abae507fd33db9e07b01fc87967fb0 DIST psycopg2-2.8.5.tar.gz 380874 BLAKE2B 843321175499bf00b080d3e58ce0d586e674585af4be5a08866b5dbb68256ff9232d3c25e2603a3a0920a6c91927eb9fbb5942acd429be5dab9177c65da0c32e SHA512 d4cf9b94573b90fe56555ea5cf841aa0c4c806770f92f35a7ef2531999bb50f98eb1276e56f1540b5f2695e443bac7e9cb8bbfbd24ed82164f99663259d2da3e +DIST psycopg2-2.8.6.tar.gz 383797 BLAKE2B da0e3f1e143c51c940ba1f51d3e457b492d880ab71267dacd4747444bc767711ccd6c2f54d9e10ce5ad8fae0c3206fb4b6199f267e9bbaf12eb654227f59c2b0 SHA512 1e1d5d8755c6d1a153d84210bf29902afafe853659d709e13abc6bc5772def13779d2394690af1c544384c9c607edc0fe5cf2763244fb346febf9a9e0032b45f EBUILD psycopg-2.7.7.ebuild 1541 BLAKE2B 6388fff673f66631cdba8911a16e36e3bd575d2a88c85704297ac7fc6ba4a3c351e54625f459e89f287a44171ea9d1c15f456d55c68e29a30b24c4784e2be1d8 SHA512 b420616a1edc69f2a181651d2e11cffa0dd5896bb239d2e5c9e642540fd9eccc70a764c3048d432c0971f751c8b3f29f92ce86358995614af4ea02d371502851 EBUILD psycopg-2.8.5.ebuild 1524 BLAKE2B 1402eecade47b0ef53252a7a00b282f8bbac55956b858e0625a5784b71e19a7eeea2ffd40ba87aee963c89437b7413644b719faaf983e1fb83eb351bedd55562 SHA512 25d3d9113ecc63762a1c1916511760d3c9059a1af35aebc533942fcbd0aeae8109c6e46f21da7c641c1c0e1e492f0795b4403563f7c9344bb3ed0eac18546cbc +EBUILD psycopg-2.8.6.ebuild 1627 BLAKE2B 2bb102633147da683597d92361ce51c871f034bae961df0a9cd437aedb5eee10c32b9ff02d5c1a500973d4e9b4bd76153e5bfbe3f94489145f1ee86ab7a7c29a SHA512 c4cfca9cac251613213ffa755f3f2b157503fbdd470ab24493f87f07d4018aa3fe1e3e20b079738ac8b39b9d2b4e86c290c31376876aab7c854763b8e29c132f MISC metadata.xml 321 BLAKE2B aff48bec04e34b92668aa18214d86ddbedef2376eeced4815118d35eebfb8e6af87234a9470828f465626f7d9ed56fe0fcb8f078c23945371248136533651ad3 SHA512 358b751b3a65f64ab5468bcf4022315f7069a2fb60709c2bb12ac02577866a3ff24ab2dd69577052070cf010a51428cb3ec385ca7cfe48640f4dd25ae478a966 diff --git a/dev-python/psycopg/psycopg-2.8.6.ebuild b/dev-python/psycopg/psycopg-2.8.6.ebuild new file mode 100644 index 000000000000..eab79881aa49 --- /dev/null +++ b/dev-python/psycopg/psycopg-2.8.6.ebuild @@ -0,0 +1,65 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +PYTHON_COMPAT=( python2_7 python3_{6..9} ) + +inherit distutils-r1 flag-o-matic + +MY_PN="${PN}2" +MY_P="${MY_PN}-${PV}" + +DESCRIPTION="PostgreSQL database adapter for Python" +HOMEPAGE="https://www.psycopg.org https://pypi.org/project/psycopg2/" +SRC_URI="mirror://pypi/${MY_PN:0:1}/${MY_PN}/${MY_P}.tar.gz" +S=${WORKDIR}/${MY_P} + +LICENSE="LGPL-3+" +SLOT="2" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x86-solaris" +IUSE="debug test" +RESTRICT="!test? ( test )" + +# automagic dep on mxdatetime (from egenix-mx-base) +# the package was removed, so let's just make sure it's gone +RDEPEND=">=dev-db/postgresql-8.1:*" +DEPEND="${RDEPEND} + test? ( >=dev-db/postgresql-8.1[server] ) + !!dev-python/egenix-mx-base" + +python_compile() { + local CFLAGS=${CFLAGS} CXXFLAGS=${CXXFLAGS} + + ! python_is_python3 && append-flags -fno-strict-aliasing + + distutils-r1_python_compile +} + +python_prepare_all() { + if use debug; then + sed -i 's/^\(define=\)/\1PSYCOPG_DEBUG,/' setup.cfg || die + fi + + distutils-r1_python_prepare_all +} + +src_test() { + initdb -D "${T}"/pgsql || die + # TODO: random port + pg_ctl -w -D "${T}"/pgsql start \ + -o "-h '' -k '${T}'" || die + createdb -h "${T}" psycopg2_test || die + + local -x PSYCOPG2_TESTDB_HOST="${T}" + distutils-r1_src_test + + pg_ctl -w -D "${T}"/pgsql stop || die +} + +python_test() { + "${EPYTHON}" -c " +import tests +tests.unittest.main(defaultTest='tests.test_suite') +" --verbose || die "Tests fail with ${EPYTHON}" +} |