Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,6 @@ docs/_build
.pixi/*
!.pixi/config.toml

# pixi installer that the Windows entry-point scripts fetch into the
# working directory (make_windows_zip.ps1,
# windows-download-cache-and-build-module-wheels.ps1)
# pixi installer that windows-download-cache-and-build-module-wheels.ps1
# fetches into the working directory
install-pixi.ps1
29 changes: 15 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -386,19 +386,17 @@ To see how to build ITK Python Build Caches, see this section:

#### GitHub Compatible Caches

To build the caches compatible with GitHub Actions CI and the ITKPythonBuilds repository. You can run:

On Linux and macOS systems
`release-wheels` builds the caches compatible with GitHub Actions CI and the
ITKPythonBuilds repository alongside the wheels: it passes
`--build-itk-tarball-cache` to `build_wheels.py` for every target.

```bash
bash scripts/make_tarballs.sh # py311 (optionally add specific version of Python)
pixi run release-wheels v6.0b03
```

On Windows systems

```powershell
.\scripts\make_windows_zip.ps1 # py311 (optionally add specific version of Python)
```
POSIX builds write `dist/ITKPythonBuilds-<platform>-<arch>.tar.zst` under the
build root (`scripts/wheel_packaging.py`); Windows writes
`ITKPythonBuilds-windows.zip` in the build root.

> [!IMPORTANT]
> Build caches embed absolute paths. If you extract a tarball to a different
Expand All @@ -410,11 +408,14 @@ On Windows systems
> | macOS | `/Users/svc-dashboard/D/P/ITKPythonPackage-build` |
> | Windows | `C:\BDR` |
>
> The scripts above set these for you. **`build_wheels.py` does not**: its
> default build root is `<repo>/../ITKPythonPackage-build`, which matches the
> convention only on Windows. A cache built by calling `build_wheels.py`
> directly therefore needs `--build-dir-root` set to the path in the table, or
> it will not be usable by the reusable workflow. Check a finished cache with:
> `release-wheels` uses the manylinux and Windows paths by default. On macOS
> its build root is `<repo>/../ITKPythonPackage-build`, so clone the
> repository at `/Users/svc-dashboard/D/P/ITKPythonPackage` or pass
> `--build-root /Users/svc-dashboard/D/P/ITKPythonPackage-build`.
> `build_wheels.py` called directly defaults to `C:\BDR` on Windows and to
> `<repo>/../ITKPythonPackage-build` elsewhere, so a macOS cache built that way
> needs `--build-dir-root` set to the path in the table, or it will not be
> usable by the reusable workflow. Check a finished cache with:
>
> ```bash
> tar -xOf <cache>.tar ITKPythonPackage-build/build/ITK-support-bld/CMakeCache.txt \
Expand Down
23 changes: 10 additions & 13 deletions docs/Build_ITK_Python_packages.rst
Original file line number Diff line number Diff line change
Expand Up @@ -295,21 +295,16 @@ artifacts) so that external module builds can skip the costly ITK compilation st
These are the same caches distributed via `ITKPythonBuilds
<https://github.com/InsightSoftwareConsortium/ITKPythonBuilds>`_ releases.

By default these scripts build for Python 3.11 but you can optionally add a specific version to build for

Linux / macOS:
``release-wheels`` builds a cache for every target it builds, by passing
``--build-itk-tarball-cache`` to ``build_wheels.py``:

.. code-block:: bash

ITK_GIT_TAG=v6.0b01
bash scripts/make_tarballs.sh py311

Windows (PowerShell):

.. code-block:: powershell
pixi run release-wheels v6.0b01

$env:ITK_GIT_TAG = "v6.0b01"
.\scripts\make_windows_zip.ps1 py311
POSIX builds write ``dist/ITKPythonBuilds-<platform>-<arch>.tar.zst`` under the
build root (``scripts/wheel_packaging.py``); Windows writes
``ITKPythonBuilds-windows.zip`` in the build root.

Or via ``build_wheels.py`` directly:

Expand All @@ -329,8 +324,10 @@ Or via ``build_wheels.py`` directly:
- **macOS**: ``/Users/svc-dashboard/D/P/ITKPythonPackage-build``
- **Windows**: ``C:\BDR``

The ``make_tarballs.sh`` and ``make_windows_zip.ps1`` scripts enforce these
paths automatically.
``release-wheels`` uses the manylinux and Windows paths by default. On
macOS, clone the repository at ``/Users/svc-dashboard/D/P/ITKPythonPackage``
or pass ``--build-root /Users/svc-dashboard/D/P/ITKPythonPackage-build``
(``--build-dir-root`` for ``build_wheels.py``).


Output Artifacts
Expand Down
111 changes: 0 additions & 111 deletions scripts/make_tarballs.sh

This file was deleted.

174 changes: 0 additions & 174 deletions scripts/make_windows_zip.ps1

This file was deleted.

Loading