diff options
author | Thomas Deutschmann <whissi@gentoo.org> | 2020-03-08 02:23:05 +0100 |
---|---|---|
committer | Thomas Deutschmann <whissi@gentoo.org> | 2020-03-08 02:31:32 +0100 |
commit | 13926f810426bd99d4d580bf6facc29d552e5e6f (patch) | |
tree | 4e0d2b993047ba426220d9ef80429566b2aa3df1 /dev-python/mysql-python | |
parent | sys-apps/coreutils: restore ls behavior from 8.31 (diff) | |
download | gentoo-13926f810426bd99d4d580bf6facc29d552e5e6f.tar.gz gentoo-13926f810426bd99d4d580bf6facc29d552e5e6f.tar.bz2 gentoo-13926f810426bd99d4d580bf6facc29d552e5e6f.zip |
dev-python/mysql-python: fix building against dev-db/mysql-8+
Closes: https://bugs.gentoo.org/632578
Package-Manager: Portage-2.3.91, Repoman-2.3.20
Signed-off-by: Thomas Deutschmann <whissi@gentoo.org>
Diffstat (limited to 'dev-python/mysql-python')
-rw-r--r-- | dev-python/mysql-python/files/mysql-python-1.2.5-drop-my_config.h-include.patch | 15 | ||||
-rw-r--r-- | dev-python/mysql-python/mysql-python-1.2.5-r3.ebuild | 46 |
2 files changed, 61 insertions, 0 deletions
diff --git a/dev-python/mysql-python/files/mysql-python-1.2.5-drop-my_config.h-include.patch b/dev-python/mysql-python/files/mysql-python-1.2.5-drop-my_config.h-include.patch new file mode 100644 index 000000000000..15a22f737a4e --- /dev/null +++ b/dev-python/mysql-python/files/mysql-python-1.2.5-drop-my_config.h-include.patch @@ -0,0 +1,15 @@ +We don't use anything from my_config.h. + +Bug: https://bugs.gentoo.org/632578 + +--- a/_mysql.c ++++ b/_mysql.c +@@ -40,8 +40,6 @@ PERFORMANCE OF THIS SOFTWARE. + #include "structmember.h"
+ #if defined(MS_WINDOWS)
+ #include <config-win.h>
+-#else
+-#include "my_config.h"
+ #endif
+ #include "mysql.h"
+ #include "mysqld_error.h"
diff --git a/dev-python/mysql-python/mysql-python-1.2.5-r3.ebuild b/dev-python/mysql-python/mysql-python-1.2.5-r3.ebuild new file mode 100644 index 000000000000..232df2192159 --- /dev/null +++ b/dev-python/mysql-python/mysql-python-1.2.5-r3.ebuild @@ -0,0 +1,46 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +PYTHON_COMPAT=( python2_7 ) + +inherit distutils-r1 flag-o-matic + +MY_PN="MySQL-python" +MY_P="${MY_PN}-${PV}" + +DESCRIPTION="Python interface to MySQL" +HOMEPAGE="https://sourceforge.net/projects/mysql-python/ https://pypi.org/project/MySQL-python/" +SRC_URI="mirror://pypi/${MY_PN:0:1}/${MY_PN}/${MY_P}.zip" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" +IUSE="doc" + +RDEPEND="dev-db/mysql-connector-c" +DEPEND="${RDEPEND}" +BDEPEND="${RDEPEND} + app-arch/unzip + dev-python/setuptools[${PYTHON_USEDEP}] + doc? ( dev-python/sphinx[${PYTHON_USEDEP}] )" + +S="${WORKDIR}/${MY_P}" + +PATCHES=( "${FILESDIR}"/${PN}-1.2.5-drop-my_config.h-include.patch ) + +DOCS=( HISTORY README.md doc/{FAQ,MySQLdb}.rst ) + +python_configure_all() { + append-flags -fno-strict-aliasing +} + +python_compile_all() { + use doc && sphinx-build -b html doc doc/_build/ +} + +python_install_all() { + use doc && local HTML_DOCS=( doc/_build/. ) + distutils-r1_python_install_all +} |