# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
description xgalaga is a rework of the Galaga shooting game.
long_description ${description}
homepage http://sourceforge.net/projects/xgalaga/
checksums md5 f37c3377b245d2d53b33eb489966bf28 \
sha1 ef40ad833d2434b0643d4c00202bd75ec14b94ac \
rmd160 b55a97187b61ffe7c072ecd784cf9a16fe568c26
patchfiles patch-Makefile.in.diff \
depends_lib port:xorg-libX11 \
# The shipped config.guess and config.sub are too old to recognize OS X.
# https://sourceforge.net/p/xgalaga/bugs/2/
xinstall -m 644 -W ${prefix}/share/libtool/build-aux config.guess config.sub ${worksrcpath}
# The configure script uses these variables incorrectly, hence the strange values.
configure.pre_args --prefix=${prefix}/share/${name}
configure.args --exec-prefix=${prefix}/bin \
--mandir=${prefix}/share/man \
--with-xpm-lib=${prefix}/lib
set docdir ${prefix}/share/doc/${subport}
xinstall -d ${destroot}${docdir}
xinstall -m 644 -W ${worksrcpath} \
# xgalaga <= 2.1.1.0_1 installed its manpage directly into /usr; remove it if found.
# https://sourceforge.net/p/xgalaga/bugs/11/
foreach filepath {/usr/share/man/xgalaga.6x.gz} {
if {[file exists ${filepath}] && [registry_file_registered ${filepath}] == "0"} {
if {[catch {delete ${filepath}}]} {
ui_warn "Cannot delete ${filepath}; please remove it manually"