dev-cpp/pangomm: stable 2.42.1 for hppa, bug #717144
[gentoo.git] / gnome-extra / cjs / cjs-4.4.0.ebuild
1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=6
5 inherit autotools gnome2 pax-utils virtualx
6
7 DESCRIPTION="Linux Mint's fork of gjs for Cinnamon"
8 HOMEPAGE="https://projects.linuxmint.com/cinnamon/"
9 SRC_URI="https://github.com/linuxmint/cjs/archive/${PV}.tar.gz -> ${P}.tar.gz"
10
11 LICENSE="MIT || ( MPL-1.1 LGPL-2+ GPL-2+ )"
12 SLOT="0"
13 IUSE="+cairo examples gtk test"
14 KEYWORDS="~amd64 ~x86"
15
16 RDEPEND="
17         dev-lang/spidermonkey:52
18         >=dev-libs/glib-2.42:2
19         >=dev-libs/gobject-introspection-1.41.4:=
20         sys-libs/readline:0=
21         dev-libs/libffi:0=
22         cairo? ( x11-libs/cairo[X,glib] )
23         gtk? ( x11-libs/gtk+:3 )
24 "
25 DEPEND="${RDEPEND}
26         sys-devel/gettext
27         virtual/pkgconfig
28         test? ( sys-apps/dbus )
29         sys-devel/autoconf-archive
30 "
31 # Cinnamon 2.2 does not work with this release.
32 RDEPEND="${RDEPEND}
33         !<gnome-extra/cinnamon-2.4
34 "
35
36 RESTRICT="test"
37
38 src_prepare() {
39         eautoreconf
40         gnome2_src_prepare
41
42         # Fixed in 4.6.0
43         sed -ie "s/Gjs-WARNING/Cjs-WARNING/g" \
44                 "${S}"/installed-tests/scripts/testCommandLine.sh || die
45
46         # Fixed in 4.6.0
47         sed -ie "s/40000/50000/g" \
48                 "${S}"/installed-tests/js/testSystem.js || die
49
50         sed -ie "s/'Gjs'/'Cjs'/g" \
51                 "${S}"/installed-tests/js/testExceptions.js \
52                 "${S}"/installed-tests/js/testEverythingBasic.js || die
53 }
54
55 src_configure() {
56         # FIXME: add systemtap/dtrace support, like in glib:2
57         # FIXME: --enable-systemtap installs files in ${D}/${D} for some reason
58         gnome2_src_configure \
59                 --disable-systemtap \
60                 --disable-dtrace \
61                 $(use_with cairo) \
62                 $(use_with gtk)
63 }
64
65 src_test() {
66         virtx emake check
67 }
68
69 src_install() {
70         # installation sometimes fails in parallel
71         gnome2_src_install -j1
72
73         if use examples; then
74                 docinto examples
75                 dodoc "${S}"/examples/*
76         fi
77
78         # Required for cjs-console to run correctly on PaX systems
79         pax-mark mr "${ED}/usr/bin/cjs-console"
80 }