Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 19 Mar 2004 03:41:13 -0800 (PST)
From:      michael johnson <ahze@ahze.net>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   ports/64454: [New Port] games/dotgnu-nim -  traditional "Nim" game in C#
Message-ID:  <200403191141.i2JBfD8q004410@www.freebsd.org>
Resent-Message-ID: <200403191150.i2JBoL9N099402@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         64454
>Category:       ports
>Synopsis:       [New Port] games/dotgnu-nim -  traditional "Nim" game in C#
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          maintainer-update
>Submitter-Id:   current-users
>Arrival-Date:   Fri Mar 19 03:50:20 PST 2004
>Closed-Date:
>Last-Modified:
>Originator:     michael johnson
>Release:        
>Organization:
>Environment:
>Description:
- New port games/dotgnu-nim
   C# implementation of the traditional "Nim" game
- Update lang/pnet to install a script dotgnu-nim and other C# programs.
>How-To-Repeat:
      
>Fix:
-- begin dotgnu-nim

# This is a shell archive.  Save it in a file, remove anything before
# this line, and then unpack it by entering "sh file".  Note, it may
# create directories; files and directories will be owned by you and
# have default permissions.
#
# This archive contains:
#
#	games/dotgnu-nim/
#	games/dotgnu-nim/pkg-descr
#	games/dotgnu-nim/Makefile
#	games/dotgnu-nim/distinfo
#
echo c - games/dotgnu-nim/
mkdir -p games/dotgnu-nim/ > /dev/null 2>&1
echo x - games/dotgnu-nim/pkg-descr
sed 's/^X//' >games/dotgnu-nim/pkg-descr << 'END-of-games/dotgnu-nim/pkg-descr'
XMohan Embar wrote an implementation of the traditional "Nim" game to 
Xdemonstrate how to write a Model-View-Controller application using DotGNU 
XPortable.NET's System.Windows.Forms implementation.
X
XWWW:	http://www.dotgnu.org
END-of-games/dotgnu-nim/pkg-descr
echo x - games/dotgnu-nim/Makefile
sed 's/^X//' >games/dotgnu-nim/Makefile << 'END-of-games/dotgnu-nim/Makefile'
X# New ports collection makefile for:	dotgnu-nim
X# Date created:		2004-03-19
X# Whom:			Michael Johnson <ahze@ahze.net>
X#
X# $FreeBSD$
X#
X
XPORTNAME=	dotgnu-nim
XPORTVERSION=	20040305
XCATEGORIES=	games
XMASTER_SITES=	http://dotgnu.org/
X
XMAINTAINER=	ahze@ahze.net
XCOMMENT=	C\# implementation of the traditional Nim game
X
XBUILD_DEPENDS=	cscc:${PORTSDIR}/lang/pnet-base \
X		csunit:${PORTSDIR}/lang/pnetlib
XRUN_DEPENDS=	cscc:${PORTSDIR}/lang/pnet-base \
X		csunit:${PORTSDIR}/lang/pnetlib
X
XUSE_REINPLACE=	yes
XUSE_XLIB=	yes
XWRKSRC=		${WRKDIR}/${PORTNAME}
XPORTDOCS=	README \
X		screenshot.jpg
XPNET_STRAP_BIN=	nim
XPLIST_FILES=	bin/nim \
X		bin/nim.exe
XSTRIP=		# Nothing To Strip
X
X.include "../../lang/pnet/Makefile.pnet"
X.include <bsd.port.pre.mk>
X
Xpost-extract: ilrun-cp-strap
X
Xpost-patch: ilrun-do-strap
X	@${REINPLACE_CMD} -e 's|cscc|cscc ${CSFLAGS}|' \
X		${WRKSRC}/Makefile
X
Xdo-install:
X	@${INSTALL_SCRIPT} ${WRKSRC}/${PNET_STRAP_BIN} ${PREFIX}/bin/nim
X	@${INSTALL_PROGRAM} ${ILSTRIP_CMD} ${WRKSRC}/nim.exe ${PREFIX}/bin
X.if !defined(NOPORTDOCS)
X	@${MKDIR} ${DOCSDIR}
X.for docfile in ${PORTDOCS}
X	@${INSTALL_DATA} ${WRKSRC}/${docfile} ${DOCSDIR}
X.endfor
X.endif
X
X.include <bsd.port.post.mk>
END-of-games/dotgnu-nim/Makefile
echo x - games/dotgnu-nim/distinfo
sed 's/^X//' >games/dotgnu-nim/distinfo << 'END-of-games/dotgnu-nim/distinfo'
XMD5 (dotgnu-nim-20040305.tar.gz) = 3a3fbe827fe628918353b61b39cd14fe
XSIZE (dotgnu-nim-20040305.tar.gz) = 61179
END-of-games/dotgnu-nim/distinfo
exit

