Skip to content

Commit 01e0e12

Browse files
authored
NO-JIRA: fix selftest, need to use gmake on macOS (opendatahub-io#799)
1 parent 03c3b6f commit 01e0e12

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

ci/cached-builds/gha_pr_changed_files.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,12 @@
22
import os
33
import pathlib
44
import re
5+
import shutil
56
import subprocess
67
import unittest
78

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

1012

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

0 commit comments

Comments
 (0)