diff --git a/cibuildwheel/__main__.py b/cibuildwheel/__main__.py index 034673a2..3853ba28 100644 --- a/cibuildwheel/__main__.py +++ b/cibuildwheel/__main__.py @@ -160,9 +160,9 @@ def build_in_directory(args: CommandLineArguments) -> None: textwrap.dedent( """ cibuildwheel: Unable to detect platform. cibuildwheel should run on your CI server; - Travis CI, AppVeyor, Azure Pipelines, GitHub Actions, CircleCI, and Gitlab are - supported. You can run on your development machine or other CI providers using the - --platform argument. Check --help output for more information. + Travis CI, AppVeyor, Azure Pipelines, GitHub Actions, CircleCI, Gitlab, and Cirrus CI + are supported. You can run on your development machine or other CI providers + using the --platform argument. Check --help output for more information. """ ), file=sys.stderr, diff --git a/cibuildwheel/linux.py b/cibuildwheel/linux.py index 2a0ec43f..d213ce94 100644 --- a/cibuildwheel/linux.py +++ b/cibuildwheel/linux.py @@ -349,6 +349,8 @@ def build(options: Options, tmp_path: Path) -> None: # pylint: disable=unused-a If you're building on Travis CI, add `services: [docker]` to your .travis.yml. If you're building on Circle CI in Linux, add a `setup_remote_docker` step to your .circleci/config.yml. + If you're building on Cirrus CI, use `docker_builder` task on x86 + or run `docker:dind` image in an additional container on ARM. """ ), file=sys.stderr, diff --git a/cibuildwheel/util.py b/cibuildwheel/util.py index 62422201..2cf16187 100644 --- a/cibuildwheel/util.py +++ b/cibuildwheel/util.py @@ -393,6 +393,7 @@ class CIProvider(Enum): azure_pipelines = "azure_pipelines" github_actions = "github_actions" gitlab = "gitlab" + cirrus_ci = "cirrus_ci" other = "other" @@ -409,6 +410,8 @@ def detect_ci_provider() -> CIProvider | None: return CIProvider.github_actions elif "GITLAB_CI" in os.environ: return CIProvider.gitlab + elif "CIRRUS_CI" in os.environ: + return CIProvider.cirrus_ci elif strtobool(os.environ.get("CI", "false")): return CIProvider.other else: diff --git a/unit_test/main_tests/main_platform_test.py b/unit_test/main_tests/main_platform_test.py index 61dd8e85..96fd4412 100644 --- a/unit_test/main_tests/main_platform_test.py +++ b/unit_test/main_tests/main_platform_test.py @@ -19,6 +19,7 @@ def test_unknown_platform_non_ci(monkeypatch, capsys): monkeypatch.delenv("GITHUB_ACTIONS", raising=False) monkeypatch.delenv("GITLAB_CI", raising=False) monkeypatch.delenv("CIRCLECI", raising=False) + monkeypatch.delenv("CIRRUS_CI", raising=False) monkeypatch.delenv("CIBW_PLATFORM", raising=False) with pytest.raises(SystemExit) as exit: