Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 20 Nov 2013 12:43:30 +0000 (UTC)
From:      Baptiste Daroussin <bapt@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r334411 - head/Mk/Uses
Message-ID:  <201311201243.rAKChUaf093568@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bapt
Date: Wed Nov 20 12:43:29 2013
New Revision: 334411
URL: http://svnweb.freebsd.org/changeset/ports/334411

Log:
  Define the target in post section.
  Remove the PHONY kmod-pre-install target and replace it with a real file target (well directory in this case)
  
  Approved by:	rene

Modified:
  head/Mk/Uses/kmod.mk

Modified: head/Mk/Uses/kmod.mk
==============================================================================
--- head/Mk/Uses/kmod.mk	Wed Nov 20 12:41:39 2013	(r334410)
+++ head/Mk/Uses/kmod.mk	Wed Nov 20 12:43:29 2013	(r334411)
@@ -11,6 +11,8 @@
 .if !defined(_INCLUDE_USES_KMOD_MK)
 _INCLUDE_USES_KMOD_MK=	yes
 
+_USES_POST=	kmod
+
 .if defined(kmod_ARGS)
 IGNORE=	USES=kmod takes no arguments
 .endif
@@ -33,15 +35,16 @@ MAKE_ENV+=	KMODDIR="${KMODDIR}" SYSDIR="
 MAKE_ENV+=	NO_XREF=yes
 .endif
 
-.PHONY: kmod-preinstall kmod-post-install
-pre-install: kmod-pre-install
-kmod-pre-install:
-.if defined(NO_STAGE)
-	${MKDIR} ${KMODDIR}
-.else
-	${MKDIR} ${STAGEDIR}${KMODDIR}
 .endif
 
+.if defined(_POSTMKINCLUDED) && !defined(_INCLUDE_USES_KMOD_POST_MK)
+_INCLUDE_USES_KMOD_POST_MK=	yes
+
+.PHONY: kmod-post-install
+pre-install: ${STAGEDIR}${KMODDIR}
+${STAGEDIR}${KMODDIR}:
+	${MKDIR} ${.TARGET}
+
 post-install: kmod-post-install
 kmod-post-install:
 	${ECHO_CMD} "@exec /usr/sbin/kldxref ${KMODDIR}"  >> ${TMPPLIST}



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