From c627d25a0b0e6f9cc2d3b31b3173875083a41841 Mon Sep 17 00:00:00 2001 From: rillig Date: Wed, 7 Mar 2007 21:44:52 +0000 Subject: Replaced sed(1) and mv(1) with the SUBST framework. --- cad/spice/Makefile | 23 +++++++++-------------- 1 file changed, 9 insertions(+), 14 deletions(-) (limited to 'cad') diff --git a/cad/spice/Makefile b/cad/spice/Makefile index e3f10b0fa50..a2e966b5f05 100644 --- a/cad/spice/Makefile +++ b/cad/spice/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.38 2007/03/07 14:59:06 joerg Exp $ +# $NetBSD: Makefile,v 1.39 2007/03/07 21:44:52 rillig Exp $ DISTNAME= sp3f4.kit PKGNAME= spice-3f5.1 @@ -31,24 +31,19 @@ MAKE_ENV+= WRKSRC=${WRKSRC:Q} post-extract: ${CP} ${FILESDIR}/NetBSD ${WRKSRC}/conf +SUBST_CLASSES+= conf +SUBST_STAGE.conf= pre-configure +SUBST_FILES.conf= conf/NetBSD conf/defaults +SUBST_VARS.conf= MAKE_PROGRAM CFLAGS LDFLAGS WRKSRC PREFIX + do-configure: - ${RM} -f ${WRKSRC}/makefile - cd ${WRKSRC}/conf; for file in NetBSD defaults; do \ - ${SED} -e "s|@MAKE_PROGRAM@|${MAKE_PROGRAM}|g" \ - -e "s|@CFLAGS@|${CFLAGS}|g" \ - -e "s|@LDFLAGS@|${LDFLAGS}|g" \ - -e 's|@X11BASE@|${X11BASE}|g' \ - -e "s|@WRKSRC@|${WRKSRC}|g" \ - -e 's|@PREFIX@|${PREFIX}|g' \ - $${file} > $${file}.new; \ - ${MV} -f $${file}.new $${file}; \ - done + rm -f ${WRKSRC}/makefile do-build: - cd ${WRKSRC}; ${SETENV} ${MAKE_ENV} util/build NetBSD default + cd ${WRKSRC} && env ${MAKE_ENV} util/build NetBSD default do-install: - cd ${WRKSRC}; util/build NetBSD install + cd ${WRKSRC} && env ${MAKE_ENV} util/build NetBSD install ${CHMOD} a+rx ${PREFIX}/bin/spice3 ${PREFIX}/bin/nutmeg \ ${PREFIX}/bin/sconvert ${PREFIX}/bin/help \ ${PREFIX}/bin/proc2mod ${PREFIX}/bin/multidec -- cgit v1.2.3