You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
127 lines
4.2 KiB
127 lines
4.2 KiB
## |
|
## python-www.spec -- OpenPKG RPM Package Specification |
|
## Copyright (c) 2000-2010 OpenPKG Foundation e.V. <http://openpkg.net/> |
|
## |
|
## Permission to use, copy, modify, and distribute this software for |
|
## any purpose with or without fee is hereby granted, provided that |
|
## the above copyright notice and this permission notice appear in all |
|
## copies. |
|
## |
|
## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED |
|
## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF |
|
## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. |
|
## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR |
|
## CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, |
|
## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT |
|
## LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF |
|
## USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND |
|
## ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, |
|
## OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT |
|
## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF |
|
## SUCH DAMAGE. |
|
## |
|
|
|
# package versions |
|
%define V_python 2.5 |
|
%define V_webpy 0.33 |
|
%define V_cheetah 2.2.1 |
|
%define V_genshi 0.5.1 |
|
%define V_html5lib 0.90 |
|
|
|
# package information |
|
Name: python-www |
|
Summary: Python Modules for World Wide Web |
|
URL: http://www.python.org/ |
|
Vendor: Python Community |
|
Packager: OpenPKG Foundation e.V. |
|
Distribution: OpenPKG Community |
|
Class: BASE |
|
Group: Language |
|
License: GPL |
|
Version: %{V_python} |
|
Release: 20100118 |
|
|
|
# list of sources |
|
Source0: http://webpy.org/static/web.py-%{V_webpy}.tar.gz |
|
Source1: http://switch.dl.sourceforge.net/cheetahtemplate/Cheetah-%{V_cheetah}.tar.gz |
|
Source2: http://ftp.edgewall.com/pub/genshi/Genshi-%{V_genshi}.tar.bz2 |
|
Source3: http://html5lib.googlecode.com/files/html5lib-%{V_html5lib}.zip |
|
|
|
# build information |
|
Prefix: %{l_prefix} |
|
BuildRoot: %{l_buildroot} |
|
BuildPreReq: OpenPKG, openpkg >= 20040130, python >= %{V_python}, infozip |
|
PreReq: OpenPKG, openpkg >= 20040130, python >= %{V_python} |
|
AutoReq: no |
|
AutoReqProv: no |
|
|
|
%description |
|
This is a set of Python extension modules for WWW. |
|
|
|
%track |
|
prog python-www:webpy = { |
|
version = %{V_webpy} |
|
url = http://webpy.org/ |
|
regex = web\.py-(__VER__)\.tar\.gz |
|
} |
|
prog python-www:cheetah = { |
|
version = %{V_cheetah} |
|
url = http://sourceforge.net/projects/cheetahtemplate/files/ |
|
regex = Cheetah-(__VER__)\.tar\.gz |
|
} |
|
prog python-www:genshi = { |
|
version = %{V_genshi} |
|
url = http://genshi.edgewall.org/wiki/Download |
|
regex = Genshi-(__VER__)\.tar\.bz2 |
|
} |
|
prog python-www:html5lib = { |
|
version = %{V_html5lib} |
|
url = http://code.google.com/p/html5lib/ |
|
regex = html5lib-(__VER__)\.zip |
|
} |
|
|
|
%prep |
|
%setup -q -c |
|
%setup -q -T -D -a 1 |
|
%setup -q -T -D -a 2 |
|
unzip -q -o -x %{SOURCE3} |
|
|
|
%build |
|
|
|
%install |
|
rm -rf $RPM_BUILD_ROOT |
|
( cd web.py-%{V_webpy} |
|
PYTHONPATH=$RPM_BUILD_ROOT%{l_prefix}/lib/python/site-packages \ |
|
%{l_prefix}/bin/python \ |
|
setup.py install \ |
|
--root=$RPM_BUILD_ROOT \ |
|
--prefix=%{l_prefix} |
|
) || exit $? |
|
( cd Cheetah-%{V_cheetah} |
|
PYTHONPATH=$RPM_BUILD_ROOT%{l_prefix}/lib/python/site-packages \ |
|
%{l_prefix}/bin/python \ |
|
setup.py install \ |
|
--root=$RPM_BUILD_ROOT \ |
|
--prefix=%{l_prefix} |
|
) || exit $? |
|
( cd Genshi-%{V_genshi} |
|
PYTHONPATH=$RPM_BUILD_ROOT%{l_prefix}/lib/python/site-packages \ |
|
%{l_prefix}/bin/python \ |
|
setup.py install \ |
|
--root=$RPM_BUILD_ROOT \ |
|
--prefix=%{l_prefix} |
|
) || exit $? |
|
( cd html5lib-%{V_html5lib} |
|
PYTHONPATH=$RPM_BUILD_ROOT%{l_prefix}/lib/python/site-packages \ |
|
%{l_prefix}/bin/python \ |
|
setup.py install \ |
|
--root=$RPM_BUILD_ROOT \ |
|
--prefix=%{l_prefix} |
|
) || exit $? |
|
%{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT %{l_files_std} |
|
|
|
%files -f files |
|
|
|
%clean |
|
rm -rf $RPM_BUILD_ROOT |
|
|
|
|