From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 163B7158094 for ; Thu, 23 Jun 2022 07:19:26 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 5B3C4E091D; Thu, 23 Jun 2022 07:19:25 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 3E537E08FF for ; Thu, 23 Jun 2022 07:19:25 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 583CF341C70 for ; Thu, 23 Jun 2022 07:19:24 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id CD3F951C for ; Thu, 23 Jun 2022 07:19:21 +0000 (UTC) From: "Michał Górny" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Michał Górny" Message-ID: <1655968756.7c990d4d47c51afd42a252d8416aa5fa6fb05b7f.mgorny@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/mysqlclient/ X-VCS-Repository: repo/gentoo X-VCS-Files: dev-python/mysqlclient/Manifest dev-python/mysqlclient/mysqlclient-2.1.1.ebuild X-VCS-Directories: dev-python/mysqlclient/ X-VCS-Committer: mgorny X-VCS-Committer-Name: Michał Górny X-VCS-Revision: 7c990d4d47c51afd42a252d8416aa5fa6fb05b7f X-VCS-Branch: master Date: Thu, 23 Jun 2022 07:19:21 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 851c9f53-10b1-4683-b89a-a2fd085d57bb X-Archives-Hash: 8f349bc69449a6dc0aecbe916cb2020c commit: 7c990d4d47c51afd42a252d8416aa5fa6fb05b7f Author: Michał Górny gentoo org> AuthorDate: Thu Jun 23 06:43:59 2022 +0000 Commit: Michał Górny gentoo org> CommitDate: Thu Jun 23 07:19:16 2022 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7c990d4d dev-python/mysqlclient: Bump to 2.1.1 Signed-off-by: Michał Górny gentoo.org> dev-python/mysqlclient/Manifest | 1 + dev-python/mysqlclient/mysqlclient-2.1.1.ebuild | 91 +++++++++++++++++++++++++ 2 files changed, 92 insertions(+) diff --git a/dev-python/mysqlclient/Manifest b/dev-python/mysqlclient/Manifest index 8e94c89c1ede..1a19bd15ebe5 100644 --- a/dev-python/mysqlclient/Manifest +++ b/dev-python/mysqlclient/Manifest @@ -1 +1,2 @@ DIST mysqlclient-2.1.0.tar.gz 87635 BLAKE2B b92e138f6128873912e951087bc4f12b3c00a400521c7ee64da177c6f5a2dfb3a649d92f7a12f45c8716fd8b6b9682a0eff6d9bc111cffac38a27676f67d396a SHA512 a0b2645af225fd6f1f551cfd34c09309a859410e66287c32637901e15beb88632f9a3e87cf2b08a94867a9b2d4a048c56d63d55f523eafc82f1b1b93ce1c843c +DIST mysqlclient-2.1.1.tar.gz 88138 BLAKE2B fdd044f2703af874dc0ca67b2fe07fcac3ceed5a4543aa15a0daa852ddf5ad6940a43675c0f104d9aa173e96da946e33054e1cc4c1b9812487558af64cc8fd43 SHA512 d8aed044b651aabb8d28d2df085f84e4d824ef0f147216d111425a9c8024f55634236ec131debf46660084c5a8fd67c944db60ffbf89e1d712cdca80c0726a06 diff --git a/dev-python/mysqlclient/mysqlclient-2.1.1.ebuild b/dev-python/mysqlclient/mysqlclient-2.1.1.ebuild new file mode 100644 index 000000000000..e1988244df9f --- /dev/null +++ b/dev-python/mysqlclient/mysqlclient-2.1.1.ebuild @@ -0,0 +1,91 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( python3_{8..10} ) + +inherit distutils-r1 + +DESCRIPTION="Python interface to MySQL" +HOMEPAGE=" + https://pypi.org/project/mysqlclient/ + https://github.com/PyMySQL/mysqlclient/ +" +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz" + +LICENSE="GPL-2+" +SLOT="0" +KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux" + +DEPEND=" + dev-db/mysql-connector-c:0= +" +RDEPEND=" + ${DEPEND} +" +BDEPEND=" + test? ( + dev-db/mariadb[server] + ) +" + +distutils_enable_sphinx doc +distutils_enable_tests pytest + +src_test() { + local datadir="${T}/mysql" \ + install_log="${T}/mysqld_install.log" \ + pidfile="${T}/mysqld.pid" \ + socket="${T}/mysqld.sock" \ + log="${T}/mysqld.log" + einfo "Creating test MySQL instance ..." + if ! mysql_install_db \ + --no-defaults \ + --auth-root-authentication-method=normal \ + --basedir="${EPREFIX}/usr" \ + --datadir="${datadir}" >& "${install_log}" + then + cat "${install_log}" + die "Failed to create database" + fi + + einfo "Starting test MySQL instance ..." + mysqld \ + --no-defaults \ + --character-set-server=utf8 \ + --pid-file="${pidfile}" \ + --socket="${socket}" \ + --skip-networking \ + --datadir="${datadir}" >& "${log}" & + + local i timeout=10 + einfo "Waiting for MySQL to start for up to ${timeout} seconds ..." + for i in seq 1 ${timeout}; do + [[ -S "${socket}" ]] && break + sleep 1 + done + if [[ ! -S "${socket}" ]]; then + cat "${log}" + die "MySQL failed to start in ${timeout} seconds" + fi + + cat > "${T}/mysql.cnf" <<- EOF + [MySQLdb-tests] + socket = ${socket} + user = root + database = test + EOF + + distutils-r1_src_test + + einfo "Stopping test MySQL instance ..." + pkill -F "${pidfile}" &>/dev/null +} + +python_test() { + local -x TESTDB="${T}/mysql.cnf" + rm -rf MySQLdb || die + epytest +}