mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-09 21:30:08 +02:00
Add recipe for dateutil 1.5
- the magic is in --single-version-externally-managed to disable those (easter) egg things... cf. https://wiki.debian.org/Python/FAQ#How_should_we_package_Python_eggs.3F - --root is required so just pass / - also, python must be called without any path, else it setuptools uses it as an extra prefix for install... so we munge PATH and call python.
This commit is contained in:
56
dev-python/python_dateutil/python_dateutil-1.5.recipe
Normal file
56
dev-python/python_dateutil/python_dateutil-1.5.recipe
Normal file
@@ -0,0 +1,56 @@
|
||||
SUMMARY="Extensions to the standard Python datetime module"
|
||||
DESCRIPTION="
|
||||
The dateutil module provides powerful extensions to the \
|
||||
standard datetime module, available in Python 2.3+.
|
||||
"
|
||||
HOMEPAGE="http://labix.org/python-dateutil"
|
||||
SRC_URI="http://labix.org/download/python-dateutil/python-dateutil-1.5.tar.gz"
|
||||
CHECKSUM_SHA256="c08aca7d85f8f8eed61e83b3423b829262c596a9a78f7ca3de0bcee2217d0e3b"
|
||||
#FIXME: check exact license
|
||||
#XXX: 2.0 is "simplified BSD" (which one ?)
|
||||
LICENSE="Python"
|
||||
COPYRIGHT="2003-2010 Gustavo Niemeyer"
|
||||
REVISION="1"
|
||||
|
||||
ARCHITECTURES="x86 x86_gcc2 x86_64"
|
||||
|
||||
SOURCE_DIR="python-dateutil-$portVersion"
|
||||
|
||||
PROVIDES="
|
||||
python_dateutil = $portVersion
|
||||
"
|
||||
|
||||
REQUIRES="
|
||||
haiku >= $haikuVersion
|
||||
cmd:python
|
||||
#python_setuptools
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku_devel >= $haikuVersion
|
||||
python_setuptools
|
||||
"
|
||||
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:python
|
||||
cmd:gcc
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
$portPackageLinksDir/cmd~python/bin/python setup.py build
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
# GENERIC: all python_setuptools-based installs need this
|
||||
export PATH="$portPackageLinksDir/cmd~python/bin:$PATH"
|
||||
pythonVersion=$(python --version 2>&1 | sed 's/Python //' | head -c3)
|
||||
installLocation=$prefix/lib/python$pythonVersion/vendor-packages/
|
||||
export PYTHONPATH=$installLocation:$PYTHONPATH
|
||||
mkdir -p $installLocation
|
||||
|
||||
python setup.py install \
|
||||
--single-version-externally-managed \
|
||||
--root=/ --prefix=$prefix
|
||||
}
|
||||
Reference in New Issue
Block a user