-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding build automation for Amd64 platform
- Loading branch information
Showing
1 changed file
with
52 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
name: Build macOS Amd64 Project | ||
|
||
on: | ||
push: | ||
branches: | ||
- automation | ||
pull_request: | ||
|
||
jobs: | ||
build-macos-amd64: | ||
runs-on: macos-latest | ||
|
||
steps: | ||
- name: Checkout Code | ||
uses: actions/checkout@v4 | ||
with: | ||
submodules: true | ||
|
||
- name: Set up x86_64 Homebrew | ||
run: | | ||
arch -x86_64 /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" | ||
echo 'eval "$(/usr/local/bin/brew shellenv)"' >> ~/.zshrc | ||
eval "$(/usr/local/bin/brew shellenv)" | ||
- name: Install Dependencies | ||
run: | | ||
brew update | ||
brew install cmake ninja llvm boost | ||
- name: Configure Build | ||
run: | | ||
mkdir -p build | ||
cd build | ||
arch -x86_64 cmake .. -DCMAKE_BUILD_TYPE=Release -G "Ninja" \ | ||
-DCMAKE_OSX_ARCHITECTURES=x86_64 \ | ||
-DBOOST_ROOT=$(brew --prefix boost) | ||
- name: Build Project | ||
run: | | ||
cd build | ||
arch -x86_64 cmake --build . | ||
- name: Prepare Artifacts | ||
run: | | ||
mkdir -p artifacts | ||
cp build/bin/* artifacts/ | ||
- name: Archive Artifacts | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: macos-amd64-artifacts | ||
path: artifacts/ |