source: projects/specs/trunk/p/python-sphinx/python-sphinx-vl.spec @ 1741

Revision 1741, 7.7 KB checked in by munepi, 14 years ago (diff)

NEW calibre: updated/added calibre's dependencies

Line 
1%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")}
2
3%global upstream_name Sphinx
4%global prerel b2
5
6Name:       python-sphinx
7Version:    1.0
8Release:    1.%{?prerel}%{?_dist_release}
9Summary:    Python documentation generator
10
11Group:      Development/Tools
12
13# Unless otherwise noted, the license for code is BSD
14# sphinx/util/stemmer.py Public Domain
15# sphinx/pycode/pgen2 Python
16# jquery (MIT or GPLv2)
17License: BSD and Public Domain and Python and (MIT or GPLv2)
18URL:        http://sphinx.pocoo.org/
19Source0:    http://pypi.python.org/packages/source/S/%{upstream_name}/%{upstream_name}-%{version}%{?prerel}.tar.gz
20
21BuildRoot:     %{_tmppath}/%{name}-%{version}-%{release}-root
22BuildArch:     noarch
23BuildRequires: python-devel >= 2.4
24BuildRequires: python-setuptools
25BuildRequires: python-docutils
26BuildRequires: python-jinja2
27BuildRequires: python-nose
28Requires:      python-docutils
29Requires:      python-jinja2
30Requires:      python-pygments
31
32
33%description
34Sphinx is a tool that makes it easy to create intelligent and
35beautiful documentation for Python projects (or other documents
36consisting of multiple reStructuredText sources), written by Georg
37Brandl. It was originally created to translate the new Python
38documentation, but has now been cleaned up in the hope that it will be
39useful to many other projects.
40
41Sphinx uses reStructuredText as its markup language, and many of its
42strengths come from the power and straightforwardness of
43reStructuredText and its parsing and translating suite, the Docutils.
44
45Although it is still under constant development, the following
46features are already present, work fine and can be seen "in action" in
47the Python docs:
48
49    * Output formats: HTML (including Windows HTML Help) and LaTeX,
50      for printable PDF versions
51    * Extensive cross-references: semantic markup and automatic links
52      for functions, classes, glossary terms and similar pieces of
53      information
54    * Hierarchical structure: easy definition of a document tree, with
55      automatic links to siblings, parents and children
56    * Automatic indices: general index as well as a module index
57    * Code handling: automatic highlighting using the Pygments highlighter
58    * Various extensions are available, e.g. for automatic testing of
59      snippets and inclusion of appropriately formatted docstrings.
60
61
62%package doc
63Summary:    Documentation for %{name}
64Group:      Documentation
65License:    BSD
66Requires:   %{name} = %{version}-%{release}
67
68
69%description doc
70Sphinx is a tool that makes it easy to create intelligent and
71beautiful documentation for Python projects (or other documents
72consisting of multiple reStructuredText sources), written by Georg
73Brandl. It was originally created to translate the new Python
74documentation, but has now been cleaned up in the hope that it will be
75useful to many other projects.
76
77This package contains documentation in reST and HTML formats.
78
79
80%prep
81%setup -q -n %{upstream_name}-%{version}%{?prerel}
82%__sed '1d' -i sphinx/pycode/pgen2/token.py
83
84%build
85%{__python} setup.py build
86pushd doc
87%__make html
88%__rm -rf _build/html/.buildinfo
89%__mv _build/html ..
90%__rm -rf _*
91popd
92
93
94%install
95%__rm -rf %{buildroot}
96
97%{__python} setup.py install --skip-build --root %{buildroot}
98
99
100# Manpages not in beta release yet
101#pushd doc
102# Deliver man pages
103#install -d %{buildroot}%{_mandir}/man1
104#mv sphinx-*.1 %{buildroot}%{_mandir}/man1/
105#popd
106
107# Deliver rst files
108%__mv doc reST
109
110# Move language files to /usr/share in association with %patch1
111pushd %{buildroot}%{python_sitelib}
112
113for lang in `find sphinx/locale -maxdepth 1 -mindepth 1 -type d -printf "%f "`;
114do
115  install -d %{buildroot}%{_datadir}/sphinx/locale/$lang
116  install -d %{buildroot}%{_datadir}/locale/$lang/LC_MESSAGES
117  %__mv sphinx/locale/$lang/LC_MESSAGES/sphinx.js \
118     %{buildroot}%{_datadir}/sphinx/locale/$lang/
119  %__mv sphinx/locale/$lang/LC_MESSAGES/sphinx.mo \
120    %{buildroot}%{_datadir}/locale/$lang/LC_MESSAGES/
121  %__rm -rf sphinx/locale/$lang
122done
123popd
124%find_lang sphinx
125
126# Language files; Since these are javascript, it's not immediately obvious to
127# find_lang that they need to be marked with a language.
128(cd %{buildroot} && find . -name 'sphinx.js') | %__sed -e 's|^.||' | %__sed -e \
129  's:\(.*/locale/\)\([^/_]\+\)\(.*\.js$\):%lang(\2) \1\2\3:' \
130  >> sphinx.lang
131
132
133%clean
134%__rm -rf %{buildroot}
135
136
137%check
138%__make test
139
140
141%files -f sphinx.lang
142%defattr(-,root,root,-)
143%doc AUTHORS CHANGES EXAMPLES LICENSE README TODO
144%{_bindir}/sphinx-*
145%{python_sitelib}/*
146%{_datadir}/sphinx/
147%exclude %{_datadir}/sphinx/locale/*/sphinx.js
148#%{_mandir}/man1/*
149
150%files doc
151%defattr(-,root,root,-)
152%doc html reST
153
154
155%changelog
156* Mon Aug 23 2010 Munehiro Yamamoto <munepi@vinelinux.org> 1.0-1.b2
157- initial build based on Fedora development
158
159* Thu Jul 22 2010 David Malcolm <dmalcolm@redhat.com> - 1.0-0.1.b2.1
160- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
161
162* Mon May 31 2010 Toshio Kuratomi <toshio@fedoraproject.org> - 1.0-0.2.b2
163- Update to 1.0 beta 2
164- Fixes problem building html documentation in non-English locales
165
166* Wed May 26 2010 Michel Salim <salimma@fedoraproject.org> - 1.0-0.1.b1
167- Update to 1.0 beta 1
168
169* Tue May 25 2010 Michel Salim <salimma@fedoraproject.org> - 0.6.6-1
170- Update to 0.6.6
171
172* Fri May 21 2010 Toshio Kuratomi <toshio@fedoraproject.org> - 0.6.5-2
173- Few minor tweaks to Gareth's spec file update
174
175* Mon May 10 2010 Gareth Armstrong <gareth.armstrong@hp.com> - 0.6.5-1.hp
176- Update to 0.6.5
177- Initial import of python-sphinx from Fedora Rawhide for use in HP CMS
178- Enforce that Sphinx requires Python 2.4 or later via an explicit BR
179- Minor tweaks to spec file
180- Move language files to %%{_datadir}, idea borrowed from Debian's sphinx
181  package
182- Deliver man pages for sphinx-build & sphinx-quickstart
183- Deliver rst documentation files to reST directory in doc sub-package
184- Add %%check section for Python2 and add BR on python-nose
185
186* Wed Jan 13 2010 Toshio Kuratomi <toshio@fedoraproject.org> - 0.6.4-1
187- Update to 0.6.4
188- Fixes a problem using autodoc with pylons projects.
189
190* Fri Sep  4 2009 Michel Salim <salimma@fedoraproject.org> - 0.6.3-1
191- Update to 0.6.3
192
193* Mon Aug 17 2009 Toshio Kuratomi <toshio@fedoraproject.org> - 0.6.2-1
194- Update to 0.6.2 -- upstream bugfix requested inside bz#512438
195
196* Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6.1-3
197- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
198
199* Fri Jun 05 2009 Luke Macken <lmacken@redhat.com> - 0.6.1-2
200- Add a patch to use our own setuptools package
201
202* Fri Apr 17 2009 Michel Salim <salimma@fedoraproject.org> - 0.6.1-1
203- Update to 0.6.1
204
205* Thu Feb 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.5.1-2
206- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
207
208* Fri Jan  2 2009 Michel Salim <salimma@fedoraproject.org> - 0.5.1-1
209- Update to 0.5.1
210
211* Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 0.5-2
212- Rebuild for Python 2.6
213
214* Mon Nov 24 2008 Michel Salim <salimma@fedoraproject.org> - 0.5-1
215- Update to 0.5
216
217* Fri Oct 10 2008 Michel Salim <salimma@fedoraproject.org> - 0.4.3-1
218- Update to 0.4.3
219
220* Wed Aug 27 2008 Toshio Kuratomi <toshio@fedoraproject.org> - 0.4.2-1.1
221- Fix for EL-5 build.
222
223* Mon Aug 25 2008 Michel Salim <salimma@fedoraproject.org> - 0.4.2-1
224- Update to 0.4.2
225
226* Mon May 26 2008 Michel Salim <salimma@fedoraproject.org> - 0.3-1
227- Update to 0.3
228
229* Fri May  2 2008 Michel Salim <salimma@fedoraproject.org> - 0.1.61950-3
230- Split documentation into subpackage
231- Exclude C files (not built by default anyway)
232
233* Wed Apr 16 2008 José Matos <jamatos@fc.up.pt> - 0.1.61950-2
234- Build html documentation, include it and include the rst
235  documentation.
236
237* Thu Mar 27 2008 Michel Salim <michel.sylvan@gmail.com> 0.1.61950-1
238- Initial package
Note: See TracBrowser for help on using the repository browser.