From a6e899f0f859dfe868ff7a1164b178225d5dc1b9 Mon Sep 17 00:00:00 2001 From: Stephan Raue Date: Tue, 19 Oct 2010 20:30:31 +0200 Subject: [PATCH] feedparser: add distutilscross and distribute support Signed-off-by: Stephan Raue --- packages/python/web/feedparser/build | 10 ++++++++-- packages/python/web/feedparser/install | 1 + .../web/feedparser/patches/feedparser-setuptools.diff | 9 +++++++++ 3 files changed, 18 insertions(+), 2 deletions(-) create mode 100644 packages/python/web/feedparser/patches/feedparser-setuptools.diff diff --git a/packages/python/web/feedparser/build b/packages/python/web/feedparser/build index 670c515a80..833810c468 100755 --- a/packages/python/web/feedparser/build +++ b/packages/python/web/feedparser/build @@ -4,10 +4,16 @@ $SCRIPTS/build toolchain $SCRIPTS/build Python +$SCRIPTS/build distribute +$SCRIPTS/build distutilscross -. config/options.python +export PYTHONXCPREFIX="$SYSROOT_PREFIX/usr" +export LDFLAGS="$LDFLAGS -L$SYSROOT_PREFIX/usr/lib -L$SYSROOT_PREFIX/lib" cd $PKG_BUILD -$PYTHON setup.py install --prefix /usr --root .install + +python setup.py build --cross-compile +python setup.py install -O1 --skip-build --prefix /usr --root .install find .install -name "*.py" -exec rm -rf "{}" ";" +find .install -name "*.pyo" -exec rm -rf "{}" ";" diff --git a/packages/python/web/feedparser/install b/packages/python/web/feedparser/install index daa797322c..4d0a7235de 100755 --- a/packages/python/web/feedparser/install +++ b/packages/python/web/feedparser/install @@ -3,5 +3,6 @@ . config/options $1 $SCRIPTS/install Python +$SCRIPTS/install distribute cp -PR $PKG_BUILD/.install/* $INSTALL diff --git a/packages/python/web/feedparser/patches/feedparser-setuptools.diff b/packages/python/web/feedparser/patches/feedparser-setuptools.diff new file mode 100644 index 0000000000..2f80c162e1 --- /dev/null +++ b/packages/python/web/feedparser/patches/feedparser-setuptools.diff @@ -0,0 +1,9 @@ +diff -Naur feedparser-4.1/setup.py feedparser-4.1.patch/setup.py +--- feedparser-4.1/setup.py 2006-01-10 19:13:27.000000000 +0100 ++++ feedparser-4.1.patch/setup.py 2010-10-19 01:30:43.326660941 +0200 +@@ -1,4 +1,4 @@ +-from distutils.core import setup ++from setuptools import setup + + # patch distutils if it can't cope with the "classifiers" or "download_url" + # keywords (prior to python 2.3.0).