commit:     847204a2b260d0e5783e3c84d6b7d0312e38cb81
Author:     Anna (cybertailor) Vyalkova <cyber+gentoo <AT> sysrq <DOT> in>
AuthorDate: Wed Oct 23 17:30:44 2024 +0000
Commit:     Anna Vyalkova <cyber+gentoo <AT> sysrq <DOT> in>
CommitDate: Wed Oct 23 22:49:59 2024 +0000
URL:        https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=847204a2

dev-python/asyncpg: fix build with USE=debug

Unset "cython_directives" via build_ext options, because the default for
debug builds is broken.

Closes: https://bugs.gentoo.org/926720
Signed-off-by: Anna (cybertailor) Vyalkova <cyber+gentoo <AT> sysrq.in>

 dev-python/asyncpg/asyncpg-0.30.0.ebuild | 19 ++++++++++++-------
 1 file changed, 12 insertions(+), 7 deletions(-)

diff --git a/dev-python/asyncpg/asyncpg-0.30.0.ebuild 
b/dev-python/asyncpg/asyncpg-0.30.0.ebuild
index a412dba36..f1897b83e 100644
--- a/dev-python/asyncpg/asyncpg-0.30.0.ebuild
+++ b/dev-python/asyncpg/asyncpg-0.30.0.ebuild
@@ -54,22 +54,27 @@ distutils_enable_tests pytest
 distutils_enable_sphinx docs \
        dev-python/sphinx-rtd-theme
 
-src_prepare() {
+python_prepare_all() {
+       # bug #926720
+       cat <<-EOF >> setup.cfg || die
+               [build_ext]
+               cython_always=True
+               cython_annotate=False
+               cython_directives=
+       EOF
+
        # remove pre-generated Cython sources
        rm asyncpg/{pgproto/pgproto,protocol/protocol}.c || die
 
-       distutils-r1_src_prepare
+       distutils-r1_python_prepare_all
 }
 
-src_configure() {
+python_configure_all() {
        use debug && \
                export ASYNCPG_DEBUG=1
 
-       if ! use kerberos; then
+       use kerberos || \
                EPYTEST_DESELECT+=( 
tests/test_connect.py::TestGssAuthentication )
-       fi
-
-       distutils-r1_src_configure
 }
 
 python_test() {

Reply via email to