/[gentoo-x86]/games-action/d1x-rebirth/d1x-rebirth-0.58.1.ebuild
Gentoo

Contents of /games-action/d1x-rebirth/d1x-rebirth-0.58.1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (show annotations) (download)
Sun Apr 19 09:47:40 2015 UTC (4 years, 10 months ago) by pacho
Branch: MAIN
CVS Tags: HEAD
Changes since 1.1: +2 -2 lines
x86 stable wrt bug #539068

(Portage version: 2.2.18/cvs/Linux x86_64, RepoMan options: --include-arches="x86", signed Manifest commit with key A188FBD4)

1 # Copyright 1999-2015 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/games-action/d1x-rebirth/d1x-rebirth-0.58.1.ebuild,v 1.1 2015/01/27 07:45:13 mr_bones_ Exp $
4
5 EAPI=5
6 CDROM_OPTIONAL="yes"
7 inherit eutils cdrom scons-utils games
8
9 DV=1
10 MY_P=${PN}_v${PV}-src
11 DESCRIPTION="Descent Rebirth - enhanced Descent ${DV} engine"
12 HOMEPAGE="http://www.dxx-rebirth.com/"
13 SRC_URI="http://www.dxx-rebirth.com/download/dxx/${MY_P}.tar.gz
14 http://www.dxx-rebirth.com/download/dxx/res/d1xrdata.zip
15 http://www.dxx-rebirth.com/download/dxx/res/dxx-rebirth_icons.zip
16 opl3-musicpack? ( http://www.dxx-rebirth.com/download/dxx/res/d${DV}xr-opl3-music.zip )
17 sc55-musicpack? ( http://www.dxx-rebirth.com/download/dxx/res/d${DV}xr-sc55-music.zip ) cdinstall? ( http://www.dxx-rebirth.com/download/dxx/res/d1datapt.zip )
18 linguas_de? ( http://www.dxx-rebirth.com/download/dxx/res/d${DV}xr-briefings-ger.zip )"
19
20 LICENSE="D1X GPL-2 public-domain"
21 SLOT="0"
22 KEYWORDS="~amd64 x86"
23 IUSE="cdinstall debug demo ipv6 linguas_de +music opengl opl3-musicpack sc55-musicpack"
24 REQUIRED_USE="?? ( cdinstall demo )
25 ?? ( opl3-musicpack sc55-musicpack )
26 opl3-musicpack? ( music )
27 sc55-musicpack? ( music )"
28
29 RDEPEND="dev-games/physfs[hog,zip]
30 media-libs/libsdl[X,sound,joystick,opengl?,video]
31 cdinstall? ( !games-action/descent1-demodata )
32 music? (
33 media-libs/sdl-mixer[timidity]
34 )
35 opengl? (
36 virtual/opengl
37 virtual/glu
38 )"
39 DEPEND="${RDEPEND}
40 app-arch/unzip"
41 PDEPEND="demo? ( games-action/descent1-demodata )"
42
43 S=${WORKDIR}/${MY_P}
44
45 src_unpack() {
46 unpack ${MY_P}.tar.gz dxx-rebirth_icons.zip
47 if use cdinstall ; then
48 unpack d1datapt.zip
49 cdrom_get_cds descent/descent.hog
50 mkdir "${S}"/Data
51 cp \
52 ${CDROM_ROOT}/descent/descent.{hog,pig} \
53 ${CDROM_ROOT}/descent/chaos.{hog,msn} \
54 "${S}"/Data || die
55 fi
56 }
57
58 src_prepare() {
59 if use cdinstall ; then
60 cd Data
61 patch -p0 < "${WORKDIR}"/d1datapt/descent.hog.diff descent.hog
62 patch -p0 < "${WORKDIR}"/d1datapt/descent.pig.diff descent.pig
63 fi
64 epatch "${FILESDIR}"/${P}-flags.patch
65 }
66
67 src_compile() {
68 escons \
69 verbosebuild=1 \
70 sharepath="${GAMES_DATADIR}/d${DV}x" \
71 $(use_scons ipv6) \
72 $(use_scons music sdlmixer) \
73 $(use_scons debug) \
74 $(use_scons opengl) || die
75 }
76
77 src_install() {
78 dodoc {CHANGELOG,INSTALL,README,RELEASE-NOTES}.txt
79
80 insinto "${GAMES_DATADIR}/d${DV}x"
81 doins "${DISTDIR}"/d1xrdata.zip
82 # None of the following zip files need to be extracted.
83 use linguas_de && doins "${DISTDIR}"/d${DV}xr-briefings-ger.zip
84 use opl3-musicpack && doins "${DISTDIR}"/d${DV}xr-opl3-music.zip
85 use sc55-musicpack && doins "${DISTDIR}"/d${DV}xr-sc55-music.zip
86
87 if use cdinstall ; then
88 doins Data/descent.{hog,pig}
89 insinto "${GAMES_DATADIR}"/d${DV}x/missions
90 doins Data/chaos.{hog,msn}
91 fi
92 doicon "${WORKDIR}/${PN}.xpm"
93
94 dogamesbin d${DV}x-rebirth
95 make_desktop_entry d${DV}x-rebirth "Descent ${DV} Rebirth"
96 prepgamesdirs
97 }
98
99 pkg_postinst() {
100 games_pkg_postinst
101 if ! use cdinstall ; then
102 echo
103 elog "To play the full game enable USE=\"cdinstall\" or manually "
104 elog "copy the files to ${GAMES_DATADIR}/d${DV}x."
105 elog "See /usr/share/doc/${PF}/INSTALL.txt for details."
106 echo
107 fi
108 }

  ViewVC Help
Powered by ViewVC 1.1.20