Skip to content

Commit

Permalink
phase1: make list of builders configurable
Browse files Browse the repository at this point in the history
Currently we always populate builders (build targets) from the Git tree,
but for staging environment this is usually overkill as we might need
just a bunch of targets, so lets make this configurable.

Signed-off-by: Petr Štetiar <ynezz@true.cz>
  • Loading branch information
ynezz committed Jun 1, 2024
1 parent 8673562 commit d7c977e
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
5 changes: 5 additions & 0 deletions phase1/config.ini.example
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,11 @@ config_seed = # Seed configuration
CONFIG_CCACHE=n
CONFIG_KERNEL_KALLSYMS=y
CONFIG_AUTOREMOVE=y
build_targets = armsr/armv8
malta/be
mediatek/filogic
qualcommax/ipq807x
x86/64

[branch openwrt-22.03]
name = openwrt-22.03
Expand Down
9 changes: 8 additions & 1 deletion phase1/master.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ def ini_parse_branch(section):
b["usign_comment"] = section.get("usign_comment", usign_comment)

b["config_seed"] = section.get("config_seed")
b["build_targets"] = section.get("build_targets")

b["kmod_archive"] = section.getboolean("kmod_archive", False)

Expand Down Expand Up @@ -300,8 +301,14 @@ targets = dict()


def populateTargets():
def buildTargetsConfigured(branch):
builders = branches[branch].get("build_targets")
return builders and set(filter(None, [t.strip() for t in builders.split("\n")]))

for branch in branchNames:
populateTargetsForBranch(branch)
targets[branch] = buildTargetsConfigured(branch)
if not targets[branch]:
populateTargetsForBranch(branch)


def populateTargetsForBranch(branch):
Expand Down

0 comments on commit d7c977e

Please sign in to comment.