From owner-svn-ports-all@FreeBSD.ORG Mon Jun 22 21:34:54 2015 Return-Path: Delivered-To: svn-ports-all@nevdull.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 7938DD64; Mon, 22 Jun 2015 21:34:54 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4D5D4389; Mon, 22 Jun 2015 21:34:54 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.9/8.14.9) with ESMTP id t5MLYso6020446; Mon, 22 Jun 2015 21:34:54 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by svn.freebsd.org (8.14.9/8.14.9/Submit) id t5MLYsle020445; Mon, 22 Jun 2015 21:34:54 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201506222134.t5MLYsle020445@svn.freebsd.org> X-Authentication-Warning: svn.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Mon, 22 Jun 2015 21:34:54 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r390332 - head/Mk X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 22 Jun 2015 21:34:54 -0000 Author: bapt Date: Mon Jun 22 21:34:53 2015 New Revision: 390332 URL: https://svnweb.freebsd.org/changeset/ports/390332 Log: factorize add-plist-docs and add-plist-examples Modified: head/Mk/bsd.port.mk Modified: head/Mk/bsd.port.mk ============================================================================== --- head/Mk/bsd.port.mk Mon Jun 22 21:19:05 2015 (r390331) +++ head/Mk/bsd.port.mk Mon Jun 22 21:34:53 2015 (r390332) @@ -5089,33 +5089,21 @@ ${TMPPLIST}: ${TMPPLIST_SORT}: ${TMPPLIST} @${SORT} -u ${TMPPLIST} >${TMPPLIST_SORT} -.if !target(add-plist-docs) -.if defined(PORTDOCS) && !defined(NOPORTDOCS) -add-plist-docs: -.for x in ${PORTDOCS} +.for _type in EXAMPLES DOCS +.if !target(add-plist-${_type:tl}) +.if defined(PORT${_type}) && !defined(NOPORT${_type}) +add-plist-${_type:tl}: +.for x in ${PORT${_type}} @if ${ECHO_CMD} "${x}"| ${AWK} '$$1 ~ /(\*|\||\[|\]|\?|\{|\}|\$$)/ { exit 1};'; then \ - if [ ! -e ${STAGEDIR}${DOCSDIR}/${x} ]; then \ - ${ECHO_CMD} ${DOCSDIR}/${x} >> ${TMPPLIST}; \ + if [ ! -e ${STAGEDIR}${${_type}DIR}/${x} ]; then \ + ${ECHO_CMD} ${${_type}DIR}/${x} >> ${TMPPLIST}; \ fi;fi .endfor - @${FIND} -P ${PORTDOCS:S/^/${STAGEDIR}${DOCSDIR}\//} ! -type d 2>/dev/null | \ + @${FIND} -P ${PORT${_type}:S/^/${STAGEDIR}${${_type}DIR}\//} ! -type d 2>/dev/null | \ ${SED} -ne 's,^${STAGEDIR},,p' >> ${TMPPLIST} .endif .endif - -.if !target(add-plist-examples) -.if defined(PORTEXAMPLES) && !defined(NOPORTEXAMPLES) -add-plist-examples: -.for x in ${PORTEXAMPLES} - @if ${ECHO_CMD} "${x}"| ${AWK} '$$1 ~ /(\*|\||\[|\]|\?|\{|\}|\$$)/ { exit 1};'; then \ - if [ ! -e ${STAGEDIR}${EXAMPLESDIR}/${x} ]; then \ - ${ECHO_CMD} ${EXAMPLESDIR}/${x} >> ${TMPPLIST}; \ - fi;fi .endfor - @${FIND} -P ${PORTEXAMPLES:S/^/${STAGEDIR}${EXAMPLESDIR}\//} ! -type d 2>/dev/null | \ - ${SED} -ne 's,^${STAGEDIR},,p' >> ${TMPPLIST} -.endif -.endif .if !target(add-plist-data) .if defined(PORTDATA)