summaryrefslogtreecommitdiff
path: root/games-util/springlobby/springlobby-scm.ebuild
blob: 137dbccbbce3d32c96af752c3615085c6fa0af6f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $


EAPI="5"
EGIT_REPO_URI="git://github.com/springlobby/springlobby.git"
EGIT_BRANCH="master"

inherit git-r3 cmake-utils eutils flag-o-matic games

DESCRIPTION="lobby client for spring rts engine - git version"
HOMEPAGE="http://springlobby.info"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS=""
RESTRICT="nomirror"
IUSE="+sound debug libnotify gstreamer"

RDEPEND="
        dev-libs/boost
	x11-libs/wxGTK:3.0
	net-misc/curl
	libnotify? (    x11-libs/libnotify )
	sound? (
			media-libs/openal
			media-libs/libvorbis
			media-libs/flac
			media-sound/mpg123
			media-libs/alure
	)
	gstreamer? (    media-libs/gstreamer )
"

DEPEND="${RDEPEND}
	>=dev-util/cmake-2.6.0
"
src_unpack() {
		git-r3_src_unpack
}

BUILD_DIR="${WORKDIR}/${P}_build"
src_configure() {
	if ! use sound ; then
		mycmakeargs="${mycmakeargs} -DOPTION_SOUND=OFF"
	fi
	if use gstreamer ; then
		mycmakeargs="${mycmakeargs} -DGSTREAMER=ON"
	fi

	mycmakeargs="${mycmakeargs} -DAUX_VERSION=(Gentoo,$ARCH) -DCMAKE_INSTALL_PREFIX=/usr/games/"
	cmake-utils_src_configure
}

src_compile () {
	cmake-utils_src_compile
}

src_install() {
	cmake-utils_src_install
	prepgamesdirs
	# bad
	dodir /usr/share/games/icons/hicolor/scalable/apps/
	mv ${D}/usr/games/share/icons/hicolor/scalable/apps/springlobby.svg ${D}/usr/share/games/icons/hicolor/scalable/apps/springlobby.svg
	rm ${D}/usr/share/games/pixmaps/ -fr
	dodir /usr/share/games/applications/
	mv ${D}/usr/games/share/applications/springlobby.desktop ${D}/usr/share/games/applications/springlobby.desktop
	rm ${D}/usr/games/share/applications/ -fr
	dodir /etc/env.d/
	echo 'XDG_DATA_DIRS="/usr/share/games"' >> ${D}/etc/env.d/99games
}