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-misc/birthday/, app-misc/birthday/files/
Date: Sun, 31 Jul 2022 20:03:54
Message-Id: 1659297797.5036c1fea222b3671b9e63c9b87a49b4a76ef5f8.soap@gentoo
1 commit: 5036c1fea222b3671b9e63c9b87a49b4a76ef5f8
2 Author: David Seifert <soap <AT> gentoo <DOT> org>
3 AuthorDate: Sun Jul 31 20:03:17 2022 +0000
4 Commit: David Seifert <soap <AT> gentoo <DOT> org>
5 CommitDate: Sun Jul 31 20:03:17 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5036c1fe
7
8 app-misc/birthday: update EAPI 6 -> 8
9
10 Signed-off-by: David Seifert <soap <AT> gentoo.org>
11
12 ...ay-1.6.2-r1.ebuild => birthday-1.6.2-r2.ebuild} | 20 ++--------
13 .../birthday/files/birthday-1.6.2-makefile.patch | 44 ++++++++++++++++++++++
14 2 files changed, 48 insertions(+), 16 deletions(-)
15
16 diff --git a/app-misc/birthday/birthday-1.6.2-r1.ebuild b/app-misc/birthday/birthday-1.6.2-r2.ebuild
17 similarity index 53%
18 rename from app-misc/birthday/birthday-1.6.2-r1.ebuild
19 rename to app-misc/birthday/birthday-1.6.2-r2.ebuild
20 index 4d2088dc58c5..53041e6b6378 100644
21 --- a/app-misc/birthday/birthday-1.6.2-r1.ebuild
22 +++ b/app-misc/birthday/birthday-1.6.2-r2.ebuild
23 @@ -1,7 +1,7 @@
24 # Copyright 1999-2022 Gentoo Authors
25 # Distributed under the terms of the GNU General Public License v2
26
27 -EAPI=6
28 +EAPI=8
29
30 inherit toolchain-funcs
31
32 @@ -13,20 +13,8 @@ LICENSE="GPL-2"
33 SLOT="0"
34 KEYWORDS="amd64 ppc ppc64 sparc x86"
35
36 -src_prepare() {
37 - # Don't strip, install in correct share dir and respect CFLAGS
38 - sed \
39 - -e "s@install -s@install@g" \
40 - -e "s@#SHARE@SHARE@g" \
41 - -e "s@-O2@${CFLAGS}@g" \
42 - -i Makefile || die
43 - sed \
44 - -e 's@grep -v@grep --binary-files=text -v@g' \
45 - -i runtest.sh || die
46 +PATCHES=( "${FILESDIR}"/${P}-makefile.patch )
47
48 - default
49 -}
50 -
51 -src_compile() {
52 - emake CC="$(tc-getCC)"
53 +src_configure() {
54 + tc-export CC
55 }
56
57 diff --git a/app-misc/birthday/files/birthday-1.6.2-makefile.patch b/app-misc/birthday/files/birthday-1.6.2-makefile.patch
58 new file mode 100644
59 index 000000000000..f48102d929b7
60 --- /dev/null
61 +++ b/app-misc/birthday/files/birthday-1.6.2-makefile.patch
62 @@ -0,0 +1,44 @@
63 +--- a/Makefile
64 ++++ b/Makefile
65 +@@ -12,7 +12,7 @@
66 + else
67 + OSCFLAGS=-Wall -Wstrict-prototypes
68 + endif
69 +-CFLAGS=-O2 $(DEBUG) -D$(OS) $(OSCFLAGS)
70 ++CFLAGS += $(DEBUG) -D$(OS) $(OSCFLAGS)
71 +
72 + # engine
73 + ENGSRC=bdengine.c xmalloc.c
74 +@@ -48,16 +48,15 @@
75 +
76 + else
77 + birthday: $(CMDOBJ)
78 +- $(CC) $(LDFLAGS) $(CMDOBJ) -o $@
79 ++ $(CC) $(LDFLAGS) $(CMDOBJ) -o $@ $(LIBS)
80 +
81 + # you can override this to use the new FHS locations.
82 +-SHARE=
83 +-#SHARE=/share
84 ++SHARE=/share
85 +
86 + install: birthday birthday.man
87 +- install -d $(DESTDIR)/usr/bin $(DESTDIR)/usr$(SHARE)/man/man1
88 +- install -s birthday $(DESTDIR)/usr/bin/birthday
89 +- install -m 0644 birthday.man $(DESTDIR)/usr$(SHARE)/man/man1/birthday.1
90 ++ install -d $(DESTDIR)$(EPREFIX)/usr/bin $(DESTDIR)$(EPREFIX)/usr$(SHARE)/man/man1
91 ++ install birthday $(DESTDIR)$(EPREFIX)/usr/bin/birthday
92 ++ install -m 0644 birthday.man $(DESTDIR)$(EPREFIX)/usr$(SHARE)/man/man1/birthday.1
93 +
94 + test: birthday
95 + sh runtest.sh -exec `pwd`/birthday test/*.t
96 +--- a/runtest.sh
97 ++++ b/runtest.sh
98 +@@ -7,7 +7,7 @@
99 + unset PASSED FAILED TAKEN KEEP
100 +
101 + extract_section() {
102 +- sed -ne "/^\\*$1/,/^\\*/p" "$2" | grep -v '^*'
103 ++ sed -ne "/^\\*$1/,/^\\*/p" "$2" | grep --binary-files=text -v '^*'
104 + }
105 +
106 + runtest() {