Skip to content

Add MacOS build packaging tool#734

Merged
m-reuter merged 30 commits intoDeep-MI:devfrom
OtabekRintaro:feature/release-packaging
Nov 18, 2025
Merged

Add MacOS build packaging tool#734
m-reuter merged 30 commits intoDeep-MI:devfrom
OtabekRintaro:feature/release-packaging

Conversation

@OtabekRintaro
Copy link
Contributor

This PR contains a tool for packaging MacOS build for FastSurfer and modified workflow to automate packaging on FastSurfer release.

build_release_package.sh script packages FastSurfer along with minimised freesurfer code.
Modified deploy.yml workflow builds and uploads packaged FastSurfers to artifacts on FastSurfer release.

  • Folder structure change: Docker, Singularity and macos_build in the tools folder
  • Static files used for installer customisation added into doc folder

@m-reuter
Copy link
Member

python3.10 is hardcoded in a few places. We should try to make it easier to upgrade to a new python version in the future, which can happen pretty often. Maybe it is even possible to replace with python3 ?

@m-reuter m-reuter marked this pull request as draft October 15, 2025 14:48
@OtabekRintaro OtabekRintaro force-pushed the feature/release-packaging branch from 2f413e4 to 051c9ff Compare October 15, 2025 15:53
Copy link
Member

@dkuegler dkuegler left a comment

Choose a reason for hiding this comment

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

Nice work, see comments.

@dkuegler
Copy link
Member

We will also need to update the install instructions for macOS in doc/overview/INSTALL.md.

@OtabekRintaro OtabekRintaro force-pushed the feature/release-packaging branch from 85f3e65 to d06303d Compare October 22, 2025 14:49
@OtabekRintaro OtabekRintaro force-pushed the feature/release-packaging branch from 9eeec5b to 3b74988 Compare October 31, 2025 16:36
@dkuegler dkuegler self-requested a review November 4, 2025 12:26
Copy link
Member

@dkuegler dkuegler left a comment

Choose a reason for hiding this comment

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

Lots of good stuff, some minor comments.

Big things:

  1. Documentation of the new installation method (in doc/overview/INSTALL.md)
  2. Fix the workflow
  3. @dkuegler While the docker build seems to work, the docker "running" seems to have errors in the surface pipeline, I will have a look at that on Friday.

@dkuegler dkuegler force-pushed the feature/release-packaging branch from 11920c8 to d8b4cb1 Compare November 4, 2025 18:20
@dkuegler dkuegler force-pushed the feature/release-packaging branch from 8ce91b4 to b45b11f Compare November 10, 2025 19:01
@dkuegler dkuegler force-pushed the feature/release-packaging branch from d83a22a to c3574a3 Compare November 10, 2025 22:20
@dkuegler dkuegler marked this pull request as ready for review November 11, 2025 14:21
@dkuegler dkuegler force-pushed the feature/release-packaging branch from f68439d to 3d493dc Compare November 14, 2025 15:32
@dkuegler dkuegler force-pushed the feature/release-packaging branch from 3d493dc to a8f8084 Compare November 14, 2025 15:34
@OtabekRintaro OtabekRintaro force-pushed the feature/release-packaging branch from 8b5891c to ea21063 Compare November 14, 2025 16:16
@dkuegler dkuegler marked this pull request as draft November 14, 2025 16:36
Copy link
Member

@dkuegler dkuegler left a comment

Choose a reason for hiding this comment

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

Looks good to me :)
Please change the PR from draft to ready to merge when you completed your testing.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR adds macOS build packaging tools for FastSurfer and reorganizes the project structure by moving Docker, Singularity, and build tools into a tools folder. The changes enable automated macOS package creation on release and improve project organization.

Key changes:

  • New macOS packaging system with installer scripts and build tools
  • Reorganized folder structure: Docker, Singularity, and build scripts moved to tools/ directory
  • Added FreeSurfer configuration to pyproject.toml for centralized version management
  • Updated documentation and workflows to reflect the new folder structure

Reviewed Changes

Copilot reviewed 34 out of 40 changed files in this pull request and generated 16 comments.

Show a summary per file
File Description
tools/read_toml.py New utility for extracting values from TOML configuration files
tools/macos_build/build_release_package.sh Main script for building macOS installer packages
tools/macos_build/scripts/*.sh Post-installation and FreeSurfer linking scripts for macOS
tools/build/install_fs_pruned.sh Updated FreeSurfer installation script with improved download handling and pyproject.toml integration
pyproject.toml Added FreeSurfer version and URL configuration
doc/overview/MACOS.md New macOS-specific installation documentation
doc/overview/INSTALL.md Updated installation instructions with macOS package option
.github/workflows/deploy.yml Modified to build and upload macOS packages on release
tools/Docker/* Moved Docker-related files from root to tools directory with path updates
Comments suppressed due to low confidence (2)

tools/build/install_fs_pruned.sh:68

  • The embedded Python script (lines 52-68) for reading pyproject.toml is duplicated in multiple places in the codebase (also in tools/read_toml.py). Consider extracting this to a shared function or always using the dedicated tools/read_toml.py script to avoid code duplication and maintenance issues.
    tools/build/install_fs_pruned.sh:22
  • Typo in usage message: "install_fs_prunded" should be "install_fs_pruned.sh"

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

m-reuter and others added 4 commits November 18, 2025 12:48
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@OtabekRintaro
Copy link
Contributor Author

doc build has failed due to cloudflare being down

@OtabekRintaro OtabekRintaro force-pushed the feature/release-packaging branch from 68dffee to 9045517 Compare November 18, 2025 15:11
@OtabekRintaro OtabekRintaro marked this pull request as ready for review November 18, 2025 15:15
@m-reuter m-reuter merged commit 9bd088b into Deep-MI:dev Nov 18, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants