# Copyright 2016 Julian Ospald # Distributed under the terms of the GNU General Public License v2 EDITION="collect_edition" require gtk-icon-cache \ sourceforge [ pnv=sauerbraten_${PV//./_}_${EDITION}_linux ] SUMMARY="Cube 2: Sauerbraten is an open source game engine (Cube 2) with freeware game data (Sauerbraten)" HOMEPAGE="http://sauerbraten.org/" LICENCES="ZLIB freedist" SLOT="0" PLATFORMS="~amd64 ~x86" MYOPTIONS="" DEPENDENCIES=" build+run: media-libs/SDL:0[X] media-libs/SDL_image:1 media-libs/SDL_mixer:0[ogg] x11-libs/libX11 sys-libs/zlib x11-dri/glu x11-dri/mesa run: group/sauerbraten [[ note = [ for server ] ]] user/sauerbraten [[ note = [ for server ] ]] " WORK=${WORKBASE}/${PN} src_prepare() { edo rm -r sauerbraten_unix bin_unix src/{include,lib,vcpp} default # Fix links so they point to the correct directory edo sed -i -e 's:docs/::' README.html } src_compile() { emake -C src master server client } src_install() { local LIBEXECDIR="/usr/$(exhost --target)/libexec/${PN}" local DATADIR="/usr/share/${PN}" local STATEDIR="/var/lib/${PN}" # Install the game data insinto "${DATADIR}" doins -r data packages # Install the client executable exeinto "${LIBEXECDIR}" doexe src/sauer_client # Install the client wrapper herebin ${PN}-client <