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
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,5 @@ CMakeFiles
*.so
ecell4/*/tests/*.h5
ecell4/*/tests/*_test
dist/
ecell4_base.egg-info/
29 changes: 29 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,32 @@ What is E-Cell System?
E-Cell System is a software platform for modeling, simulation and analysis of complex, heterogeneous and multi-scale systems like a cell.

See https://ecell4.e-cell.org/

Build macOS arm64 wheel
------------------------

The following steps will build:
`dist/ecell4_base-2.1.2-cp310-cp310-macosx_26_0_arm64.whl`
on macOS Tahoe (Apple Silicon, arm64).
Comment on lines +21 to +23
Copy link

Copilot AI Mar 24, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The wheel filename here is hard-coded to a specific project version, Python ABI (cp310), and macOS tag (macosx_26_0_arm64). This will be different for other Python versions and depending on the build machine/deployment target, so readers following the guide may not find this exact file. Consider describing the output as a pattern (e.g., dist/*.whl) and/or referencing variables like and instead of a single concrete filename.

Copilot uses AI. Check for mistakes.

```bash
# 1) Install required build dependencies
brew install cmake hdf5 boost gsl

# 2) Build wheel for arm64
cd /path/to/ecell4_base
rm -rf dist build
uv venv --python 3.10
# or
# uv venv --python 3.11
# uv venv --python 3.12
# uv venv --python 3.13
# uv venv --python 3.14
source .venv/bin/activate
uv pip install pip
CMAKE_OSX_ARCHITECTURES=arm64 pip wheel . -w dist --no-deps
Copy link

Copilot AI Mar 24, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The build step doesn't set MACOSX_DEPLOYMENT_TARGET, so the produced wheel tag/compatibility may vary with the host OS version (often making wheels built on newer macOS not installable on older macOS). The repo's GitHub Actions wheel build sets MACOSX_DEPLOYMENT_TARGET="14.0" (.github/workflows/wheels.yml), so it would be more reproducible to document setting the same environment variable for local builds too.

Suggested change
CMAKE_OSX_ARCHITECTURES=arm64 pip wheel . -w dist --no-deps
MACOSX_DEPLOYMENT_TARGET=14.0 CMAKE_OSX_ARCHITECTURES=arm64 pip wheel . -w dist --no-deps

Copilot uses AI. Check for mistakes.

# 3) (Optional) Verify install from the built wheel in the above venv
pip install dist/ecell4_base-2.1.2-cp310-cp310-macosx_26_0_arm64.whl
python -c "from ecell4_base.core import *; sp1 = Species('A', 0.0025, 1); print(sp1.list_attributes())"
Comment on lines +42 to +44
Copy link

Copilot AI Mar 24, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This verification step hard-codes the wheel filename (version/ABI/platform tag). If the user builds with a different Python version (the guide suggests 3.11+ above) or a different deployment target, the filename will differ and this command will fail. Consider using a glob (dist/*.whl) or showing how to discover the built wheel name (e.g., listing dist/) before installing.

Copilot uses AI. Check for mistakes.
```
Loading