Diff beep-1.3-r3 with a beep-1.4.9

/usr/portage/app-misc/beep/beep-1.4.9.ebuild 2020-03-30 17:09:00.000000000 +0300
1 1
# Copyright 1999-2020 Gentoo Authors
2 2
# Distributed under the terms of the GNU General Public License v2
3 3

  
4
EAPI=6
4
EAPI=7
5 5

  
6 6
inherit toolchain-funcs
7 7

  
8
DESCRIPTION="The advanced PC speaker beeper"
9
HOMEPAGE="http://www.johnath.com/beep"
10
SRC_URI="http://www.johnath.com/beep/${P}.tar.gz"
8
DESCRIPTION="Advanced PC speaker beeper"
9
HOMEPAGE="https://github.com/spkr-beep"
10
SRC_URI="https://github.com/spkr-beep/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
11 11

  
12 12
LICENSE="GPL-2"
13 13
SLOT="0"
14
KEYWORDS="~alpha amd64 arm ppc ppc64 sparc x86"
14
KEYWORDS="~alpha amd64 arm ppc ppc64 ~sparc x86"
15 15
IUSE="suid"
16 16

  
17
PATCHES=(
18
	"${FILESDIR}/${P}-Makefile.patch"
19
	"${FILESDIR}/${P}-CVE-2018-0492.patch"
20
)
17
# Tests require a speaker
18
RESTRICT="test"
21 19

  
22
pkg_setup() {
23
	tc-export CC
20
src_prepare() {
21
	default
22

  
23
	sed -i -e "s#-D_FORTIFY_SOURCE=2##g;" GNUmakefile || die
24
}
25

  
26
src_compile() {
27
	emake \
28
		COMPILERS=gcc \
29
		COMPILER_gcc="$(tc-getCC)" \
30
		LINKER_gcc="$(tc-getCC)" \
31
		CFLAGS_gcc="${CFLAGS}" \
32
		LDFLAGS="${LDFLAGS}" \
33
		CPPFLAGS_gcc="" \
34
		all
35
}
36

  
37
src_test() {
38
	emake \
39
		COMPILERS=gcc \
40
		COMPILER_gcc="$(tc-getCC)" \
41
		LINKER_gcc="$(tc-getCC)" \
42
		CFLAGS_gcc="${CFLAGS}" \
43
		LDFLAGS="${LDFLAGS}" \
44
		check
24 45
}
25 46

  
26 47
src_install() {
27 48
	dobin beep
28
	if use suid; then
49
	doman "${PN}.1"
50

  
51
	if use suid ; then
29 52
		fowners :audio /usr/bin/beep
30 53
		fperms 4710 /usr/bin/beep
31 54
	else
32 55
		fperms 0711 /usr/bin/beep
33 56
	fi
34
	unpack "./${PN}.1.gz"
35
	doman "${PN}.1"
57

  
36 58
	einstalldocs
37 59
}
Thank you!