SUMMARY="A generic syntax highlighter" DESCRIPTION="It is a generic syntax highlighter for general use in all kinds \ of software such as forum systems, wikis or other applications that need to \ prettify source code. Highlights are: * a wide range of common languages and markup formats is supported * special attention is paid to details that increase highlighting quality * support for new languages and formats are added easily; most languages use a \ simple regex-based lexing mechanism * a number of output formats is available, among them HTML, RTF, LaTeX and \ ANSI sequences * it is usable as a command-line tool and as a library * ... and it highlights even Brainf*ck!" HOMEPAGE="http://pygments.org/" COPYRIGHT="2006-2013 by the Pygments team" LICENSE="BSD (2-clause)" REVISION="1" SOURCE_URI="https://pypi.python.org/packages/71/2a/2e4e77803a8bd6408a2903340ac498cb0a2181811af7c9ec92cb70b0308a/Pygments-$portVersion.tar.gz" CHECKSUM_SHA256="dbae1046def0efb574852fab9e90209b23f556367b5a320c0bcb871c77c3e8cc" SOURCE_DIR="Pygments-$portVersion" ARCHITECTURES="any" PROVIDES=" $portName = $portVersion " REQUIRES=" haiku " BUILD_REQUIRES=" haiku_devel " 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\ \"; \ REQUIRES_$pythonPackage=\"\ haiku\n\ cmd:python$pythonVersion\ \"" BUILD_REQUIRES="$BUILD_REQUIRES setuptools_$pythonPackage" BUILD_PREREQUIRES="$BUILD_PREREQUIRES cmd:python$pythonVersion" done PROVIDES_python="$PROVIDES_python cmd:pygmentize = $portVersion " PROVIDES_python3="$PROVIDES_python3 cmd:pygmentize3 = $portVersion " 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 if [ $pythonPackage != python ]; then mv $binDir/pygmentize $binDir/pygmentize3 fi packageEntries $pythonPackage \ $prefix/lib/python* \ $binDir done }