mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-09 13:20:08 +02:00
Jsonrpcclient: new recipe (#4853)
This commit is contained in:
67
dev-python/jsonrpcclient/jsonrpcclient-3.3.5.recipe
Normal file
67
dev-python/jsonrpcclient/jsonrpcclient-3.3.5.recipe
Normal file
@@ -0,0 +1,67 @@
|
||||
SUMMARY="Send JSON-RPC requests in Python"
|
||||
DESCRIPTION="This library allows you to call remote procedures using the \
|
||||
JSON-RPC message format."
|
||||
HOMEPAGE="https://pypi.org/project/jsonrpcclient/
|
||||
https://github.com/bcb/jsonrpcclient"
|
||||
COPYRIGHT="2015 Beau Barker"
|
||||
LICENSE="MIT"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://files.pythonhosted.org/packages/be/6a/0e756584a9550ff7d5f5a13a4cf325feeb5036e5ec8958617dd26321b7b6/jsonrpcclient-3.3.5.tar.gz"
|
||||
CHECKSUM_SHA256="a17d02a53061748384b15b4e9812e866d5f69771656ccf7031d6dc64d0c38099"
|
||||
|
||||
ARCHITECTURES="any"
|
||||
|
||||
PROVIDES="
|
||||
$portName = $portVersion
|
||||
"
|
||||
REQUIRES="
|
||||
haiku
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku_devel
|
||||
"
|
||||
|
||||
PYTHON_PACKAGES=(python3)
|
||||
PYTHON_VERSIONS=(3.7)
|
||||
for i in "${!PYTHON_PACKAGES[@]}"; do
|
||||
pythonPackage=${PYTHON_PACKAGES[i]}
|
||||
pythonVersion=${PYTHON_VERSIONS[$i]}
|
||||
eval "PROVIDES_${pythonPackage}=\"\
|
||||
${portName}_$pythonPackage = $portVersion\
|
||||
\"; \
|
||||
REQUIRES_$pythonPackage=\"\
|
||||
haiku\n\
|
||||
cmd:python$pythonVersion\
|
||||
\""
|
||||
BUILD_REQUIRES="$BUILD_REQUIRES
|
||||
setuptools_$pythonPackage"
|
||||
BUILD_PREREQUIRES="$BUILD_PREREQUIRES
|
||||
cmd:python$pythonVersion"
|
||||
done
|
||||
|
||||
PROVIDES_python3="$PROVIDES_python3
|
||||
cmd:jsonrpc3.7
|
||||
"
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
for i in "${!PYTHON_PACKAGES[@]}"; do
|
||||
pythonPackage=${PYTHON_PACKAGES[i]}
|
||||
pythonVersion=${PYTHON_VERSIONS[$i]}
|
||||
|
||||
python=python$pythonVersion
|
||||
installLocation=$prefix/lib/$python/vendor-packages/
|
||||
export PYTHONPATH=$installLocation:$PYTHONPATH
|
||||
mkdir -p $installLocation
|
||||
rm -rf build
|
||||
$python setup.py build install \
|
||||
--root=/ --prefix=$prefix
|
||||
if [ $pythonPackage != python ]; then
|
||||
mv $binDir/jsonrpc $binDir/jsonrpc$pythonVersion
|
||||
fi
|
||||
packageEntries $pythonPackage \
|
||||
$prefix/lib/python* \
|
||||
$binDir
|
||||
done
|
||||
}
|
||||
Reference in New Issue
Block a user