From 8a0c14ea8f31dc9acc132600859c6bc2c311482b Mon Sep 17 00:00:00 2001 From: David Seifert Date: Wed, 16 Oct 2019 13:39:48 +0200 Subject: media-sound/litestream: Port to EAPI 7 Bug: https://bugs.gentoo.org/697274 Package-Manager: Portage-2.3.77, Repoman-2.3.17 Signed-off-by: David Seifert --- .../litestream-1.3_rc3-fix-build-system.patch | 43 ++++++++++++++++++++++ media-sound/litestream/litestream-1.3_rc3.ebuild | 31 ++++++---------- 2 files changed, 54 insertions(+), 20 deletions(-) create mode 100644 media-sound/litestream/files/litestream-1.3_rc3-fix-build-system.patch (limited to 'media-sound') diff --git a/media-sound/litestream/files/litestream-1.3_rc3-fix-build-system.patch b/media-sound/litestream/files/litestream-1.3_rc3-fix-build-system.patch new file mode 100644 index 000000000000..0ef4eaa8a664 --- /dev/null +++ b/media-sound/litestream/files/litestream-1.3_rc3-fix-build-system.patch @@ -0,0 +1,43 @@ +--- a/Makefile ++++ b/Makefile +@@ -1,32 +1,27 @@ + # $Id: Makefile,v 1.8 2005/09/06 21:26:02 roundeye Exp $ + + INCLUDES = -Iinclude +-AR= ar +-RANLIB= sh ranlib.sh + +-CFLAGS = $(INCLUDES) -Wall -g -DVERSION="\"Litestream 1.2\"" ++CFLAGS += -Wall + +-LDFLAGS = # -lnsl -lsocket ++CPPFLAGS += $(INCLUDES) -DVERSION="\"Litestream 1.2\"" -DNO_VARARGS + + all: litestream literestream source client server + + .depend: $(WILDCARD *.c) +- $(CC) -MM $(CFLAGS) -DDEPEND *.c > .depend ++ $(CC) -MM $(CFLAGS) $(CPPFLAGS) -DDEPEND *.c > .depend + +-client: stream_cli.o stream_sched.o hexdump.o client.o stream_log.o +- $(CC) $(CFLAGS) -o $@ $^ $(LDFLAGS) ++client: stream_cli.o stream_sched.o hexdump.o stream_log.o + +-server: stream_serv.o stream_sched.o hexdump.o server.o stream_log.o +- $(CC) $(CFLAGS) -o $@ $^ $(LDFLAGS) ++server: stream_serv.o stream_sched.o hexdump.o stream_log.o + + literestream: stream_serv.o stream_sched.o restream.o hexdump.o icy.o yp.o stream_cli.o http.o textutils.o stream_log.o +- $(CC) $(CFLAGS) -o $@ $^ $(LDFLAGS) ++ $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -o $@ $^ + + litestream: stream_serv.o stream_sched.o stream.o hexdump.o icy.o yp.o stream_cli.o http.o textutils.o stream_log.o +- $(CC) $(CFLAGS) -o $@ $^ $(LDFLAGS) ++ $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -o $@ $^ + +-source: stream_sched.o stream_cli.o http.o stream_log.o source.o mp3.o playlist.o textutils.o +- $(CC) $(CFLAGS) -o $@ $^ $(LDFLAGS) ++source: stream_sched.o stream_cli.o http.o stream_log.o mp3.o playlist.o textutils.o + + clean: + rm -f *.o source server client litestream literestream .depend *.core diff --git a/media-sound/litestream/litestream-1.3_rc3.ebuild b/media-sound/litestream/litestream-1.3_rc3.ebuild index 21c193593598..e0d4d98fac8d 100644 --- a/media-sound/litestream/litestream-1.3_rc3.ebuild +++ b/media-sound/litestream/litestream-1.3_rc3.ebuild @@ -1,40 +1,31 @@ -# Copyright 1999-2018 Gentoo Foundation +# Copyright 1999-2019 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=0 +EAPI=7 -inherit eutils flag-o-matic toolchain-funcs - -MY_P=${P/_rc/RC} +inherit toolchain-funcs DESCRIPTION="Litstream is a lightweight and robust shoutcast-compatible streaming mp3 server" HOMEPAGE="http://www.litestream.org/" -SRC_URI="http://litestream.org/litestream/${MY_P}.tar.gz" +SRC_URI="http://litestream.org/litestream/${P/_rc/RC}.tar.gz" LICENSE="BSD" SLOT="0" KEYWORDS="~amd64 ~ppc sparc x86" -IUSE="" - -S=${WORKDIR}/${MY_P} -src_unpack() { - unpack ${A} - cd "${S}" - sed -i -e 's:CFLAGS = :CFLAGS = ${OPTFLAGS} :; s:-g::' \ - Makefile || die "sed failed" -} +S="${WORKDIR}/${P/_rc/RC}" +PATCHES=( "${FILESDIR}"/${P}-fix-build-system.patch ) -src_compile() { - append-flags "-DNO_VARARGS" - emake CC=$(tc-getCC) OPTFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" || die +src_configure() { + tc-export CC } src_install() { - dobin litestream literestream || die "dobin failed" + dobin litestream literestream newbin source litestream-source newbin server litestream-server newbin client litestream-client - dodoc ABOUT ACKNOWLEDGEMENTS BUGS CHANGELOG CONTACT FILES MAKEITGO README + einstalldocs + dodoc ABOUT ACKNOWLEDGEMENTS CONTACT FILES MAKEITGO } -- cgit v1.2.3-65-gdbad