Skip to content

Commit

Permalink
NO-JIRA: fix selftest, need to use gmake on macOS (#799)
Browse files Browse the repository at this point in the history
  • Loading branch information
jiridanek authored Dec 9, 2024
1 parent 03c3b6f commit 01e0e12
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion ci/cached-builds/gha_pr_changed_files.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,12 @@
import os
import pathlib
import re
import shutil
import subprocess
import unittest

PROJECT_ROOT = pathlib.Path(__file__).parent.parent.parent.resolve()
MAKE = shutil.which("gmake") or shutil.which("make")


def get_github_token() -> str:
Expand All @@ -30,7 +32,7 @@ def analyze_build_directories(make_target) -> list[str]:
pattern = re.compile(r"#\*# Image build directory: <(?P<dir>[^>]+)> #\(MACHINE-PARSED LINE\)#\*#\.\.\.")
try:
logging.debug(f"Running make in --just-print mode for target {make_target}")
for line in subprocess.check_output(["make", make_target, "--just-print"], encoding="utf-8",
for line in subprocess.check_output([MAKE, make_target, "--just-print"], encoding="utf-8",
cwd=PROJECT_ROOT).splitlines():
if m := pattern.match(line):
directories.append(m["dir"])
Expand Down

0 comments on commit 01e0e12

Please sign in to comment.