Gentoo Archives: gentoo-commits

From: "Ryan Hill (dirtyepic)" <dirtyepic@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in dev-python/wxpython: ChangeLog wxpython-2.8.9.1.ebuild
Date: Tue, 14 Oct 2008 05:59:51
Message-Id: E1Kpcwe-0007nP-EG@stork.gentoo.org
1 dirtyepic 08/10/14 05:59:48
2
3 Modified: ChangeLog
4 Added: wxpython-2.8.9.1.ebuild
5 Log:
6 Version bump. EAPI 2. New cairo USE flag.
7 (Portage version: 2.2_rc12/cvs/Linux 2.6.26-gentoo-r1 x86_64)
8
9 Revision Changes Path
10 1.99 dev-python/wxpython/ChangeLog
11
12 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-python/wxpython/ChangeLog?rev=1.99&view=markup
13 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-python/wxpython/ChangeLog?rev=1.99&content-type=text/plain
14 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-python/wxpython/ChangeLog?r1=1.98&r2=1.99
15
16 Index: ChangeLog
17 ===================================================================
18 RCS file: /var/cvsroot/gentoo-x86/dev-python/wxpython/ChangeLog,v
19 retrieving revision 1.98
20 retrieving revision 1.99
21 diff -u -r1.98 -r1.99
22 --- ChangeLog 4 Oct 2008 12:33:38 -0000 1.98
23 +++ ChangeLog 14 Oct 2008 05:59:48 -0000 1.99
24 @@ -1,6 +1,11 @@
25 # ChangeLog for dev-python/wxpython
26 # Copyright 2002-2008 Gentoo Foundation; Distributed under the GPL v2
27 -# $Header: /var/cvsroot/gentoo-x86/dev-python/wxpython/ChangeLog,v 1.98 2008/10/04 12:33:38 ranger Exp $
28 +# $Header: /var/cvsroot/gentoo-x86/dev-python/wxpython/ChangeLog,v 1.99 2008/10/14 05:59:48 dirtyepic Exp $
29 +
30 +*wxpython-2.8.9.1 (14 Oct 2008)
31 +
32 + 14 Oct 2008; Ryan Hill <dirtyepic@g.o> +wxpython-2.8.9.1.ebuild:
33 + Version bump. EAPI 2. New cairo USE flag.
34
35 04 Oct 2008; Brent Baude <ranger@g.o> wxpython-2.6.4.0-r2.ebuild:
36 stable ppc64, bug 238437
37
38
39
40 1.1 dev-python/wxpython/wxpython-2.8.9.1.ebuild
41
42 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-python/wxpython/wxpython-2.8.9.1.ebuild?rev=1.1&view=markup
43 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-python/wxpython/wxpython-2.8.9.1.ebuild?rev=1.1&content-type=text/plain
44
45 Index: wxpython-2.8.9.1.ebuild
46 ===================================================================
47 # Copyright 1999-2008 Gentoo Foundation
48 # Distributed under the terms of the GNU General Public License v2
49 # $Header: /var/cvsroot/gentoo-x86/dev-python/wxpython/wxpython-2.8.9.1.ebuild,v 1.1 2008/10/14 05:59:48 dirtyepic Exp $
50
51 EAPI="2"
52 WX_GTK_VER="2.8"
53
54 inherit alternatives eutils multilib python wxwidgets flag-o-matic
55 # We don't use distutils.eclass because it doesn't seem to play nice with
56 # need-wxwidgets
57
58 MY_P="${P/wxpython-/wxPython-src-}"
59 DESCRIPTION="A blending of the wxWindows C++ class library with Python"
60 HOMEPAGE="http://www.wxpython.org/"
61 SRC_URI="mirror://sourceforge/wxpython/${MY_P}.tar.bz2"
62
63 LICENSE="wxWinLL-3"
64 SLOT="2.8"
65 KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86"
66 IUSE="cairo opengl"
67
68 RDEPEND=">=x11-libs/wxGTK-${PV}:2.8[opengl?]
69 >=x11-libs/gtk+-2.4
70 >=x11-libs/pango-1.2
71 >=dev-libs/glib-2.0
72 media-libs/libpng
73 media-libs/jpeg
74 media-libs/tiff
75 cairo? ( dev-python/pycairo )
76 opengl? ( >=dev-python/pyopengl-2.0.0.44 )"
77
78 DEPEND="${RDEPEND}
79 dev-util/pkgconfig
80 >=dev-lang/python-2.4"
81
82 S="${WORKDIR}/${MY_P}/wxPython/"
83
84 src_prepare() {
85 sed -i "s:cflags.append('-O3'):pass:" config.py || die "sed failed"
86 epatch "${FILESDIR}"/${PN}-2.8.8-wxversion-scripts.patch
87 }
88
89 src_configure() {
90 local mypyconf
91
92 need-wxwidgets unicode
93
94 append-flags -fno-strict-aliasing
95
96 use opengl \
97 && mypyconf="${mypyconf} BUILD_GLCANVAS=1" \
98 || mypyconf="${mypyconf} BUILD_GLCANVAS=0"
99
100 mypyconf="${mypyconf} WX_CONFIG=${WX_CONFIG}"
101 mypyconf="${mypyconf} WXPORT=gtk2 UNICODE=1"
102 }
103
104 src_compile() {
105 python setup.py ${mypyconf} build || die "setup.py build failed"
106 }
107
108 src_install() {
109 local mypyconf
110 python_version
111 local site_pkgs=/usr/$(get_libdir)/python${PYVER}/site-packages
112
113 mypyconf="${mypyconf} WX_CONFIG=${WX_CONFIG}"
114 use opengl \
115 && mypyconf="${mypyconf} BUILD_GLCANVAS=1" \
116 || mypyconf="${mypyconf} BUILD_GLCANVAS=0"
117
118 mypyconf="${mypyconf} WXPORT=gtk2 UNICODE=1"
119
120 python setup.py ${mypyconf} install --root="${D}" \
121 --install-purelib ${site_pkgs} || die "setup.py install failed"
122
123 # Collision protection.
124 for file in "${D}"/usr/bin/* "${D}"/${site_pkgs}/wx{version.*,.pth}; do
125 mv "${file}" "${file}-${SLOT}"
126 done
127
128 for dir in "${D}"/${site_pkgs}/wx-${SLOT}-gtk2-{ansi,unicode}; do
129 if [[ -d ${dir} ]]; then
130 cp -R "${D}"/${site_pkgs}/wxaddons/ "${dir}"
131 wxaddons_copied=1
132 fi
133 done
134
135 [[ ${wxaddons_copied} ]] && rm -rf "${D}"/${site_pkgs}/wxaddons/
136 }
137
138 pkg_postinst() {
139 local site_pkgs=/usr/$(get_libdir)/python${PYVER}/site-packages
140
141 python_mod_optimize ${site_pkgs}
142
143 alternatives_auto_makesym \
144 "${site_pkgs}/wx.pth" "${site_pkgs}/wx.pth-[0-9].[0-9]"
145 alternatives_auto_makesym \
146 "${site_pkgs}/wxversion.py" "${site_pkgs}/wxversion.py-[0-9].[0-9]"
147
148 echo
149 elog "Gentoo uses the Multi-version method for SLOT'ing."
150 elog "Developers see this site for instructions on using 2.6 or 2.8"
151 elog "with your apps:"
152 elog "http://wiki.wxpython.org/index.cgi/MultiVersionInstalls"
153 echo
154 }
155
156 pkg_postrm() {
157 python_mod_cleanup
158
159 local site_pkgs=/usr/$(get_libdir)/python${PYVER}/site-packages
160
161 alternatives_auto_makesym \
162 "${site_pkgs}/wx.pth" "${site_pkgs}/wx.pth-[0-9].[0-9]"
163 alternatives_auto_makesym \
164 "${site_pkgs}/wxversion.py" "${site_pkgs}/wxversion.py-[0-9].[0-9]"
165 }