Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 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
38 changes: 28 additions & 10 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ on:
branches: [ "main" ]

jobs:
build-linux:
build-linux-amd64:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
uses: actions/checkout@v5

- name: Set up CMake
uses: jwlawson/actions-setup-cmake@v2
Expand All @@ -34,7 +34,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
uses: actions/checkout@v5

- name: Set up CMake
uses: jwlawson/actions-setup-cmake@v2
Expand All @@ -44,16 +44,16 @@ jobs:
sudo apt-get update
sudo apt-get install -y mingw-w64 mingw-w64-tools

- name: Build (crosscmopile) PC Windows
- name: Build (crosscompile) PC Windows
run: |
cmake -S ${{github.workspace}} -B ${{github.workspace}}/build-windows -DCMAKE_TOOLCHAIN_FILE=${{github.workspace}}/windows_x86_64_toolchain.cmake -DCMAKE_BUILD_TYPE=Release
cmake --build ${{github.workspace}}/build-windows

build-arm:
build-linux-arm64:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
uses: actions/checkout@v5

- name: Set up CMake
uses: jwlawson/actions-setup-cmake@v2
Expand All @@ -63,23 +63,41 @@ jobs:
sudo apt-get update
sudo apt-get install -y gcc-aarch64-linux-gnu binutils-aarch64-linux-gnu

- name: Build ARM
- name: Build (crosscompile) PC Linux ARM64
run: |
cmake -S ${{github.workspace}} -B ${{github.workspace}}/build-arm -DCMAKE_TOOLCHAIN_FILE=${{github.workspace}}/arm64_toolchain.cmake -DCMAKE_BUILD_TYPE=Release
cmake --build ${{github.workspace}}/build-arm

build-darwin-arm64:
runs-on: macos-13-xlarge
steps:
- uses: actions/checkout@v5
- name: Build macOS ARM64 (Apple Silicon)
run: |
cmake -S ${{github.workspace}} -B ${{github.workspace}}/build-darwin -DUNIVERSAL=FALSE -DCMAKE_OSX_ARCHITECTURES=arm64 -DARM=1 -DCMAKE_BUILD_TYPE=Release
cmake --build ${{github.workspace}}/build-darwin

build-darwin-universal:
runs-on: macos-13-xlarge
steps:
- uses: actions/checkout@v5
- name: Build macOS Universal (ARM64 + AMD64)
run: |
cmake -S ${{github.workspace}} -B ${{github.workspace}}/build -DCMAKE_TOOLCHAIN_FILE=macos_universal_toolchain.cmake -DUNIVERSAL=1 -DCMAKE_BUILD_TYPE=Release
cmake --build ${{github.workspace}}/build

test-linux:
runs-on: ubuntu-latest
needs: build-linux
needs: build-linux-amd64
steps:
- name: Checkout code
uses: actions/checkout@v4
uses: actions/checkout@v5

- name: Set up CMake
uses: jwlawson/actions-setup-cmake@v2

- name: Download build artifacts
uses: actions/download-artifact@v4
uses: actions/download-artifact@v5
with:
name: build-PC-artifacts

Expand Down
72 changes: 66 additions & 6 deletions .github/workflows/release_packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ on:
workflow_dispatch:

jobs:
build-linux:
build-linux-amd64:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
uses: actions/checkout@v5

- name: Set up CMake
uses: jwlawson/actions-setup-cmake@v2
Expand Down Expand Up @@ -41,11 +41,11 @@ jobs:
draft: false
overwrite: true

build-arm:
build-linux-arm64:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
uses: actions/checkout@v5

- name: Set up CMake
uses: jwlawson/actions-setup-cmake@v2
Expand All @@ -61,7 +61,7 @@ jobs:
cmake --build ${{github.workspace}}/build-arm
cd ${{github.workspace}}/build-arm
cpack -C Release

- name: 'Upload ARM artifacts'
uses: actions/upload-artifact@v4
with:
Expand All @@ -81,11 +81,71 @@ jobs:
draft: false
overwrite: true

