From nobody Mon May 20 21:53:57 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 4VjrtZ1C5Nz5LYHX; Mon, 20 May 2024 21:53:58 +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 4VjrtZ0Sv4z4ZcC; Mon, 20 May 2024 21:53:58 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1716242038; 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=LgZBXmdBzLmgAVQ2Ss+jlmo/Mxy44ASwf2OA/jafSyM=; b=Btr4QHVBYRPChpIm13tpZC12mSmXILhrkebGiDdiQ+TAlkvuVZbFu7se7KwdoZOCRoWs0u 6UIIqm+jPcuhdPRRD8pvl7wQsRX3Lzj26X4NtnRY0YsaZZSC9BXUHzbii9nIXUvCID6hc2 kWN+tVp8OLO5mSJ8MzeB7s9qq5X0G6kQ4pYzhqfeXu/KUcll4tMwB6Puft8JzVkKmwtSmk ZyzEmpS50RjrmXqP71P9vge98tV+WLOSjkxYfP9w2+et0dS46FikuKx19hlhBszkxB3z6g a1l3ERDMQ20uFXN7+AFMApPwA/ffl99y5dEFA+i1PoZKNUg5iV6BMkw4I4tjtQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1716242038; a=rsa-sha256; cv=none; b=cBU8yh0Tum1g4ditCRNyxrGdlb+7zDQx/Gvx/gFgb5APJ6aF6m5le0I1Rym4Lc6rZj71aJ bH9iXttpmdR+pXANtOoD7DbF2RuKgCq/RreVebaW3jxHGbAn61vCqpSejpuDgf+1z1vccM 6Lewl8+lE0K3GzRk7ePCuF8ZB82PzrxEFU9KFDV2ebjyd+a5mx/bn2OclL7WVS7aHvTnBL lN4+iQWFAVm9Hbc4tf2LoVE8j/+NNOwCawHIe+7NniZ2kdD7RdYn0aCXO6h85WugnjeBfR 4yvRSBHUpfgwFky+ULjpu9lmyycQqfWMhdNEOBQ9aTPJEWLz9hSBQUiw02dkxg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1716242038; 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=LgZBXmdBzLmgAVQ2Ss+jlmo/Mxy44ASwf2OA/jafSyM=; b=XUhHJMEKf1SKyrV53ReXcJArnF88MGXGAxYIsFx/OE0DqnufMmczSDZp2yzmeBvaKP517f KsQcBFXGRT1vfF6DR2BYcDjkKFPLMSBAbwC8pXQhirqALo6WnUy72RhEY6MlcEUmeRk37e xm60d7l8FMxQ+yGq8ByHbv1OqCfv4pmkj+SdjHHI5O0vl2W5h7hWTH+X6hjcfyuPIFyenZ 5VRhn73iAMyEGsD2IM7VFJnGjhYE0WDu+Cu2cvJzZX2fBgN4JxEcCUU/9OC+ErPrvR7tCf HhX5yG9snih6IJknlEjknCKPKG7RF+oKayXUVi6j+2OV65//dOkc2HQg7eOBwQ== 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 4VjrtZ04P7zw9C; Mon, 20 May 2024 21:53:58 +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 44KLrv4N091813; Mon, 20 May 2024 21:53:57 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 44KLrvl5091810; Mon, 20 May 2024 21:53:57 GMT (envelope-from git) Date: Mon, 20 May 2024 21:53:57 GMT Message-Id: <202405202153.44KLrvl5091810@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Daniel Engberg Subject: git: 9843444ea96e - main - Mk/Uses/ninja.mk: Add samurai as option for ARGS 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: X-BeenThere: dev-commits-ports-main@freebsd.org Sender: owner-dev-commits-ports-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: diizzy X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 9843444ea96e25eb7c782a3bf24eb67d4b934cd1 Auto-Submitted: auto-generated The branch main has been updated by diizzy: URL: https://cgit.FreeBSD.org/ports/commit/?id=9843444ea96e25eb7c782a3bf24eb67d4b934cd1 commit 9843444ea96e25eb7c782a3bf24eb67d4b934cd1 Author: Daniel Engberg AuthorDate: 2024-05-20 21:11:12 +0000 Commit: Daniel Engberg CommitDate: 2024-05-20 21:53:50 +0000 Mk/Uses/ninja.mk: Add samurai as option for ARGS This adds the ability for ports to override NINJA_DEFAULT by defining USES= ninja:samurai and use devel/samurai as backend instead of devel/ninja (default). Reviewed by: arrowd, mat and tobik (previous iterations) Differential Revision: https://reviews.freebsd.org/D45165 --- Mk/Uses/ninja.mk | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/Mk/Uses/ninja.mk b/Mk/Uses/ninja.mk index 5c78cf152d07..b9a8548fb16c 100644 --- a/Mk/Uses/ninja.mk +++ b/Mk/Uses/ninja.mk @@ -2,18 +2,19 @@ # # Feature: ninja # Usage: USES=ninja -# Valid ARGS: build, make (default), run +# Valid ARGS: build, make (default), run, samurai # # build add a build dependency on ninja # make use ninja for the build instead of make, implies "build" # run add a run dependency on ninja +# samurai use samurai irregardless of NINJA_DEFAULT (implies make) # # MAINTAINER: ports@FreeBSD.org .if !defined(_INCLUDE_USES_NINJA_MK) _INCLUDE_USES_NINJA_MK= yes -_valid_ARGS= build make run +_valid_ARGS= build make run samurai . for _arg in ${ninja_ARGS} . if empty(_valid_ARGS:M${_arg}) @@ -23,16 +24,19 @@ IGNORE= 'USES+= ninja:${ninja_ARGS}' usage: argument [${_arg}] is not recognized . if empty(ninja_ARGS) ninja_ARGS+= make +. elif !empty(ninja_ARGS:Msamurai) +_SAMURAI_FROM_ARGS= yes +ninja_ARGS+= make . endif . if ${ninja_ARGS:Mmake} ninja_ARGS+= build . endif -. if ${NINJA_DEFAULT} == ninja +. if ${NINJA_DEFAULT} == ninja && !defined(_SAMURAI_FROM_ARGS) NINJA_CMD= ninja _NINJA_PORT= devel/ninja -. elif ${NINJA_DEFAULT} == samurai +. elif ${NINJA_DEFAULT} == samurai || defined(_SAMURAI_FROM_ARGS) NINJA_CMD= samu _NINJA_PORT= devel/samurai MAKE_ENV+= SAMUFLAGS="-v -j${MAKE_JOBS_NUMBER}" @@ -56,7 +60,7 @@ MAKE_ENV+= NINJA_STATUS="[%p %s/%t] " . endif . if ${ninja_ARGS:Mmake} -. if ${NINJA_DEFAULT} == ninja +. if ${NINJA_DEFAULT} == ninja && !defined(_SAMURAI_FROM_ARGS) # samu does not support GNU-style args, so we cannot just append # -v last. samu gets this via SAMUFLAGS above but ninja does not # support an equivalent environment variable.