x11-plugins/wmacpi: Respect CFLAGS

Closes: https://bugs.gentoo.org/726270
Signed-off-by: Jakov Smolic <jakov.smolic@sartura.hr>
Closes: https://github.com/gentoo/gentoo/pull/20606
Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
Jakov Smolic 2021-04-29 23:00:45 +01:00 committed by Sam James
parent 5a2f8e82e4
commit fd66b19c58
No known key found for this signature in database
GPG Key ID: F4922810EEA0483B
2 changed files with 18 additions and 15 deletions

View File

@ -1,17 +1,18 @@
--- a/Makefile 2015-01-12 11:27:07.396319323 +0100
+++ b/Makefile 2015-01-12 11:29:21.531298827 +0100
@@ -13,8 +13,8 @@
--- a/Makefile
+++ b/Makefile
@@ -12,9 +12,8 @@ BUILD_CLI = 1
# debugging options (don't bother with these)
#OPT = -pg -g
CC := gcc
-CC := gcc
-CFLAGS += $(OPT) -Wall -W -g -ansi
-LDFLAGS += $(OPT) -lX11 -ldockapp
+CFLAGS := -Wall -W -g -ansi
+LIBS := -lX11 -ldockapp
+CFLAGS ?= -Wall -W -g -ansi
+LIBS += -lX11 -ldockapp
WMSRC := wmacpi.c libacpi.c
HEADERS := libacpi.h wmacpi.h
@@ -26,7 +26,7 @@
@@ -26,7 +25,7 @@ targets += wmacpi-cli
doc_targets += wmacpi-cli.1
endif
@ -20,7 +21,7 @@
all: $(targets)
@@ -37,7 +37,7 @@
@@ -37,7 +36,7 @@ WMOBJ := $(patsubst %.c,%.o,$(filter %.c,$(WMSRC)))
-include $(WMOBJ:.o=.d)
wmacpi: $(WMOBJ)
@ -29,7 +30,7 @@
# for the Debian package, we want to make building the command line tools
# optional. So, we hide all the necessary stuff here . . .
@@ -47,13 +47,13 @@
@@ -47,13 +46,13 @@ CLOBJ := $(patsubst %.c,%.o,$(filter %.c,$(CLSRC)))
-include $(CLOBJ:.o=.d)
wmacpi-cli: $(CLOBJ)

View File

@ -1,21 +1,23 @@
# Copyright 1999-2020 Gentoo Authors
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit toolchain-funcs
DESCRIPTION="DockApp ACPI status monitor for laptops"
HOMEPAGE="https://www.dockapps.net/wmacpi"
SRC_URI="https://dev.gentoo.org/~voyageur/distfiles/${P}.tar.gz"
S="${WORKDIR}/dockapps"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="amd64 -ppc -sparc x86"
DEPEND=">=x11-libs/libdockapp-0.7:=
DEPEND="
>=x11-libs/libdockapp-0.7:=
x11-libs/libX11"
S=${WORKDIR}/dockapps
RDEPEND="${DEPEND}"
PATCHES=(
"${FILESDIR}"/${P}-makefile.patch
@ -28,6 +30,6 @@ src_prepare() {
sed -e 's#<dockapp.h>#<libdockapp/dockapp.h>#' -i *.c || die
}
src_compile() {
emake CC="$(tc-getCC)"
src_configure() {
tc-export CC
}