From 2c80f39e4c2a7efc4798944ea4a0faebbf3f97fe Mon Sep 17 00:00:00 2001 From: Ruben Vorderman Date: Fri, 5 Apr 2024 16:24:10 +0200 Subject: [PATCH 1/2] Checkout both macos --- .github/workflows/ci.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3aa6b46..59170f2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -62,7 +62,9 @@ jobs: - "pypy-3.10" os: ["ubuntu-latest"] include: - - os: "macos-latest" + - os: "macos-latest" # For m1 macos + python-version: "3.8" + - os: "macos-13" # for x86 macos python-version: "3.8" - os: "windows-latest" python-version: "3.8" From 39b8832983ad4ddfcfe909cf8de0fe4484ec10e8 Mon Sep 17 00:00:00 2001 From: Ruben Vorderman Date: Fri, 5 Apr 2024 16:26:14 +0200 Subject: [PATCH 2/2] Be make agnostic for macos --- setup.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/setup.py b/setup.py index 2a34c5e..8da9d85 100644 --- a/setup.py +++ b/setup.py @@ -105,7 +105,8 @@ def build_zlib_ng(): run_args = dict(cwd=build_dir, env=build_env) if sys.platform == "darwin": # Cmake does not work properly subprocess.run([os.path.join(build_dir, "configure")], **run_args) - subprocess.run(["gmake", "libz-ng.a"], **run_args) + make_program = "gmake" if shutil.which("gmake") else "make" + subprocess.run([make_program, "libz-ng.a"], **run_args) elif sys.platform == "linux": subprocess.run([os.path.join(build_dir, "configure")], **run_args) subprocess.run(["make", "libz-ng.a", "-j", str(cpu_count)], **run_args)