build-darwin-arm64:
runs-on: macos-13-xlarge
steps:
- uses: actions/checkout@v5

- name: Build macOS ARM64 (Apple Silicon)
run: |
cmake -S ${{github.workspace}} -B ${{github.workspace}}/build-darwin -DUNIVERSAL=FALSE -DCMAKE_OSX_ARCHITECTURES=arm64 -DARM=1 -DCMAKE_BUILD_TYPE=Release
cmake --build ${{github.workspace}}/build-darwin
cd ${{github.workspace}}/build-darwin
# Builds OpenAPV-0.2.0.3-Darwin.tar.gz
Copy link
Collaborator

Choose a reason for hiding this comment

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

Remove that comment with hardcoded version

cpack -C Release -G TGZ

- uses: actions/upload-artifact@v4
with:
name: openapv-darwin-${{github.event.release.tag_name}}
path: |
${{ github.workspace }}/build-darwin/*.tar.gz
${{ github.workspace }}/build-darwin/*.md5
retention-days: 7

- uses: xresloader/upload-to-github-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
file: "build-darwin/*.tar.gz; build-darwin/*.md5"
update_latest_release: true
draft: false
overwrite: true

build-darwin-universal:
runs-on: macos-13-xlarge
steps:
- uses: actions/checkout@v5

- name: Build macOS Universal (ARM64 + AMD64)
run: |
cmake -S ${{github.workspace}} -B ${{github.workspace}}/build -DCMAKE_TOOLCHAIN_FILE=macos_universal_toolchain.cmake -DUNIVERSAL=1 -DCMAKE_BUILD_TYPE=Release
cmake --build ${{github.workspace}}/build
cd ${{github.workspace}}/build
# Builds OpenAPV-0.2.0.3-Darwin.dmg
Copy link
Collaborator

Choose a reason for hiding this comment

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

Remove that comment with hardcoded version

cpack -C Release -G DragNDrop

- uses: actions/upload-artifact@v4
with:
name: openapv-universal-${{github.event.release.tag_name}}
path: |
${{ github.workspace }}/build/*.dmg
${{ github.workspace }}/build/*.md5
retention-days: 7

- uses: xresloader/upload-to-github-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
file: "build/*.dmg; build/*.md5"
update_latest_release: true
draft: false
overwrite: true

build-windows:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
uses: actions/checkout@v5

- name: Set up CMake
uses: jwlawson/actions-setup-cmake@v2
Expand Down
18 changes: 18 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,24 @@ The APV codec standard has the following features:
cmake --build build-windows
```

- Build Instructions macOS (Apple Silicon)
Copy link
Collaborator

@sidwat sidwat Sep 19, 2025

Choose a reason for hiding this comment

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

The following build commands can also be added :-

  1. macOS universal build :
cmake -S . -B build -DCMAKE_TOOLCHAIN_FILE=macos_universal_toolchain.cmake -DUNIVERSAL=1 -DCMAKE_BUILD_TYPE=Release
cmake --build build
  1. ios arm64 build :-
cmake -S . -B build -DCMAKE_TOOLCHAIN_FILE=ios_arm64_toolchain.cmake -DCMAKE_BUILD_TYPE=Release
cmake --build build

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thank you, done.

```
cmake -S . -B build-darwin -DUNIVERSAL=FALSE -DCMAKE_OSX_ARCHITECTURES=arm64 -DARM=1 -DCMAKE_BUILD_TYPE=Release
cmake --build build-darwin
```

- Build Instructions macOS (Universal)
```
cmake -S . -B build -DCMAKE_TOOLCHAIN_FILE=macos_universal_toolchain.cmake -DUNIVERSAL=1 -DCMAKE_BUILD_TYPE=Release
cmake --build build
```

- Build Instructions iOS (ARM64)
```
cmake -S . -B build -DCMAKE_TOOLCHAIN_FILE=ios_arm64_toolchain.cmake -DCMAKE_BUILD_TYPE=Release
cmake --build build
```

- Output Location
- Executable applications can be found under build*/bin/
- Library files can be found under build*/lib/
Expand Down