]> git.draconx.ca Git - gentoo-draconx.git/blob - media-plugins/gimp-python/gimp-python-2.10.32.ebuild
media-plugins/gimp-python: Remove python eclass usage.
[gentoo-draconx.git] / media-plugins / gimp-python / gimp-python-2.10.32.ebuild
1 # Copyright © 2020-2022 Nick Bowler
2 # License GPLv3+: GNU General Public License version 3 or any later version.
3 # This is free software: you are free to change and redistribute it.
4 # There is NO WARRANTY, to the extent permitted by law.
5
6 EAPI=8
7
8 inherit autotools
9
10 MY_P=${P/-python/}
11
12 DESCRIPTION="Python plugin support for GIMP"
13 HOMEPAGE="https://www.gimp.org/"
14 SRC_URI="mirror://gimp/v2.10/$MY_P.tar.bz2"
15
16 LICENSE="GPL-3+"
17 SLOT="0"
18 KEYWORDS="~amd64 ~x86"
19 IUSE="cpu_flags_ppc_altivec cpu_flags_x86_mmx cpu_flags_x86_sse"
20
21 DEPEND="dev-lang/python:2.7
22         >=media-gfx/gimp-$PV
23         >=dev-python/pycairo-1.0.2:2[python_targets_python2_7(+)]
24         >=dev-python/pygtk-2.10.4:2[python_targets_python2_7(+)]
25         !media-gfx/gimp[python(-)]"
26 RDEPEND=$DEPEND
27
28 S=$WORKDIR/$MY_P
29
30 PATCHES=(
31         "$FILESDIR/2.10.20-no-mypaint-brushes.patch"
32 )
33
34 src_prepare () {
35         sed -i '/^libgimp/s|[^ ]*/lib\(gimp[^-]*\)-[^ ]*\.la|-l\1-2.0|' \
36                 plug-ins/pygimp/Makefile.am
37
38         default
39
40         eautoreconf
41 }
42
43 src_configure () {
44         local myconf=(
45                 GDBUS_CODEGEN="/bin/false"
46                 GEGL="$EPREFIX/usr/bin/gegl-0.4"
47
48                 $(use_enable cpu_flags_ppc_altivec altivec)
49                 $(use_enable cpu_flags_x86_mmx mmx)
50                 $(use_enable cpu_flags_x86_sse sse)
51                 --enable-python
52                 PYTHON=python2.7
53         )
54
55         econf "${myconf[@]}"
56 }
57
58 src_compile () {
59         cd plug-ins/pygimp && emake
60 }
61
62 src_install () {
63         cd plug-ins/pygimp && emake DESTDIR="$D" install
64         find "$D" -name '*.la' -delete
65 }