Gentoo Archives: gentoo-commits

From: Sam James <sam@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: x11-plugins/wmacpi/files/, x11-plugins/wmacpi/
Date: Tue, 04 May 2021 22:18:05
Message-Id: 1620166635.fd66b19c5899056739734378f2ed5c75776467e4.sam@gentoo
1 commit: fd66b19c5899056739734378f2ed5c75776467e4
2 Author: Jakov Smolic <jakov.smolic <AT> sartura <DOT> hr>
3 AuthorDate: Thu Apr 29 22:00:45 2021 +0000
4 Commit: Sam James <sam <AT> gentoo <DOT> org>
5 CommitDate: Tue May 4 22:17:15 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=fd66b19c
7
8 x11-plugins/wmacpi: Respect CFLAGS
9
10 Closes: https://bugs.gentoo.org/726270
11 Signed-off-by: Jakov Smolic <jakov.smolic <AT> sartura.hr>
12 Closes: https://github.com/gentoo/gentoo/pull/20606
13 Signed-off-by: Sam James <sam <AT> gentoo.org>
14
15 x11-plugins/wmacpi/files/wmacpi-2.3-makefile.patch | 19 ++++++++++---------
16 x11-plugins/wmacpi/wmacpi-2.3-r1.ebuild | 14 ++++++++------
17 2 files changed, 18 insertions(+), 15 deletions(-)
18
19 diff --git a/x11-plugins/wmacpi/files/wmacpi-2.3-makefile.patch b/x11-plugins/wmacpi/files/wmacpi-2.3-makefile.patch
20 index 2bf80a3190d..60629e22ad2 100644
21 --- a/x11-plugins/wmacpi/files/wmacpi-2.3-makefile.patch
22 +++ b/x11-plugins/wmacpi/files/wmacpi-2.3-makefile.patch
23 @@ -1,17 +1,18 @@
24 ---- a/Makefile 2015-01-12 11:27:07.396319323 +0100
25 -+++ b/Makefile 2015-01-12 11:29:21.531298827 +0100
26 -@@ -13,8 +13,8 @@
27 +--- a/Makefile
28 ++++ b/Makefile
29 +@@ -12,9 +12,8 @@ BUILD_CLI = 1
30 + # debugging options (don't bother with these)
31 #OPT = -pg -g
32
33 - CC := gcc
34 +-CC := gcc
35 -CFLAGS += $(OPT) -Wall -W -g -ansi
36 -LDFLAGS += $(OPT) -lX11 -ldockapp
37 -+CFLAGS := -Wall -W -g -ansi
38 -+LIBS := -lX11 -ldockapp
39 ++CFLAGS ?= -Wall -W -g -ansi
40 ++LIBS += -lX11 -ldockapp
41
42 WMSRC := wmacpi.c libacpi.c
43 HEADERS := libacpi.h wmacpi.h
44 -@@ -26,7 +26,7 @@
45 +@@ -26,7 +25,7 @@ targets += wmacpi-cli
46 doc_targets += wmacpi-cli.1
47 endif
48
49 @@ -20,7 +21,7 @@
50
51 all: $(targets)
52
53 -@@ -37,7 +37,7 @@
54 +@@ -37,7 +36,7 @@ WMOBJ := $(patsubst %.c,%.o,$(filter %.c,$(WMSRC)))
55 -include $(WMOBJ:.o=.d)
56
57 wmacpi: $(WMOBJ)
58 @@ -29,7 +30,7 @@
59
60 # for the Debian package, we want to make building the command line tools
61 # optional. So, we hide all the necessary stuff here . . .
62 -@@ -47,13 +47,13 @@
63 +@@ -47,13 +46,13 @@ CLOBJ := $(patsubst %.c,%.o,$(filter %.c,$(CLSRC)))
64 -include $(CLOBJ:.o=.d)
65
66 wmacpi-cli: $(CLOBJ)
67
68 diff --git a/x11-plugins/wmacpi/wmacpi-2.3-r1.ebuild b/x11-plugins/wmacpi/wmacpi-2.3-r1.ebuild
69 index 9ee992963ca..1c24cbb6058 100644
70 --- a/x11-plugins/wmacpi/wmacpi-2.3-r1.ebuild
71 +++ b/x11-plugins/wmacpi/wmacpi-2.3-r1.ebuild
72 @@ -1,21 +1,23 @@
73 -# Copyright 1999-2020 Gentoo Authors
74 +# Copyright 1999-2021 Gentoo Authors
75 # Distributed under the terms of the GNU General Public License v2
76
77 EAPI=7
78 +
79 inherit toolchain-funcs
80
81 DESCRIPTION="DockApp ACPI status monitor for laptops"
82 HOMEPAGE="https://www.dockapps.net/wmacpi"
83 SRC_URI="https://dev.gentoo.org/~voyageur/distfiles/${P}.tar.gz"
84 +S="${WORKDIR}/dockapps"
85
86 LICENSE="GPL-2"
87 SLOT="0"
88 KEYWORDS="amd64 -ppc -sparc x86"
89
90 -DEPEND=">=x11-libs/libdockapp-0.7:=
91 +DEPEND="
92 + >=x11-libs/libdockapp-0.7:=
93 x11-libs/libX11"
94 -
95 -S=${WORKDIR}/dockapps
96 +RDEPEND="${DEPEND}"
97
98 PATCHES=(
99 "${FILESDIR}"/${P}-makefile.patch
100 @@ -28,6 +30,6 @@ src_prepare() {
101 sed -e 's#<dockapp.h>#<libdockapp/dockapp.h>#' -i *.c || die
102 }
103
104 -src_compile() {
105 - emake CC="$(tc-getCC)"
106 +src_configure() {
107 + tc-export CC
108 }