summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app-misc/binclock')
-rw-r--r--app-misc/binclock/binclock-1.5.ebuild21
-rw-r--r--app-misc/binclock/files/binclock-1.5-Makefile.patch22
2 files changed, 32 insertions, 11 deletions
diff --git a/app-misc/binclock/binclock-1.5.ebuild b/app-misc/binclock/binclock-1.5.ebuild
index 3e80505179b1..0c4db18b0aad 100644
--- a/app-misc/binclock/binclock-1.5.ebuild
+++ b/app-misc/binclock/binclock-1.5.ebuild
@@ -1,9 +1,9 @@
-# Copyright 1999-2011 Gentoo Foundation
+# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-EAPI="2"
+EAPI=6
-inherit toolchain-funcs
+inherit flag-o-matic toolchain-funcs
DESCRIPTION="Displays a binary clock in your terminal"
HOMEPAGE="http://www.ngolde.de/binclock/"
@@ -17,16 +17,15 @@ IUSE=""
RDEPEND=""
DEPEND=">=sys-apps/sed-4"
-src_prepare() {
- sed -i -e s/strip/true/ Makefile || die
-}
+PATCHES=( "${FILESDIR}/binclock-1.5-Makefile.patch" )
-src_compile() {
- emake CC="$(tc-getCC)" CFLAGS="${CFLAGS} ${LDFLAGS}" || die "emake failed"
+src_configure() {
+ append-cflags -Wall -pedantic
+ tc-export CC
}
src_install() {
- dobin binclock || die "dobin failed"
- doman doc/binclock.1 || die "doman failed"
- dodoc CHANGELOG README binclockrc || die "dodoc failed"
+ dobin binclock
+ doman doc/binclock.1
+ dodoc CHANGELOG README binclockrc
}
diff --git a/app-misc/binclock/files/binclock-1.5-Makefile.patch b/app-misc/binclock/files/binclock-1.5-Makefile.patch
new file mode 100644
index 000000000000..15a510186b55
--- /dev/null
+++ b/app-misc/binclock/files/binclock-1.5-Makefile.patch
@@ -0,0 +1,22 @@
+--- a/Makefile 2018-05-29 10:18:47.795059054 -0400
++++ b/Makefile 2018-05-29 10:21:37.126740904 -0400
+@@ -18,8 +18,6 @@
+ # Boston, MA 02111-1307, USA
+ #
+
+-CC = gcc
+-CFLAGS = -O2 -Wall --pedantic
+ BIN = binclock
+ SRC = ./src/binclock.c
+ INSPATH = /usr/local/bin/
+@@ -28,8 +26,8 @@
+ CONF = /etc/
+
+ all : $(MAINSRC)
+- $(CC) $(CFLAGS) -o $(BIN) $(SRC)
+- strip $(SOURCEPATH)$(BIN)
++ $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -o $(BIN) $(SRC)
++ true $(SOURCEPATH)$(BIN)
+
+ install :
+