-
Updated the bash script (
scripts/build_macos_package.sh
) to create a universal macOS .pkg installer for BBai, supporting both x86_64 and arm64 architectures. -
Modified the GitHub Actions workflow (
.github/workflows/macos-package.yml
) to build both x86_64 and arm64 versions of the CLI and API. -
Created a bash script (
scripts/build_macos_package.sh
) to automate the building of a macOS .pkg installer for BBai. -
The updated script now accomplishes the following:
- Determines the current version from
version.ts
- Creates a dedicated build directory (
build/macos_package
) to keep the repo clean - Creates universal binaries for
bbai
andbbai-api
usinglipo
, combining x86_64 and arm64 versions - Places the universal binaries in the appropriate location in the package structure
- Generates a
distribution.xml
file for the installer - Builds a component package using
pkgbuild
- Creates the final product package using
productbuild
- Includes steps to display package contents and verify the universal binaries
- Determines the current version from
-
Resolved issues with package creation:
- Fixed problems with file inclusion in the final package
- Updated the package identifier to
tips.bbai.bbai
- Ensured
bbai
andbbai-api
are correctly included in the final package
-
The script now successfully builds a universal macOS package that includes the BBai executables for both x86_64 and arm64 architectures.
-
The
build_macos_package.sh
script is functional and creates a valid universal macOS installer package supporting both x86_64 and arm64 architectures. -
The GitHub Actions workflow has been updated to build both x86_64 and arm64 versions of the CLI and API.
-
The workflow correctly uploads the universal package as a release asset.
-
The package correctly includes the universal
bbai
andbbai-api
executables in/usr/local/bin
. -
The universal package is named with the suffix '-universal' for clarity.
-
Package signing is prepared but commented out, pending reinstatement of the Apple Developer account.
-
Architecture Testing:
- Test the universal package on both Intel and Apple Silicon Macs to ensure proper functionality on both architectures.
-
Performance Evaluation:
- Evaluate the performance of the universal binaries on both architectures to ensure there are no significant drawbacks.
-
Testing:
- Conduct thorough testing of the package installation on various macOS versions.
- Verify that the installed
bbai
andbbai-api
executables work as expected.
-
GitHub Actions Verification:
- Verify that the updated
.github/workflows/macos-package.yml
file correctly builds and uploads the universal macOS package as a release asset. - Ensure the workflow runs successfully on both push events and manual triggers.
- Verify that the updated
-
Documentation Updates:
- Update
INSTALL.md
to include instructions for installing BBai using the macOS package. - Modify
README.md
to mention the availability of the macOS installer package.
- Update
-
Package Signing:
- Once the Apple Developer account is reinstated, implement and test the package signing step in the script.
-
Notarization:
- Research and implement notarization process for the macOS package to ensure smooth installation on recent macOS versions.
-
User Guide:
- Create a macOS-specific user guide explaining how to install and use BBai with the new package installer.
-
Version Automation:
- Consider automating the version extraction process to ensure it always matches the current project version.
-
Error Handling:
- Enhance the script with more robust error handling and user-friendly error messages.
-
Cleanup Process:
- Review and potentially enhance the cleanup process after package creation.
-
Integration with Main Release Process:
- Once all tests pass, integrate the macOS package building into the main release process of BBai.
This summary serves as a checkpoint for the macOS package build process. Future development can refer to this document to understand the current state and proceed with the recommended next steps.