# $Id: Portfile 37929 2008-06-29 22:28:34Z ryandesign@macports.org $ PortSystem 1.0 name rrgbis version 1.06-2 categories games platforms darwin maintainers simon openmaintainer description Real time strategy game with fleets of spaceships. long_description ${description} homepage http://rrgbis.sourceforge.net/ master_sites sourceforge checksums md5 195038ed3b76e2189fa126e0c88ddcba \ sha1 82b65ad78de21f3760a51377f4ed75c3b497780b \ rmd160 bab91a9d4ead8e0aa6c4986c0f0ecae679ac3871 use_bzip2 yes worksrcdir ${name} depends_lib port:libsdl \ port:libsdl_image \ port:libsdl_mixer \ port:libvorbis patchfiles patch-Makefile.diff \ patch-src_GLSDL.cpp.diff pre-patch { # Convert files from DOS to UNIX linefeeds before patching. reinplace "s/\r$//g" ${worksrcpath}/Makefile } post-patch { # Set the correct path to the installed rrgbis data in the settings file. reinplace "s|pwd|${prefix}/share/rrgbis/|g" ${worksrcpath}/settings.dat } use_configure no build.target {} destroot { # Install the helper script which automatically sets the correct # LD_LIBRARY_PATH variable and set the right ${prefix} path. xinstall ${portpath}/${filesdir}/rrgbis ${destroot}${prefix}/bin reinplace "s|__PREFIX__|${prefix}|g" ${destroot}${prefix}/bin/rrgbis # Install the helper setup script which creates ~/.rrgbis and the # settings.dat file in it. xinstall ${portpath}/${filesdir}/rrgbis-setup ${destroot}${prefix}/bin reinplace "s|__PREFIX__|${prefix}|g" ${destroot}${prefix}/bin/rrgbis-setup # Install the real binary and rename it to rrgbis-bin. copy ${worksrcpath}/rrgbis ${destroot}${prefix}/bin/rrgbis-bin # Create the directory for the rrgbis data. xinstall -d ${destroot}${prefix}/share/rrgbis # Copy all data files and directories to ${destroot}. set files {aiscripts images missions music settings.dat sound \ squirrelscripts unitdata unitpictures} foreach file $files { move ${worksrcpath}/${file} ${destroot}${prefix}/share/rrgbis/${file} } } post-install { ui_msg "****************************************************************" ui_msg "* *" ui_msg "* If you run rrgbis the first time, you must call rrgbis-setup *" ui_msg "* so the default configuration data can be set up. *" ui_msg "* *" ui_msg "* This script is provided by macports and not part of the *" ui_msg "* official distribution! If there are any problems with it *" ui_msg "* contact the port maintainer. *" ui_msg "* *" ui_msg "****************************************************************" } livecheck.version 1.06