Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 10 Sep 2018 13:16:24 +0000 (UTC)
From:      Mathieu Arnold <mat@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r479409 - head/Mk
Message-ID:  <201809101316.w8ADGOaG073371@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: mat
Date: Mon Sep 10 13:16:24 2018
New Revision: 479409
URL: https://svnweb.freebsd.org/changeset/ports/479409

Log:
  Add a DEV_ERROR if PORTDOCS/PORTEXAMPLES are set and DOCS/EXAMPLES
  options are not defined.
  
  PR:		230864
  Submitted by:	mat
  exp-runs by:	antoine
  Differential Revision:	https://reviews.freebsd.org/D13651

Modified:
  head/Mk/bsd.port.mk   (contents, props changed)
  head/Mk/bsd.sanity.mk   (contents, props changed)

Modified: head/Mk/bsd.port.mk
==============================================================================
--- head/Mk/bsd.port.mk	Mon Sep 10 13:16:16 2018	(r479408)
+++ head/Mk/bsd.port.mk	Mon Sep 10 13:16:24 2018	(r479409)
@@ -4538,6 +4538,7 @@ ${TMPPLIST}:
 	@cd ${.CURDIR} && ${MAKE} generate-plist
 
 .for _type in EXAMPLES DOCS
+.if !empty(_REALLY_ALL_POSSIBLE_OPTIONS:M${_type})
 .if !target(add-plist-${_type:tl})
 .if defined(PORT${_type}) && !empty(PORT_OPTIONS:M${_type})
 add-plist-${_type:tl}:
@@ -4549,6 +4550,7 @@ add-plist-${_type:tl}:
 .endfor
 	@${FIND} -P ${PORT${_type}:S/^/${STAGEDIR}${${_type}DIR}\//} ! -type d 2>/dev/null | \
 		${SED} -ne 's,^${STAGEDIR},,p' >> ${TMPPLIST}
+.endif
 .endif
 .endif
 .endfor

Modified: head/Mk/bsd.sanity.mk
==============================================================================
--- head/Mk/bsd.sanity.mk	Mon Sep 10 13:16:16 2018	(r479408)
+++ head/Mk/bsd.sanity.mk	Mon Sep 10 13:16:24 2018	(r479409)
@@ -162,6 +162,12 @@ DEV_ERROR+=	"USE_TCL and USE_TK are no longer supporte
 DEV_ERROR+=	"USE_FPC=yes is no longer supported, please use USES=fpc"
 .endif
 
+.for _type in EXAMPLES DOCS
+.  if defined(PORT${_type}) && empty(_REALLY_ALL_POSSIBLE_OPTIONS:M${_type})
+DEV_ERROR+=	"PORT${_type} does not do anything unless the ${_type} option is present."
+.  endif
+.endfor
+
 SANITY_UNSUPPORTED=	USE_OPENAL USE_FAM USE_MAKESELF USE_ZIP USE_LHA USE_CMAKE \
 		USE_READLINE USE_ICONV PERL_CONFIGURE PERL_MODBUILD \
 		USE_PERL5_BUILD USE_PERL5_RUN USE_DISPLAY USE_FUSE \



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