mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-09 21:30:08 +02:00
67 lines
1.5 KiB
Bash
67 lines
1.5 KiB
Bash
SUMMARY="CSS related utilities (parsing, serialization, etc) for python"
|
|
DESCRIPTION="A fork of the cssutils project based on version 1.0.2. This \
|
|
fork includes general bug fixes and extensions specific to editing and \
|
|
working with ebooks."
|
|
HOMEPAGE="https://github.com/ebook-utils/css-parser"
|
|
COPYRIGHT="2004-2013 Christof Hoeke"
|
|
LICENSE="GNU LGPL v3"
|
|
REVISION="1"
|
|
SOURCE_URI="https://github.com/ebook-utils/css-parser/archive/v$portVersion.tar.gz"
|
|
CHECKSUM_SHA256="45230ee0e71088816bba910d888b6cf0808f359549237e5e0851306c2feb0cc3"
|
|
SOURCE_DIR="css-parser-$portVersion"
|
|
|
|
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
|
|
}
|