# Copyright 1999-2006 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ inherit games EXPORT_FUNCTIONS src_install SLOT="0" # "-*" because UT2004 doesn't run on other arches KEYWORDS="-* x86 amd64" IUSE="" LICENSE="freedist" RESTRICT="nomirror nostrip" # Why depend on libc? DEPEND="" # ut2004-3339 is no longer in portage RDEPEND=">=games-fps/ut2004-3369-r1" S=${WORKDIR} dir=${GAMES_PREFIX_OPT}/ut2004 games-ut2k4mappack_src_install() { insinto "${dir}" if [ -n "${MOD_DIR}" ]; then # Am installing into a subdirectory of UT2004 if [ ! -d "${MOD_DIR}" ]; then insinto "${dir}/${MOD_DIR}" fi if [ -n "${MOD_NAME}" ]; then if [ -n "${MOD_ICON}" ]; then # Install custom icon # This Bash voodoo determines the file extension, e.g. "xpm" MOD_ICON_EXT=${MOD_ICON##*.} newicon "${MOD_ICON}" "${PN}.${MOD_ICON_EXT}" \\ || die "newicon ${MOD_ICON} failed" else # Use standard icon supplied by UT2004 MOD_ICON="ut2004.xpm" fi # Set up commandline and desktop menu entry games_make_wrapper ${PN} "ut2004 -mod=${MOD_DIR}" make_desktop_entry ${PN} "UT2004 - ${MOD_NAME}" "${MOD_ICON}" fi fi # We expect anything not wanted to have been deleted by the ebuild doins -r * || die "doins -r failed" prepgamesdirs }