diff options
Diffstat (limited to 'games-fps/quake2-data/quake2-data-3.20.ebuild')
-rw-r--r-- | games-fps/quake2-data/quake2-data-3.20.ebuild | 46 |
1 files changed, 26 insertions, 20 deletions
diff --git a/games-fps/quake2-data/quake2-data-3.20.ebuild b/games-fps/quake2-data/quake2-data-3.20.ebuild index 2895730c1565..49b4daca8b63 100644 --- a/games-fps/quake2-data/quake2-data-3.20.ebuild +++ b/games-fps/quake2-data/quake2-data-3.20.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2005 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/games-fps/quake2-data/quake2-data-3.20.ebuild,v 1.14 2005/10/30 05:28:23 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/games-fps/quake2-data/quake2-data-3.20.ebuild,v 1.15 2005/10/31 23:03:45 vapier Exp $ inherit eutils games @@ -19,39 +19,45 @@ RDEPEND="" S=${WORKDIR} pkg_setup() { - cdrom_get_cds Install - if [[ -e ${CDROM_ROOT}/Install/Data ]] ; then - export CDROM_ROOT=${CDROM_ROOT}/Install/Data - einfo "Source is the CD" - elif [[ -e ${CDROM_ROOT}/baseq2 ]] ; then - export CDROM_ROOT=${CDROM_ROOT} - einfo "Source is an installed copy" - else - die "Could not determine what ${CDROM_ROOT} points at" - fi - + export CDROM_SET_NAMES=("Existing Install" "Quake2 CD" "Quake4 Bonus DVD") + cdrom_get_cds baseq2:Install:Movies games_pkg_setup } +src_unpack() { + # The .exe is just a self-extracting .zip + echo ">>> Unpacking ${A} to ${PWD}" + unzip -qo "${DISTDIR}/${A}" || die "Failed to unpack ${A}" +} + src_install() { dodoc DOCS/* 3.20_Changes.txt newdoc ctf/readme.txt ctf-readme.txt - dohtml -r "${CDROM_ROOT}"/DOCS/quake2_manual/* + case ${CDROM_SET} in + 0|1) dohtml -r "${CDROM_ROOT}"/DOCS/quake2_manual/* ;; + 2) dodoc "${CDROM_ROOT}"/Docs/* ;; + esac + + local baseq2_cdpath + case ${CDROM_SET} in + 0|1) baseq2_cdpath=${CDROM_ROOT}/baseq2;; + 2) baseq2_cdpath=${CDROM_ROOT}/setup/Data/baseq2;; + esac - dodir ${GAMES_DATADIR}/${PN}/baseq2 + dodir ${GAMES_DATADIR}/quake2/baseq2 if use videos ; then - insinto ${GAMES_DATADIR}/${PN}/baseq2/video - doins "${CDROM_ROOT}"/baseq2/video/* + insinto ${GAMES_DATADIR}/quake2/baseq2/video + doins "${baseq2_cdpath}"/video/* || die "doins videos" fi - insinto ${GAMES_DATADIR}/${PN}/baseq2 - doins "${CDROM_ROOT}"/baseq2/pak0.pak || die "couldnt grab pak0.pak" + insinto ${GAMES_DATADIR}/quake2/baseq2 + doins "${baseq2_cdpath}"/pak0.pak || die "couldnt grab pak0.pak" doins baseq2/*.pak || die "couldnt grab release paks" doins baseq2/maps.lst || die "couldnt grab maps.lst" - cp -R baseq2/players "${D}/${GAMES_DATADIR}"/${PN}/baseq2/ || die "couldnt grab player models" + cp -R baseq2/players "${D}/${GAMES_DATADIR}"/quake2/baseq2/ || die "couldnt grab player models" - insinto "${GAMES_DATADIR}"/${PN}/ctf + insinto "${GAMES_DATADIR}"/quake2/ctf doins ctf/*.{cfg,ico,pak} || die "couldnt grab ctf" prepgamesdirs |