From owner-svn-ports-head@FreeBSD.ORG Mon Jan 27 22:53:25 2014 Return-Path: Delivered-To: svn-ports-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 253D4BAF; Mon, 27 Jan 2014 22:53:25 +0000 (UTC) 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)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id ED1C219CF; Mon, 27 Jan 2014 22:53:24 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id s0RMrOtR047040; Mon, 27 Jan 2014 22:53:24 GMT (envelope-from mat@svn.freebsd.org) Received: (from mat@localhost) by svn.freebsd.org (8.14.7/8.14.7/Submit) id s0RMrOkQ047038; Mon, 27 Jan 2014 22:53:24 GMT (envelope-from mat@svn.freebsd.org) Message-Id: <201401272253.s0RMrOkQ047038@svn.freebsd.org> From: Mathieu Arnold Date: Mon, 27 Jan 2014 22:53:24 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r341467 - in 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-head@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: SVN commit messages for the ports tree for head List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 27 Jan 2014 22:53:25 -0000 Author: mat Date: Mon Jan 27 22:53:24 2014 New Revision: 341467 URL: http://svnweb.freebsd.org/changeset/ports/341467 QAT: https://qat.redports.org/buildarchive/r341467/ Log: Add two new options helpers: ${OPT}_${TYPE}_DEPENDS_OFF= will automatically add: ${TYPE_DEPENDS}+= in case OPT is 'off' ${OPT}_${FLAG}_OFF= will automatically add: ${FLAG}+= in case OPT is 'off' With hat: portmgr Sponsored by: Absolight Modified: head/CHANGES head/Mk/bsd.options.mk Modified: head/CHANGES ============================================================================== --- head/CHANGES Mon Jan 27 22:46:38 2014 (r341466) +++ head/CHANGES Mon Jan 27 22:53:24 2014 (r341467) @@ -10,6 +10,17 @@ in the release notes and/or placed into All ports committers are allowed to commit to this file. +20140127: +AUTHOR: mat@FreeBSD.org + + Add two new options helpers: + + ${OPT}_${TYPE}_DEPENDS_OFF= will automatically add: + ${TYPE_DEPENDS}+= in case OPT is 'off' + + ${OPT}_${FLAG}_OFF= will automatically add: + ${FLAG}+= in case OPT is 'off' + 20140111: AUTHOR: mva@FreeBSD.org Modified: head/Mk/bsd.options.mk ============================================================================== --- head/Mk/bsd.options.mk Mon Jan 27 22:46:38 2014 (r341466) +++ head/Mk/bsd.options.mk Mon Jan 27 22:53:24 2014 (r341467) @@ -107,10 +107,14 @@ # ALL_TARGET INSTALL_TARGET USES DISTFILES PLIST_FILES PLIST_DIRS PLIST_DIRSTRY # EXTRA_PATCHES PATCHFILES PATCH_SITES CATEGORIES, defining ${opt}_${variable} # will add its content to the actual variable when the option is enabled. +# Defining ${opt}_${variable}_OFF will add its content to the actual variable +# when the option is disabled. # # For each of the depends target PKG EXTRACT PATCH FETCH BUILD LIB RUN, # defining ${opt}_${deptype}_DEPENDS will add its content to the actual -# dependency when the option is enabled. +# dependency when the option is enabled. Defining +# ${opt}_${deptype}_DEPENDS_OFF will add its content to the actual dependency +# when the option is enabled. ## # Set all the options available for the ports, beginning with the @@ -418,6 +422,18 @@ CONFIGURE_ARGS+= --without-${iopt} ${configure}_ARGS+= ${${opt}_${configure}_OFF} . endif . endfor +. for flags in CFLAGS CPPFLAGS CXXFLAGS LDFLAGS CONFIGURE_ENV MAKE_ARGS \ + MAKE_ENV ALL_TARGET INSTALL_TARGET USES DISTFILES PLIST_FILES \ + PLIST_DIRS PLIST_DIRSTRY EXTRA_PATCHES PATCHFILES PATCH_SITES CATEGORIES +. if defined(${opt}_${flags}_OFF) +${flags}+= ${${opt}_${flags}_OFF} +. endif +. endfor +. for deptype in PKG EXTRACT PATCH FETCH BUILD LIB RUN +. if defined(${opt}_${deptype}_DEPENDS_OFF) +${deptype}_DEPENDS+= ${${opt}_${deptype}_DEPENDS_OFF} +. endif +. endfor . endif .endfor