From nobody Thu Jan 11 08:06:51 2024 X-Original-To: dev-commits-ports-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4T9chC3r5nz56q72; Thu, 11 Jan 2024 08:06:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4T9chC1vswz4T7x; Thu, 11 Jan 2024 08:06:51 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1704960411; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VhlG9m3d+yS2I1f+g+SRzlMqS5ZHZ4bCEZ4v01YnxGw=; b=KwPK9BDQtxWIlm2wmTA98XmVliHcE7OZ1GqgHNVpJ8H+gvsRsAjD4avLiS0Bo2Ncxx2WwS BWZtPyaR4ssZwFDCwYR9yHKLi1899982ILyLvIYxNGcX/oaOfPu/bC9oF84pCxTs75nsTD 8/xMIO9IjXrByahzWBmxtqRtSa9XW33bVXnrhgGQw0Oud+cLQIokY+x+cdFzP0F6r/6ZrN fWf9mFomf8a03v4X65AdG7tZM9qSzDYrgni/EM55wBxOWWoeXeAqlvmGd1l0fPD5XmfjXo aUTZkS056OmOGyQsb7f1lT8foWTDtRRS6VOvNahNkwTF2nxpbUq9KjmpUVnJcg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1704960411; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=VhlG9m3d+yS2I1f+g+SRzlMqS5ZHZ4bCEZ4v01YnxGw=; b=qtQBFAGHAmdzz+qmIicQIU5JZAhjjrx2zB8OIsam2MYfZz0se1pZQZOsEejXLWydPaX2un m5AqeghyakrZgBJM3lCqwyQjcjElyTx0bptx+0N6yjp/Pq5J4RwiS79L9ANoFYhY9RqxOx M8lGc2LJJumkK/ngbkb4FYR3ra460M6dES1ehmco//Qcs/u72ZUj2iwxtNH5igbkDLRQ2i mDWRYbvzHzOQLKD92JL7vmka0wiy1t4Ci6ZNY93K8p/7bwZuAJ8XfzLQK3wJ3ST0tg1r/X ig4J+wy4esOniIoGd2V/YWEWJf12vAXZLhgvzlvExgyZaVPZjhrbey7aVrEaPg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1704960411; a=rsa-sha256; cv=none; b=Dpzv1dxezlbNvTxHubzMj+OZs/4cYO6r8BsM3yCQd8wy+tb1LRjq7HhsB/ilQe7A8QDyAd ksihHKParuOMMLyRRUZKBuBaFGGBDjSWhQbZXSCkm9ayolfnM5RAnYbzEH4ileFRSLUVkZ THEzRwMzcoL/9X/45/QrnqLDZuC4JEbdK7a1ZjNQiHsjYyHf++F9AhBDczJXYB530fNe9m laOKMBUqDzcv5rUv11FerdWEfe3IIBlJIy1Hy1qAlrnCnZRDyG7RaD43H1PA9J703xWbMm mSnW84tKP81TOQtvC8EgDxfpnEyISUTKxuCucNE4ZpejSLv5ad+X/ZcLsKhUkg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4T9chC0qYpz19rk; Thu, 11 Jan 2024 08:06:51 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 40B86p6D061956; Thu, 11 Jan 2024 08:06:51 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 40B86pZ6061953; Thu, 11 Jan 2024 08:06:51 GMT (envelope-from git) Date: Thu, 11 Jan 2024 08:06:51 GMT Message-Id: <202401110806.40B86pZ6061953@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Gleb Popov Subject: git: 263bffb30676 - main - Mk/bsd.port.mk: Introduce generic WITH__PORTS knob. List-Id: Commits to the main branch of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-main@freebsd.org X-BeenThere: dev-commits-ports-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: arrowd X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 263bffb306762bd6ff208111fda30cfbff3d6486 Auto-Submitted: auto-generated The branch main has been updated by arrowd: URL: https://cgit.FreeBSD.org/ports/commit/?id=263bffb306762bd6ff208111fda30cfbff3d6486 commit 263bffb306762bd6ff208111fda30cfbff3d6486 Author: Gleb Popov AuthorDate: 2024-01-08 18:40:03 +0000 Commit: Gleb Popov CommitDate: 2024-01-11 08:06:28 +0000 Mk/bsd.port.mk: Introduce generic WITH__PORTS knob. This allows enabling any feature supported by Ports Framework for a selected ports. It was only possible to do WITH_DEBUG_PORTS before. Differential Revision: https://reviews.freebsd.org/D43369 Approved by: bapt --- Mk/bsd.port.mk | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/Mk/bsd.port.mk b/Mk/bsd.port.mk index 097f64d4b6ae..54390720912e 100644 --- a/Mk/bsd.port.mk +++ b/Mk/bsd.port.mk @@ -1325,11 +1325,21 @@ LDCONFIG32_DIR= libdata/ldconfig32 TMPDIR?= /tmp . endif # defined(PACKAGE_BUILDING) -. if defined(WITH_DEBUG_PORTS) -. if ${WITH_DEBUG_PORTS:M${PKGORIGIN}} -WITH_DEBUG= yes +# For each Feature we support, process the +# WITH_FEATURE_PORTS and WITHOUT_FEATURE_PORTS variables +. for feature in ${_LIST_OF_WITH_FEATURES} +. if ${_DEFAULT_WITH_FEATURES:M${feature}} +_WITH_OR_WITHOUT= WITHOUT +. else +_WITH_OR_WITHOUT= WITH . endif -. endif + +. if defined(${_WITH_OR_WITHOUT}_${feature:tu}_PORTS) +. if ${${_WITH_OR_WITHOUT}_${feature:tu}_PORTS:M${PKGORIGIN}} +${_WITH_OR_WITHOUT}_${feature:tu}= yes +. endif +. endif +. endfor . if defined(USE_LTO) WITH_LTO= ${USE_LTO}