Gentoo Archives: gentoo-commits

From: Lars Wendler <polynomial-c@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-apps/irqbalance/files/, sys-apps/irqbalance/
Date: Mon, 09 Jul 2018 12:35:00
Message-Id: 1531139686.3a3f1112c39d4134a912edfb8a4e94efdbd74a69.polynomial-c@gentoo
1 commit: 3a3f1112c39d4134a912edfb8a4e94efdbd74a69
2 Author: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
3 AuthorDate: Mon Jul 9 12:34:14 2018 +0000
4 Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
5 CommitDate: Mon Jul 9 12:34:46 2018 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3a3f1112
7
8 sys-apps/irqbalance: Fixed USE="-caps" still linking to libcaps
9
10 Also revbumped to 1.4.0-r1 with added "tui" USE flag.
11
12 Bug: https://bugs.gentoo.org/660782
13 Package-Manager: Portage-2.3.41, Repoman-2.3.9
14
15 .../files/irqbalance-1.4.0-configure.patch | 68 ++++++++++++++++++++++
16 sys-apps/irqbalance/irqbalance-1.3.0.ebuild | 7 ++-
17 ...nce-1.4.0.ebuild => irqbalance-1.4.0-r1.ebuild} | 13 +++--
18 sys-apps/irqbalance/metadata.xml | 1 +
19 4 files changed, 82 insertions(+), 7 deletions(-)
20
21 diff --git a/sys-apps/irqbalance/files/irqbalance-1.4.0-configure.patch b/sys-apps/irqbalance/files/irqbalance-1.4.0-configure.patch
22 new file mode 100644
23 index 00000000000..6008e45126c
24 --- /dev/null
25 +++ b/sys-apps/irqbalance/files/irqbalance-1.4.0-configure.patch
26 @@ -0,0 +1,68 @@
27 +From 8ad74cdabac37599d20a985e6a456b1faca92df8 Mon Sep 17 00:00:00 2001
28 +From: Manuel Mommertz <2kmm@×××.de>
29 +Date: Mon, 9 Jul 2018 14:08:35 +0200
30 +Subject: [PATCH 1/2] configure.ac: Fix --without-caps option
31 +
32 +irqbalance links to libcap-ng if it is installed, even when useflag
33 +caps is disabled. This is an error in the configure-script, which
34 +checks for the wrong variable to determine if the user used --with/
35 +--without for libcap-ng.
36 +
37 +Downstream bug report: https://bugs.gentoo.org/660782
38 +
39 +Signed-off-by: Lars Wendler <polynomial-c@g.o>
40 +---
41 + configure.ac | 2 +-
42 + 1 file changed, 1 insertion(+), 1 deletion(-)
43 +
44 +diff --git a/configure.ac b/configure.ac
45 +index f6c60da..19b148a 100644
46 +--- a/configure.ac
47 ++++ b/configure.ac
48 +@@ -65,7 +65,7 @@ AC_ARG_WITH([libcap-ng],
49 + AS_HELP_STRING([libcap-ng], [Add libcap-ng-support @<:@default=auto@:>@]))
50 +
51 + AS_IF(
52 +- [test "x$libcap_ng" != "xno"],
53 ++ [test "x$with_libcap_ng" != "xno"],
54 + [
55 + PKG_CHECK_MODULES([LIBCAP_NG], [libcap-ng],
56 + [AC_DEFINE(HAVE_LIBCAP_NG,1,[libcap-ng support])],
57 +--
58 +2.18.0
59 +
60 +From bc56dbd4eead9ad19ff1d84dc8810123c96503c0 Mon Sep 17 00:00:00 2001
61 +From: Lars Wendler <polynomial-c@g.o>
62 +Date: Mon, 9 Jul 2018 14:11:44 +0200
63 +Subject: [PATCH 2/2] configure.ac: Fix --enable-irqbalance-ui logic
64 +
65 +Before this patch --enable-irqbalance-ui disabled compilation/
66 +installation of the ui because AC_ARG_WITH is used wrong.
67 +The third arguement to AC_ARG_WITH is _action-if-present_ which means
68 +that this action gets triggered once the --enable option has been
69 +submitted to configure on command line no matter if it's enabled or
70 +disabled.
71 +See also https://autotools.io/autoconf/arguments.html chapter 3.1
72 +---
73 + configure.ac | 4 ++--
74 + 1 file changed, 2 insertions(+), 2 deletions(-)
75 +
76 +diff --git a/configure.ac b/configure.ac
77 +index 19b148a..75c234d 100644
78 +--- a/configure.ac
79 ++++ b/configure.ac
80 +@@ -43,9 +43,9 @@ AM_PROG_CC_C_O
81 + AC_ARG_WITH([irqbalance-ui],
82 + [AC_HELP_STRING([--without-irqbalance-ui],
83 + [Dont build the irqbalance ui component])],
84 +- [with_irqbalanceui=false], [with_irqbalanceui=true])
85 ++ [with_irqbalanceui=$withval], [with_irqbalanceui=yes])
86 +
87 +-AM_CONDITIONAL([IRQBALANCEUI], [test x$with_irqbalanceui = xtrue])
88 ++AM_CONDITIONAL([IRQBALANCEUI], [test x$with_irqbalanceui = xyes])
89 +
90 + AC_ARG_WITH([systemd],
91 + [ AS_HELP_STRING([--with-systemd],[Add systemd-lib support])]
92 +--
93 +2.18.0
94 +
95
96 diff --git a/sys-apps/irqbalance/irqbalance-1.3.0.ebuild b/sys-apps/irqbalance/irqbalance-1.3.0.ebuild
97 index 144745c1bc8..e8685a79161 100644
98 --- a/sys-apps/irqbalance/irqbalance-1.3.0.ebuild
99 +++ b/sys-apps/irqbalance/irqbalance-1.3.0.ebuild
100 @@ -1,8 +1,7 @@
101 -# Copyright 1999-2017 Gentoo Foundation
102 +# Copyright 1999-2018 Gentoo Foundation
103 # Distributed under the terms of the GNU General Public License v2
104
105 EAPI="6"
106 -AUTOTOOLS_AUTORECONF=true
107
108 inherit autotools systemd linux-info
109
110 @@ -28,6 +27,10 @@ RDEPEND="${CDEPEND}
111 selinux? ( sec-policy/selinux-irqbalance )
112 "
113
114 +PATCHES=(
115 + "${FILESDIR}/${PN}-1.4.0-configure.patch"
116 +)
117 +
118 pkg_setup() {
119 CONFIG_CHECK="~PCI_MSI"
120 linux-info_pkg_setup
121
122 diff --git a/sys-apps/irqbalance/irqbalance-1.4.0.ebuild b/sys-apps/irqbalance/irqbalance-1.4.0-r1.ebuild
123 similarity index 88%
124 rename from sys-apps/irqbalance/irqbalance-1.4.0.ebuild
125 rename to sys-apps/irqbalance/irqbalance-1.4.0-r1.ebuild
126 index a38439a45dc..c3874ddf72d 100644
127 --- a/sys-apps/irqbalance/irqbalance-1.4.0.ebuild
128 +++ b/sys-apps/irqbalance/irqbalance-1.4.0-r1.ebuild
129 @@ -2,7 +2,6 @@
130 # Distributed under the terms of the GNU General Public License v2
131
132 EAPI="6"
133 -AUTOTOOLS_AUTORECONF=true
134
135 inherit autotools systemd linux-info
136
137 @@ -13,13 +12,13 @@ SRC_URI="https://github.com/Irqbalance/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.g
138 LICENSE="GPL-2"
139 SLOT="0"
140 KEYWORDS="~amd64 ~ppc ~x86"
141 -IUSE="caps +numa selinux"
142 +IUSE="caps +numa selinux tui"
143
144 CDEPEND="
145 dev-libs/glib:2
146 - sys-libs/ncurses:0=[unicode]
147 caps? ( sys-libs/libcap-ng )
148 numa? ( sys-process/numactl )
149 + tui? ( sys-libs/ncurses:0=[unicode] )
150 "
151 DEPEND="${CDEPEND}
152 virtual/pkgconfig
153 @@ -28,6 +27,10 @@ RDEPEND="${CDEPEND}
154 selinux? ( sec-policy/selinux-irqbalance )
155 "
156
157 +PATCHES=(
158 + "${FILESDIR}/${P}-configure.patch"
159 +)
160 +
161 pkg_setup() {
162 CONFIG_CHECK="~PCI_MSI"
163 linux-info_pkg_setup
164 @@ -50,8 +53,8 @@ src_configure() {
165 local myeconfargs=(
166 $(use_with caps libcap-ng)
167 $(use_enable numa)
168 - )
169 -
170 + $(use_with tui irqbalance-ui)
171 + )
172 econf "${myeconfargs[@]}"
173 }
174
175
176 diff --git a/sys-apps/irqbalance/metadata.xml b/sys-apps/irqbalance/metadata.xml
177 index 8aa1af6dd70..d4dedf3afa5 100644
178 --- a/sys-apps/irqbalance/metadata.xml
179 +++ b/sys-apps/irqbalance/metadata.xml
180 @@ -7,6 +7,7 @@
181 </maintainer>
182 <use>
183 <flag name="numa">Support balancing IRQs across NUMA nodes</flag>
184 + <flag name="tui">Enable build of irqbalance terminal user interface</flag>
185 </use>
186 <upstream>
187 <remote-id type="google-code">irqbalance</remote-id>