# $Id: Portfile,v 1.11 2004/05/19 16:31:56 mww Exp $

PortSystem 1.0

name		openmortal
version		0.7
categories	games
platforms	darwin
maintainers	mww@opendarwin.org
description	Mortal Szombat is a parody of the coin-up game Mortal Kombat
long_description	Mortal Szombat is a parody of the popular coin-up \
			game, Mortal Kombat. It is currently playable (maybe \
			even enjoyable), although it is still under \
			development. Only two-player game is supported, \
			single-player games against computer opponent is not \
			planned yet. There are currently 9 playable \
			characters, and 8 more in the making!

homepage	http://openmortal.sourceforge.net/
master_sites	sourceforge
checksums	md5 95278382bb563906fce624d833a845cf
use_bzip2	yes

depends_lib	bin:sdl-config:libsdl \
		lib:libSDL_mixer:libsdl_mixer \
		lib:libSDL_image:libsdl_image \
		lib:libSDL_ttf:libsdl_ttf \
		lib:libSDL_net:libsdl_net \
		lib:libfreetype:freetype \
		bin:perl:perl5.8

variant darwin	{
	patchfiles	patch-gfx.cpp.diff \
			patch-sge_tt_text.cpp.diff
	post-destroot	{
		xinstall -d -m 755 \
			${destroot}/Applications/DarwinPorts/OpenMortal.app/Contents/MacOS \
			${destroot}/Applications/DarwinPorts/OpenMortal.app/Resources
		system "ln -s ${prefix}/bin/openmortal \
			${destroot}/Applications/DarwinPorts/OpenMortal.app/Contents/MacOS/OpenMortal"
		xinstall -m 644 ${filespath}/OpenMortal.icns \
			${destroot}/Applications/DarwinPorts/OpenMortal.app/Resources/
	}
}

configure.env	LDFLAGS="-L${prefix}/lib" \
		CPPFLAGS="-I${prefix}/include"
configure.args	--enable-main \
		--enable-characters \
		--enable-additional \
		--enable-thirdparty \
		--disable-sdltest
