Gentoo Archives: gentoo-commits

From: Ian Delaney <idella4@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: net-p2p/classified-ads/
Date: Tue, 03 May 2016 03:42:07
Message-Id: 1462246904.a7a6d00357859094ff31fcbaf4eba09de9360022.idella4@gentoo
1 commit: a7a6d00357859094ff31fcbaf4eba09de9360022
2 Author: Antti Jarvinen <antti.jarvinen <AT> katiska <DOT> org>
3 AuthorDate: Tue Apr 26 20:59:19 2016 +0000
4 Commit: Ian Delaney <idella4 <AT> gentoo <DOT> org>
5 CommitDate: Tue May 3 03:41:44 2016 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a7a6d003
7
8 net-p2p/classified-ads: Classified ads v0.10 version bump. - changed way how test suite is run and fixed 2 unit tests.
9
10 Package-Manager: portage-2.2.26
11 Closes: https://github.com/gentoo/gentoo/pull/1327
12
13 Signed-off-by: Ian Delaney <idella4 <AT> gentoo.org>
14
15 net-p2p/classified-ads/classified-ads-0.10.ebuild | 35 +++++++++++++++--------
16 1 file changed, 23 insertions(+), 12 deletions(-)
17
18 diff --git a/net-p2p/classified-ads/classified-ads-0.10.ebuild b/net-p2p/classified-ads/classified-ads-0.10.ebuild
19 index 9ff04f5..a792705 100644
20 --- a/net-p2p/classified-ads/classified-ads-0.10.ebuild
21 +++ b/net-p2p/classified-ads/classified-ads-0.10.ebuild
22 @@ -5,11 +5,12 @@
23 EAPI=5
24 PLOCALES="en fi sv da uk"
25 PLOCALE_BACKUP="en"
26 -inherit qt4-r2 qmake-utils
27 +inherit qt4-r2 qmake-utils virtualx vcs-snapshot
28
29 +COMMIT_ID="cd0652c52f86f6284b793f26e5362bc8fb8a7118"
30 DESCRIPTION="Program for displaying classified advertisement items"
31 HOMEPAGE="http://katiska.org/classified-ads/"
32 -SRC_URI="https://github.com/operatornormal/classified-ads/archive/${PV}.tar.gz -> classified-ads-${PV}.tar.gz \
33 +SRC_URI="https://github.com/operatornormal/classified-ads/archive/${COMMIT_ID}.tar.gz -> ${P}.tar.gz \
34 https://github.com/operatornormal/classified-ads/blob/graphics/preprocessed.tar.gz?raw=true \
35 -> classified-ads-graphics-${PV}.tar.gz"
36
37 @@ -37,13 +38,14 @@ DEPEND="${RDEPEND}
38 dev-qt/qttest:4
39 sys-devel/gdb:0
40 doc? ( app-doc/doxygen[dot] )
41 - test? ( dev-libs/libgcrypt:0 )
42 + test? ( dev-libs/libgcrypt:0
43 + ${VIRTUALX_DEPEND} )
44 "
45
46 src_prepare() {
47 # preprocessed graphics are unpacked into wrong directory
48 # so lets move them into correct location:
49 - mv ../ui/* ui/ || die
50 + mv ../classified-ads-graphics-${PV}/* ui/ || die
51 # then just run qmake
52 qt4-r2_src_prepare
53 }
54 @@ -57,8 +59,19 @@ src_compile() {
55 }
56
57 src_test() {
58 - cd test || die "test suite missing"
59 - "$(qt4_get_bindir)"/qmake || die "test suite configure failed"
60 + virtx test_suite
61 +}
62 +
63 +src_install() {
64 + emake install INSTALL_ROOT="${D}" DESTDIR="${D}"
65 + use doc && dodoc -r doc/doxygen.generated/html/
66 +}
67 +
68 +# virtualx requires a command that returns number, and does not just die:
69 +test_suite() {
70 + cd test || return -1
71 + echo qmake
72 + "$(qt4_get_bindir)"/qmake || return -2
73 emake
74 # test suite will create files under $HOME, set $HOME to point to
75 # safe location, ideas stolen from
76 @@ -70,11 +83,9 @@ src_test() {
77 result=$?
78 export HOME=$BACKUP_HOME
79 if [ $result != "0" ]; then
80 - die "test suite failed with error code " `echo $result`
81 + echo "test suite failed with error code " `echo $result`
82 + return $result
83 + else
84 + return 0
85 fi
86 }
87 -
88 -src_install() {
89 - emake install INSTALL_ROOT="${D}" DESTDIR="${D}"
90 - use doc && dodoc -r doc/doxygen.generated/html/
91 -}