Gentoo Archives: gentoo-commits

From: Joonas Niilola <juippis@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-apps/bleachbit/
Date: Wed, 01 Apr 2020 14:38:07
Message-Id: 1585751852.a99484f44d5447410c3c25823746e7b103eafaf2.juippis@gentoo
1 commit: a99484f44d5447410c3c25823746e7b103eafaf2
2 Author: Christian Tietz <christian.tietz <AT> mailbox <DOT> org>
3 AuthorDate: Wed Mar 25 03:10:54 2020 +0000
4 Commit: Joonas Niilola <juippis <AT> gentoo <DOT> org>
5 CommitDate: Wed Apr 1 14:37:32 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a99484f4
7
8 sys-apps/bleachbit: Bump to 3.9.0 beta (Py3 port), implement tests
9
10 Tests require FEATURES=-usersandbox. Hence, restrict them.
11
12 Closes: https://bugs.gentoo.org/711962
13 Package-Manager: Portage-2.3.89, Repoman-2.3.20
14 Signed-off-by: Christian Tietz <christian.tietz <AT> mailbox.org>
15 Closes: https://github.com/gentoo/gentoo/pull/15102
16 Closes: https://github.com/gentoo/gentoo/pull/14902
17 Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>
18
19 sys-apps/bleachbit/Manifest | 1 +
20 sys-apps/bleachbit/bleachbit-3.9.0.ebuild | 78 +++++++++++++++++++++++++++++++
21 2 files changed, 79 insertions(+)
22
23 diff --git a/sys-apps/bleachbit/Manifest b/sys-apps/bleachbit/Manifest
24 index 9a75f2900af..f1f68a470f6 100644
25 --- a/sys-apps/bleachbit/Manifest
26 +++ b/sys-apps/bleachbit/Manifest
27 @@ -1 +1,2 @@
28 DIST bleachbit-3.0.tar.bz2 562646 BLAKE2B 4acdd5469ac1b36ff149231ad0b1b2e4e85a54a81c24c7751ceeed569526b905c1cc6be5201c4fb6929eb48e0553f0b27016de2584ee2f702492cc3fe659c2f9 SHA512 0d61f0b183c0d453275913741020c54c2915be9df45be706203e2278b125f4a02c75865117a7a2d587a034caa9bf109b2f498a4d522cc103c3879cc4a5d4854d
29 +DIST bleachbit-3.9.0.tar.bz2 578754 BLAKE2B cafce09ccc45e2a1b058730597571f4ef94672376e067b2b8f5fb6df674bac48ee7ad40cb52165b38afee0513e8b687f46d27264c562f863fe29d80d08093264 SHA512 bb93825b8dffdb62058315683fc3d3c77e0b0aa9adc2901be73abeae07667e15b91a4266c6ca7cecdfcf10cef8c179d8796b39dd76866ccddc0cd50e5e097bdc
30
31 diff --git a/sys-apps/bleachbit/bleachbit-3.9.0.ebuild b/sys-apps/bleachbit/bleachbit-3.9.0.ebuild
32 new file mode 100644
33 index 00000000000..1caaed30cb4
34 --- /dev/null
35 +++ b/sys-apps/bleachbit/bleachbit-3.9.0.ebuild
36 @@ -0,0 +1,78 @@
37 +# Copyright 1999-2020 Gentoo Authors
38 +# Distributed under the terms of the GNU General Public License v2
39 +
40 +EAPI=7
41 +
42 +PYTHON_COMPAT=( python3_{6,7} )
43 +PYTHON_REQ_USE="sqlite(+)"
44 +
45 +inherit desktop distutils-r1 virtualx
46 +
47 +DESCRIPTION="Clean junk to free disk space and to maintain privacy"
48 +HOMEPAGE="https://www.bleachbit.org"
49 +SRC_URI="https://download.bleachbit.org/beta/${PV}/${P}.tar.bz2"
50 +
51 +LICENSE="GPL-3"
52 +SLOT="0"
53 +KEYWORDS="~amd64 ~x86"
54 +
55 +RDEPEND="
56 + dev-python/chardet[$PYTHON_USEDEP]
57 + dev-python/pygobject:3[$PYTHON_USEDEP]
58 +"
59 +BDEPEND="
60 + sys-devel/gettext
61 + test? ( dev-python/mock[${PYTHON_USEDEP}] )
62 +"
63 +
64 +distutils_enable_tests unittest
65 +
66 +# tests fail under FEATURES=usersandbox
67 +RESTRICT+=" test"
68 +
69 +python_prepare_all() {
70 + if use test; then
71 + # avoid tests requiring internet access
72 + rm tests/Test{Chaff,Update}.py || die
73 +
74 + # fails due to non-existent $HOME/.profile
75 + rm tests/TestInit.py || die
76 +
77 + # permission error on $PORTAGE_TMPDIR
78 + sed -e "s/test_encoding(self)/_&/" \
79 + -i tests/TestCLI.py || die
80 +
81 + # fails on upstream Travis CI as well as on Gentoo
82 + sed -e "s/test_get_proc_swaps(self)/_&/" \
83 + -i tests/TestMemory.py || die
84 + fi
85 +
86 + distutils-r1_python_prepare_all
87 +}
88 +
89 +python_compile_all() {
90 + emake -C po local
91 +}
92 +
93 +python_install() {
94 + distutils-r1_python_install
95 + python_newscript ${PN}.py ${PN}
96 +}
97 +
98 +python_install_all() {
99 + distutils-r1_python_install_all
100 + emake -C po DESTDIR="${D}" install
101 +
102 + insinto /usr/share/bleachbit/cleaners
103 + doins cleaners/*.xml
104 +
105 + insinto /usr/share/bleachbit
106 + doins data/app-menu.ui
107 +
108 + doicon ${PN}.png
109 + domenu org.${PN}.BleachBit.desktop
110 +}
111 +
112 +python_test() {
113 + virtx emake tests
114 +}