Gentoo Archives: gentoo-commits

From: David Seifert <soap@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-admin/fetchlog/, app-admin/fetchlog/files/
Date: Fri, 29 Dec 2017 17:02:47
Message-Id: 1514566912.93a25195bedb143cd79af69f6437d3dc17d6ea73.soap@gentoo
1 commit: 93a25195bedb143cd79af69f6437d3dc17d6ea73
2 Author: David Seifert <soap <AT> gentoo <DOT> org>
3 AuthorDate: Fri Dec 29 16:08:21 2017 +0000
4 Commit: David Seifert <soap <AT> gentoo <DOT> org>
5 CommitDate: Fri Dec 29 17:01:52 2017 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=93a25195
7
8 app-admin/fetchlog: [QA] Minor touchups
9
10 Package-Manager: Portage-2.3.19, Repoman-2.3.6
11
12 app-admin/fetchlog/fetchlog-1.4-r1.ebuild | 35 ++++++++++++----------
13 .../files/fetchlog-1.4-fix-build-system.patch | 30 +++++++++++++++++++
14 2 files changed, 49 insertions(+), 16 deletions(-)
15
16 diff --git a/app-admin/fetchlog/fetchlog-1.4-r1.ebuild b/app-admin/fetchlog/fetchlog-1.4-r1.ebuild
17 index 0893accd6e6..13e7e73d9af 100644
18 --- a/app-admin/fetchlog/fetchlog-1.4-r1.ebuild
19 +++ b/app-admin/fetchlog/fetchlog-1.4-r1.ebuild
20 @@ -8,16 +8,31 @@ inherit toolchain-funcs
21 DESCRIPTION="Displays the last new messages of a logfile"
22 HOMEPAGE="http://fetchlog.sourceforge.net/"
23 SRC_URI="mirror://sourceforge/fetchlog/${P}.tar.gz"
24 +
25 LICENSE="GPL-2"
26 SLOT="0"
27 KEYWORDS="~amd64 ~ppc ~x86 ~ppc64"
28 -
29 IUSE="snmp"
30
31 -RDEPEND="snmp? (
32 - >=dev-perl/Net-SNMP-4.0.1-r2
33 - >=net-analyzer/net-snmp-5.0.6
34 +RDEPEND="
35 + snmp? (
36 + >=dev-perl/Net-SNMP-4.0.1-r2
37 + >=net-analyzer/net-snmp-5.0.6
38 )"
39 +DEPEND=""
40 +
41 +PATCHES=( "${FILESDIR}"/${PN}-1.4-fix-build-system.patch )
42 +
43 +src_configure() {
44 + tc-export CC
45 +}
46 +
47 +src_install() {
48 + dobin fetchlog
49 + einstalldocs
50 + dodoc *cfg*
51 + doman fetchlog.1
52 +}
53
54 pkg_preinst() {
55 elog
56 @@ -28,15 +43,3 @@ pkg_preinst() {
57 elog "have 'snmp' in your USE flags"
58 elog
59 }
60 -
61 -src_compile() {
62 - # Links the .c file straight to the binary
63 - emake CC="$(tc-getCC)" CFLAGS="${CFLAGS} ${LDFLAGS}"
64 -}
65 -
66 -src_install() {
67 - dodoc CHANGES README*
68 - dodoc *cfg*
69 - dobin fetchlog
70 - doman fetchlog.1
71 -}
72
73 diff --git a/app-admin/fetchlog/files/fetchlog-1.4-fix-build-system.patch b/app-admin/fetchlog/files/fetchlog-1.4-fix-build-system.patch
74 new file mode 100644
75 index 00000000000..53c05d85f74
76 --- /dev/null
77 +++ b/app-admin/fetchlog/files/fetchlog-1.4-fix-build-system.patch
78 @@ -0,0 +1,30 @@
79 +--- a/Makefile
80 ++++ b/Makefile
81 +@@ -23,8 +23,8 @@
82 + ### compiler
83 +
84 + ### gcc
85 +-CC=gcc
86 +-CFLAGS= -O -Werror -Wall -Wcast-qual -Wstrict-prototypes \
87 ++CC ?= gcc
88 ++CFLAGS += -Wall -Wcast-qual -Wstrict-prototypes \
89 + -Wmissing-prototypes -Wmissing-declarations -Winline -Wcast-align
90 + ### cc
91 + #CC=cc
92 +@@ -72,7 +72,7 @@
93 +
94 + # compiler stuff
95 + # --------------
96 +-CC_OPT= $(CFLAGS) -DFETCHLOG_VERSION_NO=\"$(FETCHLOG_VERSION)\" \
97 ++CPPFLAGS += -DFETCHLOG_VERSION_NO=\"$(FETCHLOG_VERSION)\" \
98 + $(HAS_MADVISE) $(HAS_REGEX)
99 +
100 + # all
101 +@@ -82,7 +82,6 @@
102 + # fetchlog
103 + # -------
104 + fetchlog: fetchlog.c
105 +- $(CC) $(CC_OPT) fetchlog.c -o fetchlog
106 +
107 +
108 + # install