diff options
author | Ionen Wolkens <ionen@gentoo.org> | 2022-10-13 03:41:13 -0400 |
---|---|---|
committer | Ionen Wolkens <ionen@gentoo.org> | 2022-10-13 05:06:07 -0400 |
commit | 2fc276966c91e9c0270ed31b1978d7bcff51721b (patch) | |
tree | 520ae0903c5f17e98e0e426ed2977d75ff9d6097 /games-arcade/stardork | |
parent | mail-client/thunderbird: add 102.3.3 (diff) | |
download | gentoo-2fc276966c91e9c0270ed31b1978d7bcff51721b.tar.gz gentoo-2fc276966c91e9c0270ed31b1978d7bcff51721b.tar.bz2 gentoo-2fc276966c91e9c0270ed31b1978d7bcff51721b.zip |
games-arcade/stardork: EAPI6->8, fix build with clang16
Also pass cppflags bit of ncurses' pkg-config.
Closes: https://bugs.gentoo.org/871498
Signed-off-by: Ionen Wolkens <ionen@gentoo.org>
Diffstat (limited to 'games-arcade/stardork')
-rw-r--r-- | games-arcade/stardork/files/stardork-0.7-clang16.patch | 13 | ||||
-rw-r--r-- | games-arcade/stardork/stardork-0.7-r1.ebuild | 34 | ||||
-rw-r--r-- | games-arcade/stardork/stardork-0.7-r2.ebuild | 35 |
3 files changed, 48 insertions, 34 deletions
diff --git a/games-arcade/stardork/files/stardork-0.7-clang16.patch b/games-arcade/stardork/files/stardork-0.7-clang16.patch new file mode 100644 index 000000000000..c815fcd281fb --- /dev/null +++ b/games-arcade/stardork/files/stardork-0.7-clang16.patch @@ -0,0 +1,13 @@ +https://bugs.gentoo.org/871498 +--- a/stardork.c ++++ b/stardork.c +@@ -376,3 +376,3 @@ + +-void plot_wormhole(y, x) { ++void plot_wormhole(int y, int x) { + int r1, r2, i, j; +@@ -564,3 +564,3 @@ + +-void change_colors(color) { ++void change_colors(int color) { + if (has_colors() != FALSE) { diff --git a/games-arcade/stardork/stardork-0.7-r1.ebuild b/games-arcade/stardork/stardork-0.7-r1.ebuild deleted file mode 100644 index d2b7e070c095..000000000000 --- a/games-arcade/stardork/stardork-0.7-r1.ebuild +++ /dev/null @@ -1,34 +0,0 @@ -# Copyright 1999-2021 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=6 - -inherit toolchain-funcs - -DESCRIPTION="An ncurses-based space shooter" -HOMEPAGE="http://stardork.sourceforge.net/" -SRC_URI="mirror://sourceforge/stardork/${P}.tar.gz" - -LICENSE="GPL-2" -SLOT="0" -KEYWORDS="~amd64 ~ppc64 ~x86" -IUSE="" - -RDEPEND="sys-libs/ncurses:0=" -DEPEND="${RDEPEND} - virtual/pkgconfig -" - -src_prepare() { - default - rm -f Makefile -} - -src_compile() { - emake CC="$(tc-getCC)" LDLIBS="$($(tc-getPKG_CONFIG) ncurses --libs)" ${PN} -} - -src_install() { - dobin ${PN} - einstalldocs -} diff --git a/games-arcade/stardork/stardork-0.7-r2.ebuild b/games-arcade/stardork/stardork-0.7-r2.ebuild new file mode 100644 index 000000000000..f6b1fece5104 --- /dev/null +++ b/games-arcade/stardork/stardork-0.7-r2.ebuild @@ -0,0 +1,35 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit flag-o-matic toolchain-funcs + +DESCRIPTION="ncurses-based space shooter" +HOMEPAGE="https://stardork.sourceforge.net/" +SRC_URI="mirror://sourceforge/stardork/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~ppc64 ~x86" + +RDEPEND="sys-libs/ncurses:=" +DEPEND="${RDEPEND}" +BDEPEND="virtual/pkgconfig" + +PATCHES=( + "${FILESDIR}"/${P}-clang16.patch +) + +src_compile() { + tc-export CC + append-cppflags $($(tc-getPKG_CONFIG) ncurses --cflags || die) + append-libs $($(tc-getPKG_CONFIG) ncurses --libs || die) + + emake -f /dev/null LDLIBS="${LIBS}" ${PN} +} + +src_install() { + dobin ${PN} + einstalldocs +} |