Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 17 Dec 2012 16:00:15 +0000 (UTC)
From:      Pawel Pekala <pawel@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r309106 - in head/games/kajaani-kombat: . files
Message-ID:  <201212171600.qBHG0F1d018771@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: pawel
Date: Mon Dec 17 16:00:14 2012
New Revision: 309106
URL: http://svnweb.freebsd.org/changeset/ports/309106

Log:
  - Set PORTNAME to kajaani-kombat, remove PKGNAMEPREFIX, DISTNAME, WRKSRC
  - Improve COMMENT, add manpage, execute script and desktop file
  - Convert to OptionsNG
  - Switch from PLIST_FILES to pkg-plist file
  
  While I'm here:
  - Use ALL_TARGET instead of reimplementing do-build target
  - Respect CXXFLAGS
  
  PR:		ports/170461
  Submitted by:	nemysis <nemysis@gmx.ch> (maintainer)

Added:
  head/games/kajaani-kombat/files/
  head/games/kajaani-kombat/files/kajaani-kombat.in   (contents, props changed)
  head/games/kajaani-kombat/pkg-plist   (contents, props changed)
Modified:
  head/games/kajaani-kombat/Makefile

Modified: head/games/kajaani-kombat/Makefile
==============================================================================
--- head/games/kajaani-kombat/Makefile	Mon Dec 17 15:39:36 2012	(r309105)
+++ head/games/kajaani-kombat/Makefile	Mon Dec 17 16:00:14 2012	(r309106)
@@ -1,69 +1,53 @@
-# New Ports collection makefile for:	kajaani-kombat
-# Date created:		2012-04-27
-# Whom:			nemysis@gmx.ch
-#
+# Created by: nemysis@gmx.ch
 # $FreeBSD$
-#
 
-PORTNAME=	kombat
+PORTNAME=	kajaani-kombat
 PORTVERSION=	0.7
+PORTREVISION=	1
 CATEGORIES=	games
 MASTER_SITES=	http://kombat.kajaani.net/dl/
-PKGNAMEPREFIX=	kajaani-
-DISTNAME=	${PKGNAMEPREFIX}${PORTNAME}-${PORTVERSION}
 
 MAINTAINER=	nemysis@gmx.ch
-COMMENT=	Kajaani Kombat is a funny multiplayer game... and much more
+COMMENT=	Funny multiplayer game... and much more
 
 LICENSE=	GPLv2
 
-LIB_DEPENDS=	freetype.9:${PORTSDIR}/print/freetype2
+LIB_DEPENDS=	freetype:${PORTSDIR}/print/freetype2
 
-WRKSRC=		${WRKDIR}/${PKGNAMEPREFIX}${PORTNAME}-${PORTVERSION}
-
-USE_GMAKE=	yes
 USE_SDL=	sdl image mixer net ttf
+USE_GMAKE=	yes
+ALL_TARGET=	client server
+USE_ICONV=	yes
 MAKE_JOBS_SAFE=	yes
 
-PLIST_FILES=	bin/kajaani-kombat \
-		bin/kajaani-kombat-server \
-		share/pixmaps/kajaani-kombat.png
-
-PORTDATA=	*
 PORTDOCS=	AUTHORS ChangeLog README
-DATADIR=	${PREFIX}/share/${PKGNAMEPREFIX}${PORTNAME}
-DOCSDIR=	${PREFIX}/share/doc/${PKGNAMEPREFIX}${PORTNAME}
 
-do-build:
-	@(cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ${GMAKE})
-	@(cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ${GMAKE} server)
+MAN6=		${PORTNAME}.6
+
+SUB_FILES=	${PORTNAME}
+
+DESKTOP_ENTRIES="Kajaani Kombat" "${COMMENT}" "${PORTNAME}" \
+		"${PORTNAME}" "Game;ArcadeGame;" false
+
+.include <bsd.port.options.mk>
+
+post-patch:
+	@${REINPLACE_CMD} 's|-O||g; s|-Wall $$(DEBUG)|${CXXFLAGS} &|' \
+		${WRKSRC}/Makefile
 
 do-install:
