mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-16 00:30:06 +02:00
pychart: convert from old format, add python3 subpackage. (#3304)
This commit is contained in:
@@ -1,29 +1,82 @@
|
||||
DESCRIPTION="PyChart is a Python library for creating high quality charts."
|
||||
HOMEPAGE="http://home.gna.org/pychart"
|
||||
SOURCE_URI="http://download.gna.org/pychart/PyChart-1.39.tar.gz"
|
||||
REVISION="1"
|
||||
STATUS_HAIKU="stable"
|
||||
DEPEND=""
|
||||
CHECKSUM_MD5="f1f509a1c4623056c8e780bb7c9a05c5"
|
||||
SUMMARY="A Python library for creating high quality charts"
|
||||
DESCRIPTION="PyChart is a Python library for creating professional quality \
|
||||
PS, PDF, PNG, or SVG charts. It supports line plots, bar plots, range-fill \
|
||||
plots, and pie charts."
|
||||
HOMEPAGE="https://github.com/Infinite-Code/PyChart
|
||||
https://pypi.org/project/Python-Chart/"
|
||||
COPYRIGHT="1999-2006 Yasushi Saito"
|
||||
LICENSE="GNU GPL v2"
|
||||
REVISION="2"
|
||||
srcGitRev="b4613586ba193a1c8860e1e06c0190246325236b"
|
||||
SOURCE_URI="https://github.com/Infinite-Code/PyChart/archive/$srcGitRev.tar.gz"
|
||||
CHECKSUM_SHA256="7c8d7d0b7ca0843b07f1780382a161990b97e998f8b45a8f0ff91c1cf449343c"
|
||||
SOURCE_FILENAME="PyChart-$portVersion-$srcGitRev.tar.gz"
|
||||
SOURCE_DIR="PyChart-$srcGitRev"
|
||||
|
||||
ARCHITECTURES="any"
|
||||
|
||||
PROVIDES="
|
||||
pychart = $portVersion
|
||||
"
|
||||
REQUIRES="
|
||||
haiku
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku_devel
|
||||
setuptools_python
|
||||
setuptools_python3
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:python
|
||||
cmd:python3
|
||||
"
|
||||
|
||||
PYTHON_PACKAGES=(python python3)
|
||||
PYTHON_VERSIONS=(2.7 3.6)
|
||||
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
|
||||
\""
|
||||
done
|
||||
|
||||
BUILD()
|
||||
{
|
||||
cd PyChart-1.39
|
||||
python setup.py config
|
||||
python setup.py build
|
||||
for i in "${!PYTHON_PACKAGES[@]}"; do
|
||||
pythonPackage=${PYTHON_PACKAGES[i]}
|
||||
pythonVersion=${PYTHON_VERSIONS[$i]}
|
||||
|
||||
rm -rf "$sourceDir"-$pythonPackage
|
||||
cp -a "$sourceDir" "$sourceDir"-$pythonPackage
|
||||
cd "$sourceDir"-$pythonPackage
|
||||
|
||||
python=python$pythonVersion
|
||||
$python setup.py build
|
||||
done
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
cd PyChart-1.39
|
||||
python setup.py install --root=${DESTDIR}
|
||||
}
|
||||
for i in "${!PYTHON_PACKAGES[@]}"; do
|
||||
pythonPackage=${PYTHON_PACKAGES[i]}
|
||||
pythonVersion=${PYTHON_VERSIONS[$i]}
|
||||
|
||||
TEST()
|
||||
{
|
||||
cd PyChart-1.39/demos
|
||||
make
|
||||
}
|
||||
cd "$sourceDir"-$pythonPackage
|
||||
|
||||
LICENSE="GNU GPL v2"
|
||||
COPYRIGHT="1999-2006 Yasushi Saito"
|
||||
python=python$pythonVersion
|
||||
installLocation=$prefix/lib/$python/vendor-packages/
|
||||
export PYTHONPATH=$installLocation
|
||||
mkdir -p "$installLocation"
|
||||
$python setup.py install \
|
||||
--root=/ --prefix="$prefix"
|
||||
|
||||
packageEntries $pythonPackage \
|
||||
"$prefix"/lib/$python
|
||||
done
|
||||
}
|
||||
|
||||
@@ -1,29 +0,0 @@
|
||||
DESCRIPTION="PyChart is a Python library for creating high quality charts."
|
||||
HOMEPAGE="http://home.gna.org/pychart"
|
||||
SOURCE_URI="bzr+http://download.gna.org/pychart/bzr-archive"
|
||||
REVISION="1"
|
||||
STATUS_HAIKU="stable"
|
||||
DEPEND=""
|
||||
#CHECKSUM_MD5="f1f509a1c4623056c8e780bb7c9a05c5"
|
||||
BUILD()
|
||||
{
|
||||
cd pychart-1.39-bzr
|
||||
python setup.py config
|
||||
python setup.py build
|
||||
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
cd pychart-1.39-bzr
|
||||
python setup.py install --root=${DESTDIR}
|
||||
}
|
||||
|
||||
TEST()
|
||||
{
|
||||
cd pychart-1.39-bzr/demos
|
||||
make
|
||||
}
|
||||
|
||||
LICENSE="GNU GPL v2"
|
||||
COPYRIGHT="1999-2006 Yasushi Saito"
|
||||
Reference in New Issue
Block a user