x11-misc/safeeyes: Drop old
[gentoo.git] / x11-misc / xmountains / xmountains-2.9-r1.ebuild
1 # Copyright 1999-2017 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=6
5
6 inherit toolchain-funcs
7
8 MY_P=${P/-/_}
9
10 DESCRIPTION="Fractal terrains of snow-capped mountains near water"
11 HOMEPAGE="https://spbooth.github.io/xmountains/"
12 SRC_URI="http://www.epcc.ed.ac.uk/~spb/${PN}/${MY_P}.tar.gz"
13
14 LICENSE="HPND"
15 SLOT="0"
16 KEYWORDS="amd64 ppc x86 ~x86-fbsd"
17 IUSE=""
18
19 RDEPEND="
20         x11-libs/libX11
21         x11-misc/xbitmaps"
22 DEPEND="${RDEPEND}
23         x11-proto/xproto"
24
25 S=${WORKDIR}
26
27 src_prepare() {
28         default
29         # add missing include for strcmp
30         sed -i xmountains.c -e '1a#include <string.h> /* strcmp() */' || die
31         # remove obsolete references to global.*
32         sed -i Makefile.alt README -e 's|global\..||g' || die
33 }
34
35 src_compile() {
36         emake \
37                 -f Makefile.alt \
38                 CC="$(tc-getCC)" \
39                 CFLAGS="${CFLAGS}" \
40                 LDFLAGS="${LDFLAGS}" \
41                 ${PN}
42 }
43
44 src_install() {
45         dobin ${PN}
46         newman ${PN}.man ${PN}.1
47         einstalldocs
48 }