From: Luis Chamberlain <mcgrof@kernel.org>
To: kdevops@lists.linux.dev, chuck.lever@oracle.com,
da.gomez@samsung.com, jlayton@kernel.org
Cc: mcgrof@kernel.org
Subject: [PATCH 3/3] scripts/gen-refs-default.Makefile: support direct make requests
Date: Wed, 4 Sep 2024 16:30:37 -0700 [thread overview]
Message-ID: <20240904233037.1516218-4-mcgrof@kernel.org> (raw)
In-Reply-To: <20240904233037.1516218-1-mcgrof@kernel.org>
Today we can't use:
rm -f workflows/linux/refs/default/Kconfig.linus
make workflows/linux/refs/default/Kconfig.linus
Add support for this and simplify the definitions.
Signed-off-by: Luis Chamberlain <mcgrof@kernel.org>
---
Makefile | 2 +-
scripts/gen-refs-default.Makefile | 28 ++++++++++------------------
2 files changed, 11 insertions(+), 19 deletions(-)
diff --git a/Makefile b/Makefile
index b961e44f4aa6..9d4e954811ab 100644
--- a/Makefile
+++ b/Makefile
@@ -20,6 +20,7 @@ export KDEVOPS_VAGRANT :=
export PYTHONUNBUFFERED=1
export TOPDIR=./
export TOPDIR_PATH = $(shell readlink -f $(TOPDIR))
+include scripts/refs.Makefile
KDEVOPS_NODES_ROLE_TEMPLATE_DIR := $(KDEVOPS_PLAYBOOKS_DIR)/roles/gen_nodes/templates
export KDEVOPS_NODES_TEMPLATE :=
@@ -174,7 +175,6 @@ endif
include scripts/gen-hosts.Makefile
include scripts/gen-nodes.Makefile
-include scripts/refs.Makefile
# disable built-in rules for this
.SUFFIXES:
diff --git a/scripts/gen-refs-default.Makefile b/scripts/gen-refs-default.Makefile
index b04542283211..c5d12e152cb4 100644
--- a/scripts/gen-refs-default.Makefile
+++ b/scripts/gen-refs-default.Makefile
@@ -1,14 +1,12 @@
# SPDX-License-Identifier: copyleft-next-0.3.1
-REFS_TARGET_LNS := gen_default_refs_linus
-REFS_TARGET_LNS += gen_default_refs_next
-REFS_TARGET_LNS += gen_default_refs_stable
+REF_DEF_OBJS := $(addprefix $(TOPDIR)/workflows/linux/refs/default/, Kconfig.linus Kconfig.next Kconfig.stable)
+REF_DEF_SRC := $(addprefix $(TOPDIR)/workflows/linux/refs/static/, linus.yaml next.yaml stable.yaml)
KRELEASES_FORCE := $(if $(filter --force,$(KRELEASES_FORCE)),--force,)
-.PHONY += gen_default_refs_linus
-gen_default_refs_linus:
- $(Q)$(E) "Generating refs/default/Kconfig.$(patsubst gen_default_refs_%,%,$@)..."
+$(TOPDIR)/workflows/linux/refs/default/Kconfig.linus: $(TOPDIR)/workflows/linux/refs/static/linus.yaml
+ $(Q)$(E) "Generating $@..."
$(Q)./scripts/generate_refs.py \
--prefix BOOTLINUX_TREE_LINUS \
--output workflows/linux/refs/default/Kconfig.linus \
@@ -17,9 +15,8 @@ gen_default_refs_linus:
kreleases \
--moniker mainline
-.PHONY += gen_default_refs_next
-gen_default_refs_next:
- $(Q)$(E) "Generating refs/default/Kconfig.$(patsubst gen_default_refs_%,%,$@)..."
+$(TOPDIR)/workflows/linux/refs/default/Kconfig.next: $(TOPDIR)/workflows/linux/refs/static/next.yaml
+ $(Q)$(E) "Generating $@..."
$(Q)./scripts/generate_refs.py \
--prefix BOOTLINUX_TREE_NEXT \
--output workflows/linux/refs/default/Kconfig.next \
@@ -28,9 +25,8 @@ gen_default_refs_next:
kreleases \
--moniker linux-next
-.PHONY += gen_default_refs_stable
-gen_default_refs_stable:
- $(Q)$(E) "Generating refs/default/Kconfig.$(patsubst gen_default_refs_%,%,$@)..."
+$(TOPDIR)/workflows/linux/refs/default/Kconfig.stable: $(TOPDIR)/workflows/linux/refs/static/stable.yaml
+ $(Q)$(E) "Generating $@..."
$(Q)./scripts/generate_refs.py \
--prefix BOOTLINUX_TREE_STABLE \
--output workflows/linux/refs/default/Kconfig.stable \
@@ -39,14 +35,10 @@ gen_default_refs_stable:
kreleases \
--moniker stable
-_gen-default-refs-lns:
- $(Q)$(E) "Generating refs/default/Kconfig.{linus,next,stable} files..."
- $(Q)$(MAKE) $(REFS_TARGET_LNS) KRELEASES_FORCE="--force"
-
PHONY += refs-default
-refs-default: _gen-default-refs-lns _gen-default-refs-development refs-user-clean
+refs-default: $(REF_DEF_OBJS) _gen-default-refs-development refs-user-clean
PHONY += _refs-default
-_refs-default: _gen-default-refs-lns
+_refs-default: $(REF_DEF_OBJS)
.PHONY: $(PHONY)
--
2.43.0
prev parent reply other threads:[~2024-09-04 23:30 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-09-04 23:30 [PATCH 0/3] kdevops: update to latest kconfig Luis Chamberlain
2024-09-04 23:30 ` [PATCH 1/3] scripts/kconfig/kconfig.Makefile: move _refs-default Luis Chamberlain
2024-09-04 23:30 ` [PATCH 2/3] kdevops: remove duplicate symbols and use scripts/append-makefile-vars.sh Luis Chamberlain
2024-09-04 23:30 ` Luis Chamberlain [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240904233037.1516218-4-mcgrof@kernel.org \
--to=mcgrof@kernel.org \
--cc=chuck.lever@oracle.com \
--cc=da.gomez@samsung.com \
--cc=jlayton@kernel.org \
--cc=kdevops@lists.linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox