cython_python-0.29.14.recipe revision 57c7dace
1SUMMARY="Optimising static compiler for Python"
2DESCRIPTION="Cython is an optimising static compiler for both the Python \
3programming language and the extended Cython programming language (based on \
4Pyrex). It makes writing C extensions for Python as easy as Python itself."
5HOMEPAGE="https://cython.org/"
6COPYRIGHT="2007-2018 Stefan Behnel, Robert Bradshaw, et al."
7LICENSE="Apache v2"
8REVISION="1"
9SOURCE_URI="https://github.com/cython/cython/archive/$portVersion.tar.gz"
10CHECKSUM_SHA256="6a3370fda27c020c172805c6257f222624bdd5f73653bb93f4af4e9f282d17f7"
11SOURCE_FILENAME="cython-$portVersion.tar.gz"
12SOURCE_DIR="cython-$portVersion"
13
14ARCHITECTURES="?x86_gcc2 x86 x86_64"
15
16PROVIDES="
17	cython_python = $portVersion
18	cmd:cygdb2
19	cmd:cygdb2.7
20	cmd:cython2
21	cmd:cython2.7
22	cmd:cythonize2
23	cmd:cythonize2.7
24"
25REQUIRES="
26	haiku
27	cmd:python2
28	"
29REPLACES="
30	python_cython
31	"
32
33BUILD_REQUIRES="
34	haiku_devel
35	setuptools_python
36	"
37BUILD_PREREQUIRES="
38	cmd:gcc
39	cmd:make
40	cmd:python2
41"
42
43BUILD()
44{
45	$portPackageLinksDir/cmd~python2/bin/python2 setup.py build
46}
47
48INSTALL()
49{
50	# GENERIC: all python_setuptools-based installs need this
51	pythonVersion=$(python2 --version 2>&1 | sed 's/Python //' | head -c3)
52	installLocation=$prefix/lib/python$pythonVersion/vendor-packages/
53	export PYTHONPATH=$installLocation:$PYTHONPATH
54	mkdir -p $installLocation
55
56	$portPackageLinksDir/cmd~python2/bin/python2 setup.py install \
57		--root=/ --prefix=$prefix --skip-build
58
59	for file in cygdb cython cythonize; \
60		do mv $binDir/$file $binDir/${file}2 ; \
61	done
62}
63