/[gentoo-x86]/games-strategy/freecnc/freecnc-0.2.0.ebuild
Gentoo

Contents of /games-strategy/freecnc/freecnc-0.2.0.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.9 - (show annotations) (download)
Thu Oct 5 18:18:21 2006 UTC (11 years, 10 months ago) by wolf31o2
Branch: MAIN
CVS Tags: HEAD
Changes since 1.8: +1 -1 lines
FILE REMOVED
Stable on x86 wrt bug #147783 and removing 0.2.0 ebuilds/patches.
(Portage version: 2.1.2_pre1-r4)
 (Signed Manifest commit)

1 # Copyright 1999-2006 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/games-strategy/freecnc/freecnc-0.2.0.ebuild,v 1.8 2006/05/27 00:18:10 tupone Exp $
4
5 inherit games flag-o-matic eutils
6
7 DESCRIPTION="SDL-rewrite of the classical real time strategy hit Command & Conquer"
8 HOMEPAGE="http://freecnc-sf.holarse.net/"
9 SRC_URI="mirror://sourceforge/freecnc/freecnc++-${PV}-src.tar.bz2
10 nocd? ( ftp://ftp.westwood.com/pub/cc1/previews/demo/cc1demo1.zip )
11 nocd? ( ftp://ftp.westwood.com/pub/cc1/previews/demo/cc1demo2.zip )"
12
13 LICENSE="GPL-2"
14 SLOT="0"
15 KEYWORDS="x86"
16 IUSE="zlib nocd"
17
18 RDEPEND="media-libs/libsdl
19 media-libs/sdl-net
20 zlib? ( sys-libs/zlib )"
21 DEPEND="${RDEPEND}
22 app-arch/unzip"
23
24 S=${WORKDIR}/freecnc++
25
26 src_unpack() {
27 unpack freecnc++-${PV}-src.tar.bz2
28 if use nocd ; then
29 mkdir data ; cd data
30 unpack cc1demo1.zip cc1demo2.zip
31 for f in * ; do
32 mv ${f} $(echo ${f} | awk '{print tolower($1)}') || die "moving $f"
33 done
34 fi
35 cd "${S}"
36 epatch "${FILESDIR}"/${PV}-makefile-cflags.patch \
37 "${FILESDIR}"/${PV}-remove-root.patch \
38 "${FILESDIR}"/${PV}-gentoo-paths.patch \
39 "${FILESDIR}"/${P}-endian.patch
40 rm -f src/include/endian.h
41 sed -i \
42 -e "s:GENTOO_LOGDIR:${GAMES_LOGDIR}:" \
43 -e "s:GENTOO_CONFDIR:${GAMES_SYSCONFDIR}/${PN}/:" \
44 -e "s:GENTOO_DATADIR:${GAMES_DATADIR}/${PN}/:" \
45 src/freecnc.cpp src/vfs/vfs.cpp \
46 || die "sed failed"
47 }
48
49 src_compile() {
50 emake EXTRACFLAGS="${CFLAGS}" || die "emake failed"
51 }
52
53 src_install() {
54 exeinto "${GAMES_LIBDIR}"/${PN}
55 doexe freecnc *.vfs
56 dogamesbin "${FILESDIR}"/freecnc || die "dogamesbin failed"
57 dosed "s:GENTOO_DIR:${GAMES_LIBDIR}/${PN}:" ${GAMES_BINDIR}/freecnc
58 insinto "${GAMES_DATADIR}"/${PN}/conf
59 doins conf/*
60 insinto "${GAMES_SYSCONFDIR}"/${PN}
61 doins conf/*
62 dodoc AUTHORS ChangeLog NEWS README THANKS TODO
63 if use nocd ; then
64 cd "${WORKDIR}"/data
65 insinto "${GAMES_DATADIR}"/${PN}
66 doins *.mix *.aud || die "doins failed"
67 dodoc *.txt
68 fi
69 prepgamesdirs
70 }
71
72 pkg_postinst() {
73 games_pkg_postinst
74 einfo "If you have the C&C games, then just copy the .mix"
75 einfo "to ${GAMES_DATADIR}/${PN}"
76 einfo "Otherwise, re-emerge freecnc with 'nocd' in your USE."
77 }

  ViewVC Help
Powered by ViewVC 1.1.20