Bug 170738 - [MAINTAINER] games/mopesnake: Makefile changed, OptionsNG, deleted script in Makefile
Summary: [MAINTAINER] games/mopesnake: Makefile changed, OptionsNG, deleted script in ...
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Jason Helfman
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-08-18 13:40 UTC by nemysis
Modified: 2012-09-14 07:30 UTC (History)
1 user (show)

See Also:


Attachments
mopesnake-0.5_1.patch (1.70 KB, patch)
2012-08-18 13:40 UTC, nemysis
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description nemysis 2012-08-18 13:40:09 UTC
Makefile changed:

Changed all to ${PORTNAME}


OptionsNG

.include <bsd.port.options.mk>

.if ${PORT_OPTIONS:MDOCS}


Added file(s):
- files/mopesnake.in

Generated with FreeBSD Port Tools 0.99_6 (mode: change, diff: ports)
Comment 1 Po-Chuan Hsieh freebsd_committer freebsd_triage 2012-08-18 17:09:02 UTC
Responsible Changed
From-To: freebsd-ports-bugs->sunpoet

I'll take it.
Comment 2 Po-Chuan Hsieh freebsd_committer freebsd_triage 2012-08-20 12:00:23 UTC
Responsible Changed
From-To: sunpoet->jgh

Jason would like to take nemysis's PRs.
Comment 3 dfilter service freebsd_committer freebsd_triage 2012-09-14 07:21:25 UTC
Author: jgh
Date: Fri Sep 14 06:21:14 2012
New Revision: 304257
URL: http://svn.freebsd.org/changeset/ports/304257

Log:
  - add startup script
  - adopt optionsNG for DOCS
  - while here adjust run depends listing
  
  PR:		170738
  Submitted by:	maintainer, nemysis@gmx.ch

Added:
  head/games/mopesnake/files/
  head/games/mopesnake/files/mopesnake.in   (contents, props changed)
Modified:
  head/games/mopesnake/Makefile

Modified: head/games/mopesnake/Makefile
==============================================================================
--- head/games/mopesnake/Makefile	Fri Sep 14 05:47:44 2012	(r304256)
+++ head/games/mopesnake/Makefile	Fri Sep 14 06:21:14 2012	(r304257)
@@ -1,44 +1,42 @@
-# New Ports collection makefile for:	mopesnake
-# Date created:        2012-05-16
-# Whom:                nemysis@gmx.ch
-#
 # $FreeBSD$
-#
 
 PORTNAME=	mopesnake
 PORTVERSION=	0.5
+PORTREVISION=	1
 CATEGORIES=	games
 MASTER_SITES=	SF/${PORTNAME}/${PORTNAME}/${PORTVERSION}
 DISTNAME=	${PORTNAME}-pc-${DISTVERSION}
 
 MAINTAINER=	nemysis@gmx.ch
-COMMENT=	A classic snake game in which you attempt to eat all the pain
+COMMENT=	Classic snake game in which you attempt to eat all the pain
 
 LICENSE=	GPLv2
 
-RUN_DEPENDS=	${PYTHON_SITELIBDIR}/pygame/__init__.py:${PORTSDIR}/devel/py-game
+RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}game>=0:${PORTSDIR}/devel/py-game
 
 USE_ZIP=	yes
 USE_PYTHON=	yes
 NO_BUILD=	yes
 
-PLIST_FILES=	bin/mopesnake \
+PLIST_FILES=	bin/${PORTNAME} \
 		share/pixmaps/${PORTNAME}.png
 
 PORTDATA=	*
 PORTDOCS=	TODO.txt index.html
 
+SUB_FILES=	${PORTNAME}
+
 post-patch:
 # Fix path to python interpreter
 	@${REINPLACE_CMD} -e 's,/usr/bin/python,${PYTHON_CMD},' \
 		${WRKSRC}/*.py ${WRKSRC}/mopelib/*.py
 	@(cd ${WRKSRC} && ${RM} *.py.bak mopelib/*py.bak)
 
+.include <bsd.port.options.mk>
+
 do-install:
 # Scripts
-	@${PRINTF} "#!/bin/sh\n\ncd ${DATADIR} &&\
-		./${PORTNAME}.py\n" > ${WRKDIR}/${PORTNAME}.sh
-	${INSTALL_SCRIPT} ${WRKDIR}/${PORTNAME}.sh ${PREFIX}/bin/${PORTNAME}
+	${INSTALL_SCRIPT} ${WRKDIR}/${PORTNAME} ${PREFIX}/bin
 
 # Executable
 	${MKDIR} ${DATADIR}
@@ -52,7 +50,7 @@ do-install:
 	${INSTALL_DATA} ${WRKSRC}/version ${DATADIR}
 
 # Documentation
-.if !defined(NOPORTDOCS)
+.if ${PORT_OPTIONS:MDOCS}
 	${MKDIR} ${DOCSDIR}
 .  for f in ${PORTDOCS}
 	${INSTALL_DATA} ${WRKSRC}/doc/${f} ${DOCSDIR}

Added: head/games/mopesnake/files/mopesnake.in
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/games/mopesnake/files/mopesnake.in	Fri Sep 14 06:21:14 2012	(r304257)
@@ -0,0 +1,7 @@
+#!/bin/sh
+#
+# $FreeBSD$
+
+echo "Master Of Pain (Eating) - Snake: Starting up..."
+cd "%%DATADIR%%"
+./mopesnake.py
\ No newline at end of file
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
Comment 4 Jason Helfman freebsd_committer freebsd_triage 2012-09-14 07:21:40 UTC
State Changed
From-To: open->closed

Committed, with minor changes. Thanks!