blob: ae5c3dd67a30d791fa4c62bb0a6b1cd324f312dc [file] [log] [blame]
Simran Basi80cab6a2014-02-11 14:39:09 -08001# Copyright 1999-2014 Gentoo Foundation
2# Distributed under the terms of the GNU General Public License v2
3# $Header: /var/cvsroot/gentoo-x86/dev-python/mysql-python/mysql-python-1.2.3-r1.ebuild,v 1.12 2014/02/06 09:27:32 jer Exp $
4
5EAPI=5
6PYTHON_COMPAT=( python{2_6,2_7} )
7
8inherit distutils-r1 flag-o-matic
9
10MY_P="MySQL-python-${PV}"
11
12DESCRIPTION="Python interface to MySQL"
13HOMEPAGE="http://sourceforge.net/projects/mysql-python/ http://pypi.python.org/pypi/MySQL-python"
14SRC_URI="mirror://sourceforge/mysql-python/${MY_P}.tar.gz"
15
16LICENSE="GPL-2"
17SLOT="0"
18KEYWORDS="*"
19IUSE=""
20
21# RDEPEND on sys-devel/binutils to ensure libbfd is available.
22RDEPEND="virtual/mysql
23 sys-devel/binutils
24"
25DEPEND="${RDEPEND}
26 dev-python/setuptools[${PYTHON_USEDEP}]"
27
28S="${WORKDIR}/${MY_P}"
29
30DOCS=( HISTORY README doc/{FAQ,MySQLdb}.txt )
31
32src_configure() {
33 # Append the SYSROOT Library Path in order for the linker to find
34 # libbfd when cross-compiling.
35 append-ldflags "-L${SYSROOT}/usr/${CHOST}/lib"
36
37 # Update the site configuration options to search for mysql_config in the SYSROOT.
38 sed -i -r \
39 -e "s:#mysql_config = /usr/local/bin:mysql_config = ${SYSROOT}/usr/bin:" \
40 site.cfg
41 distutils-r1_src_configure
42}
43
44python_configure_all() {
45 append-flags -fno-strict-aliasing
46}