mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-22 11:40:06 +02:00
ifaddr: update to version 0.2.0. Add Haiku support. (#9452)
Not sure this ever worked before. Seems to work well enough now.
This commit is contained in:
64
dev-python/ifaddr/ifaddr-0.2.0.recipe
Normal file
64
dev-python/ifaddr/ifaddr-0.2.0.recipe
Normal file
@@ -0,0 +1,64 @@
|
||||
SUMMARY="Cross-platform network interface and IP address enumeration library"
|
||||
DESCRIPTION="ifaddr is a small Python library that allows you to find all \
|
||||
the IP addresses of the computer."
|
||||
HOMEPAGE="https://github.com/pydron/ifaddr/"
|
||||
COPYRIGHT="2014 Stefan C. Mueller"
|
||||
LICENSE="MIT"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://github.com/pydron/ifaddr/archive/$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="bc70dbcad66c25c8c13e037585b43765c1ea82da629708b13de542cb9872c0c7"
|
||||
PATCHES="ifaddr-$portVersion.patchset"
|
||||
|
||||
ARCHITECTURES="any"
|
||||
|
||||
PROVIDES="
|
||||
$portName = $portVersion
|
||||
"
|
||||
REQUIRES="
|
||||
haiku
|
||||
"
|
||||
BUILD_REQUIRES="
|
||||
haiku_devel
|
||||
"
|
||||
|
||||
PYTHON_PACKAGES=(python39 python310)
|
||||
PYTHON_VERSIONS=(3.9 3.10)
|
||||
for i in "${!PYTHON_PACKAGES[@]}"; do
|
||||
pythonPackage=${PYTHON_PACKAGES[i]}
|
||||
pythonVersion=${PYTHON_VERSIONS[i]}
|
||||
|
||||
eval "PROVIDES_$pythonPackage=\"
|
||||
${portName}_$pythonPackage = $portVersion
|
||||
\""
|
||||
eval "REQUIRES_$pythonPackage=\"
|
||||
haiku
|
||||
cmd:python$pythonVersion
|
||||
\""
|
||||
BUILD_REQUIRES+="
|
||||
setuptools_$pythonPackage
|
||||
"
|
||||
BUILD_PREREQUIRES+="
|
||||
cmd:python$pythonVersion
|
||||
"
|
||||
done
|
||||
|
||||
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
|
||||
|
||||
packageEntries $pythonPackage \
|
||||
$prefix/lib/python*
|
||||
done
|
||||
}
|
||||
Reference in New Issue
Block a user