mirror of
https://github.com/pentoo/pentoo-overlay
synced 2026-04-17 12:20:59 +02:00
soapysdr: fix python bindings
This commit is contained in:
parent
c6e1e3a611
commit
793ccde9ab
6 changed files with 17 additions and 103 deletions
|
|
@ -1,2 +1 @@
|
|||
DIST simplesoapy-1.4.1.tar.gz 6050 SHA256 79577c1de8e5c58ad666d160e077134829ba7da8c54914d008059e5339446cc3 SHA512 d77587efc7180d5c9d23f9e943f33c93dbacf44c5f537ebcda1ca815a4ba5bcb26925fa5a620ebe9982ba533d149b3ee11cccc5ba08ce06cb49820a9b4a02551 WHIRLPOOL ddeb3db44438e4dd8412e926219a0ba200353359200fb2cea522875f8113307734d4ea36ed4fbdcf18915909669afa121f9af86a7e8727368a0fdc1d572fc326
|
||||
DIST simplesoapy-1.5.1.tar.gz 6129 SHA256 4006fb23997693266fbeee0b92d7461c3801c677a6dd2931a9539f34f37aa5b2 SHA512 5ef0a4fcd84e1da9207154d4b8c4679e8aa2c9885ca76eacb17c4fbd39f489be459f52bfd42ee9b369790c33a02ecc5d776735cf1665f3ee034c1e315fdbb818 WHIRLPOOL 62f1e1c336ac5b96dee2d684ec07203df7e1ca1e813859b91ed49dc7af9bdb5c3e3be9c650e2a303938ccf16c55e3f53a9f2c466c3629bc36ecaf330c9a8e961
|
||||
|
|
|
|||
|
|
@ -24,4 +24,5 @@ fi
|
|||
|
||||
DEPEND=""
|
||||
RDEPEND="dev-python/numpy[${PYTHON_USEDEP}]
|
||||
net-wireless/soapysdr"
|
||||
net-wireless/soapysdr[python]
|
||||
net-wireless/soapysdr[${PYTHON_USEDEP}]"
|
||||
|
|
@ -1,27 +0,0 @@
|
|||
# Copyright 1999-2017 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=6
|
||||
|
||||
PYTHON_COMPAT=( python3_{4,5,6} )
|
||||
inherit distutils-r1
|
||||
|
||||
DESCRIPTION="Simple pythonic wrapper for SoapySDR library"
|
||||
HOMEPAGE="https://github.com/xmikos/simplesoapy"
|
||||
|
||||
LICENSE="MIT"
|
||||
SLOT="0"
|
||||
|
||||
if [ "${PV}" = "9999" ]; then
|
||||
KEYWORDS=""
|
||||
inherit git-r3
|
||||
EGIT_REPO_URI="https://github.com/xmikos/simplesoapy.git"
|
||||
else
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
SRC_URI="https://github.com/xmikos/simplesoapy/archive/v${PV}.tar.gz -> ${P}.tar.gz"
|
||||
fi
|
||||
|
||||
|
||||
DEPEND=""
|
||||
RDEPEND="dev-python/numpy[${PYTHON_USEDEP}]
|
||||
net-wireless/soapysdr"
|
||||
|
|
@ -24,4 +24,5 @@ fi
|
|||
|
||||
DEPEND=""
|
||||
RDEPEND="dev-python/numpy[${PYTHON_USEDEP}]
|
||||
net-wireless/soapysdr"
|
||||
net-wireless/soapysdr[python]
|
||||
net-wireless/soapysdr[${PYTHON_USEDEP}]"
|
||||
|
|
|
|||
|
|
@ -1,6 +1,5 @@
|
|||
# Copyright 1999-2017 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=6
|
||||
|
||||
|
|
@ -25,9 +24,13 @@ fi
|
|||
LICENSE="Boost-1.0"
|
||||
SLOT="0"
|
||||
|
||||
IUSE="bladerf hackrf python rtlsdr uhd"
|
||||
IUSE="bladerf hackrf +python rtlsdr uhd"
|
||||
REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
|
||||
|
||||
#python2 will be always installed
|
||||
#https://github.com/pothosware/SoapySDR/issues/130
|
||||
#REQUIRED_USE="python_targets_python3_4? ( python_targets_python2_7 )"
|
||||
|
||||
RDEPEND="python? ( ${PYTHON_DEPS} )"
|
||||
DEPEND="${RDEPEND}
|
||||
python? ( dev-lang/swig:0 )
|
||||
|
|
@ -37,51 +40,17 @@ PDEPEND="bladerf? ( net-wireless/soapybladerf )
|
|||
rtlsdr? ( net-wireless/soapyrtlsdr )
|
||||
uhd? ( net-wireless/soapyuhd )"
|
||||
|
||||
src_prepare() {
|
||||
use python && python_copy_sources
|
||||
default
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
configuration() {
|
||||
local mycmakeargs=(
|
||||
-DENABLE_PYTHON=$(usex python)
|
||||
)
|
||||
mycmakeargs+=( -DENABLE_PYTHON=ON )
|
||||
if python_is_python3; then
|
||||
mycmakeargs+=( -DBUILD_PYTHON3=ON
|
||||
-DENABLE_PYTHON3=ON
|
||||
)
|
||||
else
|
||||
mycmakeargs+=( -DBUILD_PYTHON3=OFF
|
||||
-DENABLE_PYTHON3=OFF
|
||||
)
|
||||
mycmakeargs+=( -DBUILD_PYTHON3=ON )
|
||||
fi
|
||||
cmake-utils_src_configure
|
||||
}
|
||||
|
||||
if use python; then
|
||||
python_foreach_impl configuration
|
||||
else
|
||||
CMAKE_IN_SOURCE_BUILD=1
|
||||
mycmakeargs+=( -DBUILD_PYTHON3=OFF
|
||||
-DENABLE_PYTHON3=OFF
|
||||
-DBUILD_PYTHON=OFF
|
||||
-DENABLE_PYTHON=OFF
|
||||
)
|
||||
cmake-utils_src_configure
|
||||
fi
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
compilation() {
|
||||
cmake-utils_src_make
|
||||
}
|
||||
use python && python_foreach_impl compilation || compilation
|
||||
}
|
||||
|
||||
src_install() {
|
||||
installation() {
|
||||
cmake-utils_src_install DESTDIR="${ED}"
|
||||
use python && python_optimize
|
||||
}
|
||||
use python && python_foreach_impl installation || installation
|
||||
cmake-utils_src_configure
|
||||
}
|
||||
|
|
@ -37,46 +37,17 @@ PDEPEND="bladerf? ( net-wireless/soapybladerf )
|
|||
rtlsdr? ( net-wireless/soapyrtlsdr )
|
||||
uhd? ( net-wireless/soapyuhd )"
|
||||
|
||||
src_prepare() {
|
||||
eapply_user
|
||||
use python && python_copy_sources
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
configuration() {
|
||||
local mycmakeargs=(
|
||||
-DENABLE_PYTHON=$(usex python)
|
||||
)
|
||||
mycmakeargs+=( -DENABLE_PYTHON=ON )
|
||||
if python_is_python3; then
|
||||
mycmakeargs+=( -DBUILD_PYTHON3=ON
|
||||
-DENABLE_PYTHON3=ON
|
||||
)
|
||||
else
|
||||
mycmakeargs+=( -DBUILD_PYTHON3=OFF
|
||||
-DENABLE_PYTHON3=OFF
|
||||
)
|
||||
mycmakeargs+=( -DBUILD_PYTHON3=ON )
|
||||
fi
|
||||
|
||||
cmake-utils_src_configure
|
||||
}
|
||||
|
||||
if use python; then
|
||||
python_foreach_impl configuration
|
||||
else
|
||||
configuration
|
||||
fi
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
compilation() {
|
||||
cmake-utils_src_make
|
||||
}
|
||||
use python && python_foreach_impl compilation || compilation
|
||||
}
|
||||
|
||||
src_install() {
|
||||
installation() {
|
||||
cmake-utils_src_install DESTDIR="${ED}"
|
||||
use python && python_optimize
|
||||
}
|
||||
use python && python_foreach_impl installation || installation
|
||||
cmake-utils_src_configure
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue