games-arcade/performous-0.3.1: Bump
[otih-overlay.git] / games-arcade / performous / performous-0.3.0.ebuild
blobc01df62da32c9aa584e5de0ac3d55f4e0158a5b9
1 # Copyright 1999-2006 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /cvsroot/ultrastar-ng/UltraStar-ng/portage-overlay/games-arcade/performous/performous-9999.ebuild,v 1.10 2007/09/29 13:04:19 yoda-jm Exp $
5 inherit games cmake-utils
7 RESTRICT="nostrip"
9 MY_PN=Performous
10 MY_P=${MY_PN}-${PV}-Source
11 SONGS_PN=ultrastar-songs
12 SONGS_P=${SONGS_PN}-2
14 DESCRIPTION="SingStar GPL clone"
15 HOMEPAGE="http://performous.org"
16 SRC_URI=" mirror://sourceforge/${PN}/${MY_P}.tar.bz2
17 songs? ( mirror://sourceforge/${PN}/${SONGS_P}.tar.bz2 )"
19 LICENSE="GPL-2
20 songs? (
21 CCPL-Attribution-ShareAlike-NonCommercial-2.5
22 CCPL-Attribution-NonCommercial-NoDerivs-2.5
24 SLOT="0"
25 KEYWORDS="~x86 ~amd64 ~ppc ~ppc64"
27 IUSE="debug alsa portaudio pulseaudio jack songs gstreamer"
29 RDEPEND="gnome-base/librsvg
30 dev-libs/boost
31 x11-libs/pango
32 dev-cpp/libxmlpp
33 media-libs/libsdl
34 media-gfx/imagemagick
36 virtual/opengl
37 virtual/glu
39 >=media-video/ffmpeg-0.4.9_p20070616-r20
40 alsa? ( media-libs/alsa-lib )
41 jack? ( media-sound/jack-audio-connection-kit )
42 portaudio? ( media-libs/portaudio )
43 gstreamer? ( media-libs/gstreamer )
44 pulseaudio? ( media-sound/pulseaudio )
45 sys-apps/help2man
46 !games-arcade/ultrastar-ng"
47 DEPEND="${RDEPEND}
48 >=dev-util/cmake-2.6.0"
50 pkg_setup() {
51 games_pkg_setup
52 if ! built_with_use media-libs/libsdl opengl; then
53 eerror "libsdl wasn't build with opengl support"
55 if ! built_with_use --missing true dev-libs/boost threads ; then
56 eerror "Please emerge dev-libs/boost with USE=threads"
60 src_compile() {
61 cd "${MY_P}"
62 mkdir build
63 cd build
64 cmake \
65 -DCMAKE_CXX_FLAGS="${CXXFLAGS}" \
66 -DCMAKE_INSTALL_PREFIX="${GAMES_PREFIX}" \
67 $(cmake-utils_use_with alsa ALSA) \
68 $(cmake-utils_use_with jack JACK) \
69 $(cmake-utils_use_with pulseaudio PULSEAUDIO) \
70 $(cmake-utils_use_with portaudio PORTAUDIO) \
71 $(cmake-utils_use_with gstreamer GSTREAMER) \
72 .. || die "cmake failed"
73 emake || die "emake failed"
76 src_install() {
77 cd "${MY_P}/build"
78 emake DESTDIR="${D}" install || die "make install failed"
79 keepdir "${GAMES_DATADIR}"/ultrastar/songs
80 # copy files at the right place
81 rm -rf "${D}${GAMES_PREFIX}/share/${PN}"/{applications,pixmaps}
82 mv "${D}/${GAMES_PREFIX}/share/${PN}" "${D}/${GAMES_DATADIR}/"
83 mv "${D}/${GAMES_PREFIX}/lib" "${D}/usr/"
84 if use songs; then
85 insinto "${GAMES_DATADIR}"/ultrastar
86 doins -r ../../songs || die "doins songs failed"
88 doicon data/${PN}.xpm
89 domenu data/${PN}.desktop
90 dodoc ../docs/*.txt
91 prepgamesdirs