67 lines
1.7 KiB
Bash
67 lines
1.7 KiB
Bash
SUMMARY="Another Python SQLite Wrapper"
|
|
DESCRIPTION="A Python wrapper for the SQLite embedded relational database \
|
|
engine. In contrast to other wrappers such as pysqlite it focuses on being a \
|
|
minimal layer over SQLite attempting just to translate the complete SQLite \
|
|
API into Python."
|
|
HOMEPAGE="https://github.com/rogerbinns/apsw/
|
|
https://pypi.org/project/apsw/"
|
|
COPYRIGHT="2004-2019 Roger Binns"
|
|
LICENSE="OSI"
|
|
REVISION="3"
|
|
SOURCE_URI="https://github.com/rogerbinns/apsw/archive/3.30.1-r1.tar.gz"
|
|
CHECKSUM_SHA256="5b7adbc5aa6bc0b186d32ff813a1248817470da78dc9ebf4efc4ff0b475372dd"
|
|
SOURCE_DIR="apsw-3.30.1-r1"
|
|
|
|
ARCHITECTURES="all"
|
|
|
|
PROVIDES="
|
|
$portName = $portVersion
|
|
"
|
|
REQUIRES="
|
|
haiku
|
|
lib:libsqlite3$secondaryArchSuffix
|
|
"
|
|
|
|
BUILD_REQUIRES="
|
|
haiku_devel
|
|
"
|
|
|
|
PYTHON_PACKAGES=(python python3 python38 python39)
|
|
PYTHON_VERSIONS=(2.7 3.7 3.8 3.9)
|
|
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
|
|
devel:libsqlite3$secondaryArchSuffix"
|
|
BUILD_PREREQUIRES="$BUILD_PREREQUIRES
|
|
cmd:python$pythonVersion
|
|
cmd:gcc$secondaryArchSuffix"
|
|
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
|
|
}
|