2014-06-20 09:44:44 +00:00
|
|
|
# Template file for 'python-dbus'
|
|
|
|
pkgname=python-dbus
|
|
|
|
version=1.2.0
|
2015-05-02 01:22:13 +00:00
|
|
|
revision=6
|
2014-06-20 09:44:44 +00:00
|
|
|
lib32disabled=yes
|
|
|
|
wrksrc="dbus-python-${version}"
|
|
|
|
build_style=gnu-configure
|
|
|
|
hostmakedepends="pkg-config python-devel python3.4-devel"
|
2015-05-02 01:22:13 +00:00
|
|
|
makedepends="libglib-devel dbus-glib-devel ${hostmakedepends/pkg-config/}"
|
2014-11-15 18:40:00 +00:00
|
|
|
depends="python dbus"
|
2014-06-20 09:44:44 +00:00
|
|
|
pycompile_module="dbus"
|
|
|
|
short_desc="D-Bus Python2 bindings"
|
2015-04-10 07:16:30 +00:00
|
|
|
maintainer="Juan RP <xtraeme@voidlinux.eu>"
|
2014-06-20 09:44:44 +00:00
|
|
|
license="GPL-2, LGPL-2.1"
|
|
|
|
homepage="http://www.freedesktop.org/wiki/Software/DBusBindings"
|
|
|
|
distfiles="http://dbus.freedesktop.org/releases/dbus-python/dbus-python-${version}.tar.gz"
|
|
|
|
checksum=e12c6c8b2bf3a9302f75166952cbe41d6b38c3441bbc6767dbd498942316c6df
|
|
|
|
|
2014-11-15 19:00:53 +00:00
|
|
|
_do_pre_configure() {
|
2014-06-20 09:44:44 +00:00
|
|
|
if [ "$CROSS_BUILD" ]; then
|
2014-11-15 19:00:53 +00:00
|
|
|
local pyver=${1:-2.7} pysufx=
|
|
|
|
|
|
|
|
if [ "$pyver" != "2.7" ]; then
|
|
|
|
pysufx="m"
|
|
|
|
fi
|
|
|
|
|
|
|
|
sed -i "s,PYTHON_INCLUDES=.*,PYTHON_INCLUDES=-I${XBPS_CROSS_BASE}/usr/include/python${pyver}${pysufx},g" ../configure
|
2014-06-20 09:44:44 +00:00
|
|
|
fi
|
2014-11-15 19:00:53 +00:00
|
|
|
}
|
2014-06-20 09:44:44 +00:00
|
|
|
|
2014-11-15 19:00:53 +00:00
|
|
|
do_configure() {
|
2014-06-20 09:44:44 +00:00
|
|
|
# python2
|
|
|
|
mkdir ${wrksrc}/build-python2
|
|
|
|
cd ${wrksrc}/build-python2
|
2014-11-15 19:00:53 +00:00
|
|
|
_do_pre_configure
|
2014-06-20 09:44:44 +00:00
|
|
|
env PYTHON=python ../configure ${configure_args}
|
|
|
|
|
|
|
|
# python3.4
|
|
|
|
mkdir ${wrksrc}/build-python3.4
|
|
|
|
cd ${wrksrc}/build-python3.4
|
2014-11-15 19:00:53 +00:00
|
|
|
_do_pre_configure 3.4
|
2014-06-20 09:44:44 +00:00
|
|
|
env PYTHON=python3.4 ../configure ${configure_args}
|
|
|
|
}
|
|
|
|
|
|
|
|
do_build() {
|
|
|
|
# python2
|
|
|
|
cd ${wrksrc}/build-python2
|
|
|
|
make ${makejobs}
|
|
|
|
|
|
|
|
# python3.4
|
|
|
|
cd ${wrksrc}/build-python3.4
|
|
|
|
make ${makejobs}
|
|
|
|
}
|
|
|
|
|
|
|
|
do_install() {
|
|
|
|
# python2
|
|
|
|
cd ${wrksrc}/build-python2
|
|
|
|
make DESTDIR=${DESTDIR} install
|
|
|
|
|
|
|
|
# python3.4
|
|
|
|
cd ${wrksrc}/build-python3.4
|
|
|
|
make DESTDIR=${DESTDIR} install
|
|
|
|
}
|
|
|
|
|
|
|
|
python3.4-dbus_package() {
|
|
|
|
lib32disabled=yes
|
2014-11-15 18:40:00 +00:00
|
|
|
depends="python3.4 dbus"
|
2014-06-20 09:44:44 +00:00
|
|
|
short_desc="${short_desc/Python2/Python3.4}"
|
|
|
|
pkg_install() {
|
2014-11-15 18:40:00 +00:00
|
|
|
vmove usr/lib/python3.4
|
2014-06-20 09:44:44 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
python-dbus-devel_package() {
|
|
|
|
lib32disabled=yes
|
|
|
|
depends="python-devel python3.4-devel
|
2014-11-15 18:40:00 +00:00
|
|
|
python-dbus>=${version}_${revision} python3.4-dbus>=${version}_${revision}"
|
2014-06-20 09:44:44 +00:00
|
|
|
short_desc+=" - development files"
|
|
|
|
pkg_install() {
|
|
|
|
vmove usr/include
|
|
|
|
vmove usr/lib/pkgconfig
|
|
|
|
vmove usr/share/doc
|
|
|
|
}
|
|
|
|
}
|