Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 20 Nov 2013 13:29:42 +0000 (UTC)
From:      Ganael LAPLANCHE <martymac@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r334416 - head/games/flightgear-mb339-pan
Message-ID:  <201311201329.rAKDTgcn008292@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: martymac
Date: Wed Nov 20 13:29:41 2013
New Revision: 334416
URL: http://svnweb.freebsd.org/changeset/ports/334416

Log:
  - Enable staging
  - Cleanup WRKSRC handling

Modified:
  head/games/flightgear-mb339-pan/Makefile

Modified: head/games/flightgear-mb339-pan/Makefile
==============================================================================
--- head/games/flightgear-mb339-pan/Makefile	Wed Nov 20 13:26:34 2013	(r334415)
+++ head/games/flightgear-mb339-pan/Makefile	Wed Nov 20 13:29:41 2013	(r334416)
@@ -13,24 +13,32 @@ COMMENT=	A simulation of the MB-339 PAN 
 
 RUN_DEPENDS=	${LOCALBASE}/share/flightgear/version:${PORTSDIR}/games/flightgear-data
 
-USE_ZIP=	yes
-NO_WRKSUBDIR=	yes
-NO_BUILD=	yes
 RESTRICTED=	Redistribution prohibited
-PLIST=		${WRKDIR}/.pkg-plist
 
-NO_STAGE=	yes
+NO_BUILD=	yes
+USE_ZIP=	yes
+WRKSRC=	${WRKDIR}/${PORTNAME}
+EXTRACT_AFTER_ARGS=	-d ${WRKSRC}
+DATADIR=	${PREFIX}/share/flightgear/Aircraft
+
+PLIST=		${WRKDIR}/pkg-plist
+PLIST_DIRS=	%%DATADIR%%
+
+pre-extract:
+	@${MKDIR} ${WRKSRC}
+
 pre-install:
 	@${RM} -f ${PLIST}
 	@cd ${WRKSRC} && \
 	${FIND} * -type d -empty | ${SORT} \
-		| ${SED} -e 's|^|@exec ${MKDIR} share/flightgear/Aircraft/|' >> ${PLIST} && \
+		| ${SED} -e 's|^|@exec ${MKDIR} %D/share/flightgear/Aircraft/|' >> ${PLIST} && \
 	${FIND} * -type f | ${SORT} \
-		| ${SED} -e 's|^|share/flightgear/Aircraft/|' >> ${PLIST} && \
+		| ${SED} -e 's|^|%%DATADIR%%/|' >> ${PLIST} && \
 	${FIND} * -type d | ${SORT} -r \
-		| ${SED} -e 's|^|@dirrm share/flightgear/Aircraft/|' >> ${PLIST}
+		| ${SED} -e 's|^|@dirrm %%DATADIR%%/|' >> ${PLIST}
 
 do-install:
-	(cd ${WRKSRC}/ && ${COPYTREE_SHARE} \* ${PREFIX}/share/flightgear/Aircraft/)
+	${MKDIR} ${STAGEDIR}${DATADIR}
+	(cd ${WRKSRC}/ && ${COPYTREE_SHARE} \* ${STAGEDIR}${DATADIR})
 
 .include <bsd.port.mk>



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