python-dbus: fix cross build
This commit is contained in:
parent
f12a0d2861
commit
7d9bffa226
|
@ -17,19 +17,29 @@ update_pkgname="dbus-python"
|
||||||
distfiles="http://dbus.freedesktop.org/releases/dbus-python/dbus-python-${version}.tar.gz"
|
distfiles="http://dbus.freedesktop.org/releases/dbus-python/dbus-python-${version}.tar.gz"
|
||||||
checksum=e12c6c8b2bf3a9302f75166952cbe41d6b38c3441bbc6767dbd498942316c6df
|
checksum=e12c6c8b2bf3a9302f75166952cbe41d6b38c3441bbc6767dbd498942316c6df
|
||||||
|
|
||||||
do_configure() {
|
_do_pre_configure() {
|
||||||
if [ "$CROSS_BUILD" ]; then
|
if [ "$CROSS_BUILD" ]; then
|
||||||
ln -s ${wrksrc}/.xbps/bin/python-config ${wrksrc}
|
local pyver=${1:-2.7} pysufx=
|
||||||
fi
|
|
||||||
|
|
||||||
|
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
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
do_configure() {
|
||||||
# python2
|
# python2
|
||||||
mkdir ${wrksrc}/build-python2
|
mkdir ${wrksrc}/build-python2
|
||||||
cd ${wrksrc}/build-python2
|
cd ${wrksrc}/build-python2
|
||||||
|
_do_pre_configure
|
||||||
env PYTHON=python ../configure ${configure_args}
|
env PYTHON=python ../configure ${configure_args}
|
||||||
|
|
||||||
# python3.4
|
# python3.4
|
||||||
mkdir ${wrksrc}/build-python3.4
|
mkdir ${wrksrc}/build-python3.4
|
||||||
cd ${wrksrc}/build-python3.4
|
cd ${wrksrc}/build-python3.4
|
||||||
|
_do_pre_configure 3.4
|
||||||
env PYTHON=python3.4 ../configure ${configure_args}
|
env PYTHON=python3.4 ../configure ${configure_args}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue