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 media-libs/ming: ming-0.4.3.ebuild
Date: Tue, 20 Apr 2010 23:49:44
Message-Id: 20100420234939.E0E2B2C04B@corvid.gentoo.org
1 arfrever 10/04/20 23:49:39
2
3 Modified: ming-0.4.3.ebuild
4 Log:
5 Simplify ebuild.
6 (Portage version: HEAD/cvs/Linux x86_64)
7
8 Revision Changes Path
9 1.3 media-libs/ming/ming-0.4.3.ebuild
10
11 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/media-libs/ming/ming-0.4.3.ebuild?rev=1.3&view=markup
12 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/media-libs/ming/ming-0.4.3.ebuild?rev=1.3&content-type=text/plain
13 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/media-libs/ming/ming-0.4.3.ebuild?r1=1.2&r2=1.3
14
15 Index: ming-0.4.3.ebuild
16 ===================================================================
17 RCS file: /var/cvsroot/gentoo-x86/media-libs/ming/ming-0.4.3.ebuild,v
18 retrieving revision 1.2
19 retrieving revision 1.3
20 diff -u -r1.2 -r1.3
21 --- ming-0.4.3.ebuild 20 Apr 2010 23:37:26 -0000 1.2
22 +++ ming-0.4.3.ebuild 20 Apr 2010 23:49:39 -0000 1.3
23 @@ -1,13 +1,13 @@
24 # Copyright 1999-2010 Gentoo Foundation
25 # Distributed under the terms of the GNU General Public License v2
26 -# $Header: /var/cvsroot/gentoo-x86/media-libs/ming/ming-0.4.3.ebuild,v 1.2 2010/04/20 23:37:26 mabi Exp $
27 +# $Header: /var/cvsroot/gentoo-x86/media-libs/ming/ming-0.4.3.ebuild,v 1.3 2010/04/20 23:49:39 arfrever Exp $
28
29 -EAPI=1
30 +EAPI="3"
31
32 PHP_EXT_NAME=ming
33 PYTHON_DEPEND="python? 2"
34
35 -inherit eutils autotools flag-o-matic multilib php-ext-source-r1 perl-module distutils python
36 +inherit eutils autotools flag-o-matic multilib php-ext-source-r1 perl-module python
37
38 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd"
39 DESCRIPTION="An Open Source library for Flash movie generation."
40 @@ -28,20 +28,16 @@
41
42 S=${WORKDIR}/${P/_/.}
43
44 -#Tests only work when the package is tested on a system
45 -#which does not presently have any version of ming installed.
46 +# Tests only work when the package is tested on a system
47 +# which does not presently have any version of ming installed.
48 RESTRICT="test"
49 -RESTRICT_PYTHON_ABIS="3"
50
51 pkg_setup() {
52 use python && python_set_active_version 2
53 }
54
55 -src_unpack() {
56 - unpack ${A}
57 - cd "${S}"
58 -
59 - #Let's get rid of the TEXTRELS, link dynamic. Use gif.
60 +src_prepare() {
61 + # Let's get rid of the TEXTRELS, link dynamic. Use gif.
62 sed -i \
63 -e 's/libming.a/libming.so/' \
64 -e 's/lungif/lgif/' \
65 @@ -59,12 +55,14 @@
66 eautoreconf
67 }
68
69 -src_compile() {
70 +src_configure() {
71 # build is sensitive to -O3 (bug #297437)
72 replace-flags -O3 -O2
73
74 - econf $(use_enable perl) \
75 - $(use_enable python) || die "econf failed"
76 + econf $(use_enable perl) $(use_enable python)
77 +}
78 +
79 +src_compile() {
80 emake -j1 DESTDIR="${D}" || die "emake failed"
81
82 if use php; then
83 @@ -85,8 +83,8 @@
84
85 fixlocalpod
86
87 - #Get rid of the precompiled stuff, we generate it later.
88 - rm -f $(find "${D}" -name '*.pyc')
89 + # Get rid of the precompiled stuff, we generate it later.
90 + find "${ED}" -name "*.pyc" -print0 | xargs -0 rm -f
91
92 if use php; then
93 cd "${S}"/php_ext
94 @@ -96,18 +94,7 @@
95
96 pkg_postinst() {
97 use perl && perl-module_pkg_postinst
98 -
99 - if use python
100 - then
101 - ebegin "Compiling ming.py"
102 - python_mod_compile $(python_get_sitedir)/ming.py \
103 - || die "Failed to compile ming.py"
104 - eend $?
105 -
106 - ebegin "Compiling mingc.py"
107 - python_mod_compile $(python_get_sitedir)/mingc.py || die "mingc.py failed"
108 - eend $?
109 - fi
110 + use python && python_mod_optimize ming.py mingc.py
111 }
112
113 pkg_prerm() {
114 @@ -116,5 +103,5 @@
115
116 pkg_postrm() {
117 use perl && perl-module_pkg_postrm
118 - use python && distutils_pkg_postrm
119 + use python && python_mod_cleanup ming.py mingc.py
120 }