Gentoo Archives: gentoo-commits

From: "Arfrever Frehtes Taifersar Arahesis (arfrever)" <arfrever@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in dev-python/docutils: ChangeLog docutils-0.7_pre6334.ebuild
Date: Wed, 02 Jun 2010 18:20:48
Message-Id: 20100602182042.197FD2CE14@corvid.gentoo.org
1 arfrever 10/06/02 18:20:41
2
3 Modified: ChangeLog
4 Added: docutils-0.7_pre6334.ebuild
5 Log:
6 Version bump. Reenable support for Python 3 (bug #304641).
7 (Portage version: HEAD/cvs/Linux x86_64)
8
9 Revision Changes Path
10 1.112 dev-python/docutils/ChangeLog
11
12 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-python/docutils/ChangeLog?rev=1.112&view=markup
13 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-python/docutils/ChangeLog?rev=1.112&content-type=text/plain
14 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-python/docutils/ChangeLog?r1=1.111&r2=1.112
15
16 Index: ChangeLog
17 ===================================================================
18 RCS file: /var/cvsroot/gentoo-x86/dev-python/docutils/ChangeLog,v
19 retrieving revision 1.111
20 retrieving revision 1.112
21 diff -u -r1.111 -r1.112
22 --- ChangeLog 30 May 2010 18:49:38 -0000 1.111
23 +++ ChangeLog 2 Jun 2010 18:20:41 -0000 1.112
24 @@ -1,6 +1,12 @@
25 # ChangeLog for dev-python/docutils
26 # Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
27 -# $Header: /var/cvsroot/gentoo-x86/dev-python/docutils/ChangeLog,v 1.111 2010/05/30 18:49:38 armin76 Exp $
28 +# $Header: /var/cvsroot/gentoo-x86/dev-python/docutils/ChangeLog,v 1.112 2010/06/02 18:20:41 arfrever Exp $
29 +
30 +*docutils-0.7_pre6334 (02 Jun 2010)
31 +
32 + 02 Jun 2010; Arfrever Frehtes Taifersar Arahesis <arfrever@g.o>
33 + +docutils-0.7_pre6334.ebuild:
34 + Version bump. Reenable support for Python 3 (bug #304641).
35
36 30 May 2010; Raúl Porcel <armin76@g.o> docutils-0.6.ebuild:
37 alpha/arm/ia64/s390/sh/sparc stable wrt #318111
38
39
40
41 1.1 dev-python/docutils/docutils-0.7_pre6334.ebuild
42
43 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-python/docutils/docutils-0.7_pre6334.ebuild?rev=1.1&view=markup
44 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-python/docutils/docutils-0.7_pre6334.ebuild?rev=1.1&content-type=text/plain
45
46 Index: docutils-0.7_pre6334.ebuild
47 ===================================================================
48 # Copyright 1999-2010 Gentoo Foundation
49 # Distributed under the terms of the GNU General Public License v2
50 # $Header: /var/cvsroot/gentoo-x86/dev-python/docutils/docutils-0.7_pre6334.ebuild,v 1.1 2010/06/02 18:20:41 arfrever Exp $
51
52 EAPI="3"
53 SUPPORT_PYTHON_ABIS="1"
54
55 inherit distutils eutils
56
57 DESCRIPTION="Set of python tools for processing plaintext docs into HTML, XML, etc..."
58 HOMEPAGE="http://docutils.sourceforge.net/ http://pypi.python.org/pypi/docutils"
59 SRC_URI="mirror://gentoo/${P}.tar.bz2
60 glep? ( mirror://gentoo/glep-0.4-r1.tbz2 )"
61 #mirror://sourceforge/docutils/${P}.tar.gz
62
63 LICENSE="public-domain PYTHON BSD"
64 SLOT="0"
65 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~sparc-fbsd ~x86-fbsd ~x86-freebsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x86-solaris"
66 IUSE="glep emacs"
67
68 DEPEND="dev-python/setuptools"
69 RDEPEND=""
70 # Emacs support is in PDEPEND to avoid a dependency cycle (bug #183242)
71 PDEPEND="emacs? ( || ( >=app-emacs/rst-0.4 >=virtual/emacs-23 ) )"
72
73 DOCS="*.txt"
74
75 GLEP_SRC="${WORKDIR}/glep-0.4-r1"
76
77 src_prepare() {
78 # Delete internal copies of optparse and textwrap modules.
79 rm -f extras/{optparse.py,textwrap.py}
80 # Fix installation of extra modules.
81 epatch "${FILESDIR}/${PN}-0.6-extra_modules.patch"
82
83 sed -e "s/from distutils.core/from setuptools/" -i setup.py || die "sed setup.py failed"
84 }
85
86 src_compile() {
87 distutils_src_compile
88
89 # Generate html docs from reStructured text sources.
90
91 # Make roman.py available for the doc building process
92 ln -s extras/roman.py
93
94 # Place html4css1.css in base directory. This makes sure the
95 # generated reference to it is correct.
96 cp docutils/writers/html4css1/html4css1.css .
97
98 pushd tools > /dev/null
99
100 echo PYTHONPATH="../build-$(PYTHON -f --ABI)/lib" "$(PYTHON -f)" $([[ -f ../build-$(PYTHON -f --ABI)/lib/tools/buildhtml.py ]] && echo ../build-$(PYTHON -f --ABI)/lib/tools/buildhtml.py || echo ../tools/buildhtml.py) --stylesheet-path=../html4css1.css --traceback ..
101 PYTHONPATH="../build-$(PYTHON -f --ABI)/lib" "$(PYTHON -f)" $([[ -f ../build-$(PYTHON -f --ABI)/lib/tools/buildhtml.py ]] && echo ../build-$(PYTHON -f --ABI)/lib/tools/buildhtml.py || echo ../tools/buildhtml.py) --stylesheet-path=../html4css1.css --traceback .. || die "buildhtml.py failed"
102
103 popd > /dev/null
104
105 # Clean up after the doc building.
106 rm roman.py html4css1.css
107 }
108
109 src_test() {
110 testing() {
111 echo PYTHONPATH="build-${PYTHON_ABI}/lib" "$(PYTHON)" $([[ -f build-${PYTHON_ABI}/lib/test/alltests.py ]] && echo build-${PYTHON_ABI}/lib/test/alltests.py || echo test/alltests.py)
112 PYTHONPATH="build-${PYTHON_ABI}/lib" "$(PYTHON)" $([[ -f build-${PYTHON_ABI}/lib/test/alltests.py ]] && echo build-${PYTHON_ABI}/lib/test/alltests.py || echo test/alltests.py)
113 }
114 python_execute_function testing
115 }
116
117 install_txt_doc() {
118 local doc="${1}"
119 local dir="txt/$(dirname ${doc})"
120 docinto "${dir}"
121 dodoc "${doc}"
122 }
123
124 src_install() {
125 distutils_src_install
126
127 # Tools
128 cd tools
129 for tool in *.py; do
130 dobin "${tool}"
131 done
132
133 # Docs
134 cd "${S}"
135 dohtml -r docs tools
136 # Manually install the stylesheet file
137 insinto /usr/share/doc/${PF}/html
138 doins docutils/writers/html4css1/html4css1.css
139 for doc in $(find docs tools -name "*.txt"); do
140 install_txt_doc "${doc}"
141 done
142
143 # installing Gentoo GLEP tools. Uses versioned GLEP distribution
144 if use glep; then
145 dobin ${GLEP_SRC}/glep.py || die "dobin failed"
146
147 installation_of_glep_tools() {
148 insinto $(python_get_sitedir)/docutils/readers
149 newins ${GLEP_SRC}/glepread.py glep.py || die "newins reader failed"
150 insinto $(python_get_sitedir)/docutils/transforms
151 newins ${GLEP_SRC}/glepstrans.py gleps.py || die "newins transform failed"
152 insinto $(python_get_sitedir)/docutils/writers
153 doins -r ${GLEP_SRC}/glep_html || die "doins writer failed"
154 }
155 python_execute_function --action-message 'Installation of GLEP tools with $(python_get_implementation) $(python_get_version)...' installation_of_glep_tools
156 fi
157 }
158
159 pkg_postinst() {
160 python_mod_optimize docutils roman.py
161 }
162
163 pkg_postrm() {
164 python_mod_cleanup docutils roman.py
165 }