diff options
author | glewis <glewis@FreeBSD.org> | 2003-08-30 02:30:08 +0800 |
---|---|---|
committer | glewis <glewis@FreeBSD.org> | 2003-08-30 02:30:08 +0800 |
commit | 14ca26f8f2115c2754861fa5968f5bac1e37b005 (patch) | |
tree | 6184c31e7167143476579ab55de29f6e86154315 /net/dgd/Makefile | |
parent | 3d5008d1dd077270e045200e8e3145f3da3fc662 (diff) | |
download | freebsd-ports-gnome-14ca26f8f2115c2754861fa5968f5bac1e37b005.tar.gz freebsd-ports-gnome-14ca26f8f2115c2754861fa5968f5bac1e37b005.tar.zst freebsd-ports-gnome-14ca26f8f2115c2754861fa5968f5bac1e37b005.zip |
. Make this port act more like a standard FreeBSD port:
. Don't install everything in ${PREFIX}/dgd instead place the
executables, docs and configuration in the standard places and
place the example kernel mudlib in DATADIR.
. Don't use the packing list as a list of things to install.
. Fix up the configuration file to point to the install locations.
. Add a sample rc script which can be used to start and stop dgd
(need a 5.x RCng version as well).
. Create a user to run the dgd service as (I'll reuse this user for
ports of other mud drivers).
. Add the games category as dgd is primarily used to write muds.
. Bump PORTREVISION.
Diffstat (limited to 'net/dgd/Makefile')
-rw-r--r-- | net/dgd/Makefile | 39 |
1 files changed, 36 insertions, 3 deletions
diff --git a/net/dgd/Makefile b/net/dgd/Makefile index 9d0779d9c8c7..1061e84ec745 100644 --- a/net/dgd/Makefile +++ b/net/dgd/Makefile @@ -7,7 +7,8 @@ PORTNAME= dgd PORTVERSION= 1.2p3 -CATEGORIES= net lang +PORTREVISION= 1 +CATEGORIES= net lang games MASTER_SITES= ${MASTER_SITE_LOCAL:S|%SUBDIR%|glewis/dgd|} \ ftp://ftp.dworkin.nl/pub/dgd/ \ ftp://ftp.imaginary.com/pub/LPC/servers/DGD/ @@ -21,9 +22,41 @@ RESTRICTED= "license required for commercial use" DIST_SUBDIR= dgd WRKSRC= ${WRKDIR}/dgd/src ALL_TARGET= install +USE_REINPLACE= yes + +CPIO?= /usr/bin/cpio + +do-configure: + ${REINPLACE_CMD} -e "s:%%DATADIR%%:${DATADIR}:" ${WRKDIR}/dgd/mud.dgd do-install: - @${TAR} -C ${WRKDIR} -cf - `${GREP} '^dgd/' ${PLIST}` \ - | ${TAR} -C ${PREFIX} -xpf - + ${INSTALL_PROGRAM} ${WRKDIR}/dgd/bin/driver ${PREFIX}/sbin/dgd + ${INSTALL_PROGRAM} ${WRKDIR}/dgd/bin/precomp ${PREFIX}/bin/precomp + ${MKDIR} ${PREFIX}/etc/${PORTNAME} + ${INSTALL_DATA} ${WRKDIR}/dgd/mud.dgd \ + ${PREFIX}/etc/${PORTNAME}/kernel.dgd + ${MKDIR} ${DATADIR}/kernel + cd ${WRKDIR}/dgd/mud && ${FIND} . \ + | ${CPIO} -pdmu -R ${SHAREOWN}:${SHAREGRP} ${DATADIR}/kernel + # Install an RC script for DGD + ${CAT} ${FILESDIR}/dgd.sh | ${SED} -e "s:%%PREFIX%%:${PREFIX}:" \ + -e "s:%%DATADIR%%:${DATADIR}:" > \ + ${PREFIX}/etc/rc.d/dgd.sh.sample + ${CHMOD} a+x ${PREFIX}/etc/rc.d/dgd.sh.sample +.if !defined(NOPORTDOCS) + ${MKDIR} ${DOCSDIR} + ${INSTALL_DATA} ${WRKDIR}/dgd/Copyright ${DOCSDIR} + ${INSTALL_DATA} ${WRKDIR}/dgd/Credits ${DOCSDIR} + ${INSTALL_DATA} ${WRKDIR}/dgd/README ${DOCSDIR} + cd ${WRKDIR}/dgd/doc && ${FIND} . \ + | ${CPIO} -pdmu -R ${SHAREOWN}:${SHAREGRP} ${DOCSDIR} +.endif + +post-install: + # Need a temporary directory for certain files + ${MKDIR} ${DATADIR}/tmp + # Run package install script + ${SETENV} PKG_PREFIX=${PREFIX} ${SH} ${PKGDIR}/pkg-install ${PKGNAME} \ + POST-INSTALL .include <bsd.port.mk> |