-# Scripts
-	@${PRINTF} "#!/bin/sh\n\ncd ${DATADIR} &&\
-		./kajaani-kombat\n" > ${WRKDIR}/kajaani-kombat.sh
-	@${INSTALL_SCRIPT} ${WRKDIR}/kajaani-kombat.sh ${PREFIX}/bin/kajaani-kombat
-	@${PRINTF} "#!/bin/sh\n\ncd ${DATADIR} &&\
-		./kajaani-kombat-server\n" > ${WRKDIR}/kajaani-kombat-server.sh
-	@${INSTALL_SCRIPT} ${WRKDIR}/kajaani-kombat-server.sh ${PREFIX}/bin/kajaani-kombat-server
-# Executable
+	${INSTALL_SCRIPT} ${WRKDIR}/${PORTNAME} ${PREFIX}/bin
 	${MKDIR} ${DATADIR}
-	${INSTALL_PROGRAM} ${WRKSRC}/kajaani-kombat ${DATADIR}
-	${INSTALL_PROGRAM} ${WRKSRC}/kajaani-kombat-server ${DATADIR}
+	${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${DATADIR}
+	${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME}-server ${DATADIR}
+	@(cd ${WRKSRC} && ${INSTALL_DATA} *.png *.ogg *.ttf ${DATADIR})
+	${LN} -sf ${DATADIR}/logo.png ${PREFIX}/share/pixmaps/${PORTNAME}.png
 
-post-install:
-# Data
-.if !defined (NOPORTDATA)
-	${INSTALL_DATA} ${WRKSRC}/*.png ${WRKSRC}/*.ogg ${WRKSRC}/*.ttf ${DATADIR}
-	${INSTALL_DATA} ${WRKSRC}/logo.png ${PREFIX}/share/pixmaps/${PKGNAMEPREFIX}${PORTNAME}.png
-.endif
+	${INSTALL_MAN} ${WRKSRC}/${MAN6} ${MAN6PREFIX}/man/man6
 
-# Documentations
-.if !defined(NOPORTDOCS)
+.if ${PORT_OPTIONS:MDOCS}
 	${MKDIR} ${DOCSDIR}
-.  for f in ${PORTDOCS}
-	${INSTALL_DATA} ${WRKSRC}/${f} ${DOCSDIR}
-.  endfor
+	${INSTALL_DATA} ${PORTDOCS:S|^|${WRKSRC}/|} ${DOCSDIR}
 .endif
 
 .include <bsd.port.mk>

Added: head/games/kajaani-kombat/files/kajaani-kombat.in
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/games/kajaani-kombat/files/kajaani-kombat.in	Mon Dec 17 16:00:14 2012	(r309106)
@@ -0,0 +1,7 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+
+cd "%%DATADIR%%"
+exec ./kajaani-kombat "${@}"

Added: head/games/kajaani-kombat/pkg-plist
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/games/kajaani-kombat/pkg-plist	Mon Dec 17 16:00:14 2012	(r309106)
@@ -0,0 +1,168 @@
+bin/kajaani-kombat
+%%DATADIR%%/0ammo.png
+%%DATADIR%%/0big_ammo.png
+%%DATADIR%%/0big_cannon.png
+%%DATADIR%%/0big_cannon_dest.png
+%%DATADIR%%/0big_cannonplacer.png
+%%DATADIR%%/0blockplacer.png
+%%DATADIR%%/0cannon.png
+%%DATADIR%%/0cannon_dest.png
+%%DATADIR%%/0cannon_down.ogg
+%%DATADIR%%/0cannonplacer.png
+%%DATADIR%%/0castle.png
+%%DATADIR%%/0chooser.png
+%%DATADIR%%/0conquered_grass.png
+%%DATADIR%%/0cursor.png
+%%DATADIR%%/0cursor_ch.png
+%%DATADIR%%/0cursor_lock.png
+%%DATADIR%%/0face.png
+%%DATADIR%%/0sound_cannon_down.ogg
+%%DATADIR%%/0sound_fire.ogg
+%%DATADIR%%/0sound_hit.ogg
+%%DATADIR%%/0sound_hit_cannon.ogg
+%%DATADIR%%/0sound_select_castle.ogg
+%%DATADIR%%/0wall.png
+%%DATADIR%%/1ammo.png
+%%DATADIR%%/1big_ammo.png
+%%DATADIR%%/1big_cannon.png
+%%DATADIR%%/1big_cannon_dest.png
+%%DATADIR%%/1big_cannonplacer.png
+%%DATADIR%%/1blockplacer.png
+%%DATADIR%%/1cannon.png
+%%DATADIR%%/1cannon_dest.png
+%%DATADIR%%/1cannon_down.ogg
+%%DATADIR%%/1cannonplacer.png
+%%DATADIR%%/1castle.png
+%%DATADIR%%/1chooser.png
+%%DATADIR%%/1conquered_grass.png
+%%DATADIR%%/1cursor.png
+%%DATADIR%%/1cursor_ch.png
+%%DATADIR%%/1cursor_lock.png
+%%DATADIR%%/1face.png
+%%DATADIR%%/1sound_cannon_down.ogg
+%%DATADIR%%/1sound_fire.ogg
+%%DATADIR%%/1sound_hit.ogg
+%%DATADIR%%/1sound_hit_cannon.ogg
+%%DATADIR%%/1sound_select_castle.ogg
+%%DATADIR%%/1wall.png
+%%DATADIR%%/2ammo.png
+%%DATADIR%%/2big_ammo.png
+%%DATADIR%%/2big_cannon.png
+%%DATADIR%%/2big_cannon_dest.png
+%%DATADIR%%/2big_cannonplacer.png
+%%DATADIR%%/2blockplacer.png
+%%DATADIR%%/2cannon.png
+%%DATADIR%%/2cannon_dest.png
+%%DATADIR%%/2cannon_down.ogg
+%%DATADIR%%/2cannonplacer.png
+%%DATADIR%%/2castle.png
+%%DATADIR%%/2chooser.png
+%%DATADIR%%/2conquered_grass.png
+%%DATADIR%%/2cursor.png
+%%DATADIR%%/2cursor_ch.png
+%%DATADIR%%/2cursor_lock.png
+%%DATADIR%%/2face.png
+%%DATADIR%%/2sound_cannon_down.ogg
+%%DATADIR%%/2sound_fire.ogg
+%%DATADIR%%/2sound_hit.ogg
+%%DATADIR%%/2sound_hit_cannon.ogg
+%%DATADIR%%/2sound_select_castle.ogg
+%%DATADIR%%/2wall.png
+%%DATADIR%%/3ammo.png
+%%DATADIR%%/3big_ammo.png
+%%DATADIR%%/3big_cannon.png
+%%DATADIR%%/3big_cannon_dest.png
+%%DATADIR%%/3big_cannonplacer.png
+%%DATADIR%%/3blockplacer.png
+%%DATADIR%%/3cannon.png
+%%DATADIR%%/3cannon_dest.png
+%%DATADIR%%/3cannon_down.ogg
+%%DATADIR%%/3cannonplacer.png
+%%DATADIR%%/3castle.png
+%%DATADIR%%/3chooser.png
+%%DATADIR%%/3conquered_grass.png
+%%DATADIR%%/3cursor.png
+%%DATADIR%%/3cursor_ch.png
+%%DATADIR%%/3cursor_lock.png
+%%DATADIR%%/3face.png
+%%DATADIR%%/3sound_cannon_down.ogg
+%%DATADIR%%/3sound_fire.ogg
+%%DATADIR%%/3sound_hit.ogg
+%%DATADIR%%/3sound_hit_cannon.ogg
+%%DATADIR%%/3sound_select_castle.ogg
+%%DATADIR%%/3wall.png
+%%DATADIR%%/4ammo.png
+%%DATADIR%%/4big_ammo.png
+%%DATADIR%%/4big_cannon.png
+%%DATADIR%%/4big_cannon_dest.png
+%%DATADIR%%/4big_cannonplacer.png
+%%DATADIR%%/4blockplacer.png
+%%DATADIR%%/4cannon.png
+%%DATADIR%%/4cannon_dest.png
+%%DATADIR%%/4cannonplacer.png
+%%DATADIR%%/4castle.png
+%%DATADIR%%/4chooser.png
+%%DATADIR%%/4conquered_grass.png
+%%DATADIR%%/4cursor.png
+%%DATADIR%%/4cursor_ch.png
+%%DATADIR%%/4cursor_lock.png
+%%DATADIR%%/4face.png
+%%DATADIR%%/4sound_hit_cannon.ogg
+%%DATADIR%%/4wall.png
+%%DATADIR%%/Vera.ttf
+%%DATADIR%%/bg.png
+%%DATADIR%%/connect_butconn.png
+%%DATADIR%%/connect_butconn_act.png
+%%DATADIR%%/connect_butconn_focus.png
+%%DATADIR%%/connect_imgname.png
+%%DATADIR%%/connect_imgname2.png
+%%DATADIR%%/connect_imgport.png
+%%DATADIR%%/connect_imgserv.png
+%%DATADIR%%/host_butstart.png
+%%DATADIR%%/host_butstart_act.png
+%%DATADIR%%/host_butstart_focus.png
+%%DATADIR%%/host_imgname.png
+%%DATADIR%%/host_imgname2.png
+%%DATADIR%%/host_imgnumcastles.png
+%%DATADIR%%/host_imgnumpl.png
+%%DATADIR%%/host_imgnumwins.png
+%%DATADIR%%/host_imgport.png
+%%DATADIR%%/kajaani-kombat
+%%DATADIR%%/kajaani-kombat-server
+%%DATADIR%%/logo.png
+%%DATADIR%%/main_buthost.png
+%%DATADIR%%/main_buthost_act.png
+%%DATADIR%%/main_buthost_focus.png
+%%DATADIR%%/main_butopt.png
+%%DATADIR%%/main_butopt_act.png
+%%DATADIR%%/main_butopt_focus.png
+%%DATADIR%%/main_butquit.png
+%%DATADIR%%/main_butquit_act.png
+%%DATADIR%%/main_butquit_focus.png
+%%DATADIR%%/main_butstart.png
+%%DATADIR%%/main_butstart_act.png
+%%DATADIR%%/main_butstart_focus.png
+%%DATADIR%%/music_intro.ogg
+%%DATADIR%%/music_placecannon.ogg
+%%DATADIR%%/music_repair.ogg
+%%DATADIR%%/music_shoot.ogg
+%%DATADIR%%/numpl_butone.png
+%%DATADIR%%/numpl_butone_act.png
+%%DATADIR%%/numpl_butone_focus.png
+%%DATADIR%%/numpl_buttwo.png
+%%DATADIR%%/numpl_buttwo_act.png
+%%DATADIR%%/numpl_buttwo_focus.png
+%%DATADIR%%/numpl_imgtext.png
+%%DATADIR%%/options_apply.png
+%%DATADIR%%/options_apply_act.png
+%%DATADIR%%/options_apply_focus.png
+%%DATADIR%%/options_cancel.png
+%%DATADIR%%/options_cancel_act.png
+%%DATADIR%%/options_cancel_focus.png
+%%DATADIR%%/sound_block_down.ogg
+%%DATADIR%%/sound_block_rotate.ogg
+%%DATADIR%%/sound_gui_navigation.ogg
+%%DATADIR%%/sound_gui_select.ogg
+%%DATADIR%%/three_sec_warning.ogg
+share/pixmaps/kajaani-kombat.png
+@dirrm %%DATADIR%%



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201212171600.qBHG0F1d018771>