--end dotgnu-nim

--begin pnet

diff -ruN lang/pnet.orig/Makefile.pnet lang/pnet/Makefile.pnet
--- lang/pnet.orig/Makefile.pnet	Fri Mar 19 04:26:01 2004
+++ lang/pnet/Makefile.pnet	Fri Mar 19 06:23:54 2004
@@ -8,12 +8,41 @@
 			http://www.southern-storm.com.au/download/
 PNET_MASTER_SITE_SUBDIR=	dotgnu/pnet/
 
+.if defined(PNET_STRAP_BIN) || defined(PNET_STRAP_SBIN)
+USE_REINPLACE=	yes
+.endif
+
+ILSTRIP_CMD?=	${LOCALBASE}/bin/ilstrip
+ILRUN_CMD?=	${LOCALBASE}/bin/ilrun
 
-ILSTRIP_CMD=	${LOCALBASE}/bin/ilstrip
+PNET_STRAP_SCRIPT=	${PORTSDIR}/lang/pnet/files/pnetstrap
+PNET_STRAP_SUFX?=	.exe
 
 .if defined(WITH_OPTIMIZED_CSFLAGS)
 CSFLAGS=-O2
 .endif
+
+ilrun-cp-strap:
+.for strap in ${PNET_STRAP_BIN}
+	@${CP} ${PNET_STRAP_SCRIPT} ${WRKSRC}/${strap}
+.endfor
+.for strap in ${PNET_STRAP_SBIN}
+	@${CP} ${PNET_STRAP_SCRIPT} ${WRKSRC}/${strap}
+.endfor
+
+ilrun-do-strap:
+.for strap in ${PNET_STRAP_BIN}
+	@${REINPLACE_CMD} -e 's|SH|${SH}|; \
+		s|ILRUN|${ILRUN_CMD} ${ILRUN_FLAGS}|; \
+		s|PNET_STRAP_BIN|${PREFIX}/bin/${strap}${PNET_STRAP_SUFX}|' \
+		${WRKSRC}/${strap}
+.endfor
+.for strap in ${PNET_STRAP_SBIN}
+	@${REINPLACE_CMD} -e 's|SH|${SH}|; \
+		s|ILRUN|${ILRUN_CMD} ${ILRUN_FLAGS}|; \
+		s|PNET_STRAP_BIN|${PREFIX}/sbin/${strap}${PNET_STRAP_SUFX}|' \
+		${WRKSRC}/${strap}
+.endfor
 
 pre-everything:: post-everything
 .if !defined(WITH_OPTIMIZED_CSFLAGS)
diff -ruN lang/pnet.orig/files/pnetstrap lang/pnet/files/pnetstrap
--- lang/pnet.orig/files/pnetstrap	Wed Dec 31 19:00:00 1969
+++ lang/pnet/files/pnetstrap	Fri Mar 19 05:14:45 2004
@@ -0,0 +1,2 @@
+#!SH
+ILRUN PNET_STRAP_BIN


--end pnet
>Release-Note:
>Audit-Trail:
>Unformatted:



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