Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update CI #15

Merged
merged 6 commits into from
Jun 16, 2024
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
70 changes: 40 additions & 30 deletions .github/workflows/cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,40 +5,52 @@ on:
branches: ["*"]

jobs:
build-linux-gcc-13-x64:
linux-gcc-x64:
runs-on: ubuntu-latest
strategy:
matrix:
version: [13]
fail-fast: false
steps:
- uses: actions/checkout@v4
- uses: seanmiddleditch/gha-setup-ninja@v4

- name: Install Toolchains PPA
run: |
sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test
sudo apt-get -y update

- name: Install GCC
run: sudo apt-get -y install gcc-${{matrix.version}} g++-${{matrix.version}}

- name: Configure
env:
CC: gcc-13
CXX: gcc-13
CC: gcc-${{matrix.version}}
CXX: g++-${{matrix.version}}
working-directory: ${{github.workspace}}
run: cmake --preset env-cc-release

- name: Build
env:
CC: gcc-13
CXX: gcc-13
CC: gcc-${{matrix.version}}
CXX: g++-${{matrix.version}}
ACTIONS_STEP_DEBUG: true
working-directory: ${{github.workspace}}
run: cmake --build --preset env-cc-release

- name: Test
env:
CC: gcc-13
CXX: gcc-13
CC: gcc-${{matrix.version}}
CXX: g++-${{matrix.version}}
ACTIONS_STEP_DEBUG: true
working-directory: ${{github.workspace}}
run: ctest --preset env-cc-release --verbose

build-linux-clang-16-x64:
linux-clang-x64:
runs-on: ubuntu-latest
strategy:
matrix:
version: [16, 17, 18]
fail-fast: false
steps:
- uses: actions/checkout@v4
Expand All @@ -48,38 +60,38 @@ jobs:
run: |
wget https://apt.llvm.org/llvm.sh
chmod +x llvm.sh
sudo ./llvm.sh 16
sudo apt-get -y install clang-tidy-16
sudo ./llvm.sh ${{matrix.version}}
sudo apt-get -y install clang-tidy-${{matrix.version}}

- name: Replace clang-tidy
run: sudo cp /usr/bin/clang-tidy-16 /usr/bin/clang-tidy -f
run: sudo cp /usr/bin/clang-tidy-${{matrix.version}} /usr/bin/clang-tidy -f

- name: Configure
env:
CC: clang-16
CXX: clang-16
CC: clang-${{matrix.version}}
CXX: clang++-${{matrix.version}}
working-directory: ${{github.workspace}}
run: |
rm -rf build
cmake --preset env-cc-release

- name: Build
env:
CC: clang-16
CXX: clang-16
CC: clang-${{matrix.version}}
CXX: clang++-${{matrix.version}}
ACTIONS_STEP_DEBUG: true
working-directory: ${{github.workspace}}
run: cmake --build --preset env-cc-release

- name: Test
env:
CC: clang-16
CXX: clang-16
CC: clang-${{matrix.version}}
CXX: clang++-${{matrix.version}}
ACTIONS_STEP_DEBUG: true
working-directory: ${{github.workspace}}
run: ctest --preset env-cc-release --verbose

build-windows-msvc-x64:
windows-msvc-x64:
runs-on: windows-latest
strategy:
fail-fast: false
Expand Down Expand Up @@ -116,38 +128,36 @@ jobs:
working-directory: ${{github.workspace}}
run: ctest --preset msvc-release --verbose

build-macos-clang-15-x64:
macos-clang-x64:
runs-on: macos-latest
strategy:
matrix:
version: [16, 17, 18]
fail-fast: false
steps:
- uses: actions/checkout@v4
- uses: seanmiddleditch/gha-setup-ninja@v4

- name: Install LLVM and Clang
uses: KyleMayes/install-llvm-action@v1
with:
version: "15.0"
- name: Install LLVM
run: |
brew install llvm@${{matrix.version}}
echo "PATH=$(brew --prefix llvm@${{matrix.version}})/bin:$PATH" >> $GITHUB_ENV
echo "CC=$(brew --prefix llvm@${{matrix.version}})/bin/clang" >> $GITHUB_ENV
echo "CXX=$(brew --prefix llvm@${{matrix.version}})/bin/clang++" >> $GITHUB_ENV
echo "LDFLAGS='-L$(brew --prefix llvm@${{matrix.version}})/lib/c++ -Wl,-rpath,$(brew --prefix llvm@${{matrix.version}})/lib/c++'" >> $GITHUB_ENV

- name: Configure
env:
CC: clang-15
CXX: clang-15
working-directory: ${{github.workspace}}
run: cmake --preset env-cc-release

- name: Build
env:
CC: clang-15
CXX: clang-15
ACTIONS_STEP_DEBUG: true
working-directory: ${{github.workspace}}
run: cmake --build --preset env-cc-release

- name: Test
env:
CC: clang-15
CXX: clang-15
ACTIONS_STEP_DEBUG: true
working-directory: ${{github.workspace}}
run: ctest --preset env-cc-release --verbose
Expand Down
14 changes: 11 additions & 3 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
build:
strategy:
fail-fast: false
runs-on: "ubuntu-latest"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

Expand All @@ -33,6 +33,14 @@ jobs:
run: |
pip install sphinx breathe exhale myst-parser docutils pydata-sphinx-theme sphinx-sitemap

- name: Install Toolchains PPA
run: |
sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test
sudo apt-get -y update

- name: Install GCC
run: sudo apt-get -y install gcc-13 g++-13

- name: Configure Linux
working-directory: ${{github.workspace}}
run: |
Expand All @@ -41,8 +49,8 @@ jobs:

- name: Build Linux
env:
CC: gcc-12
CXX: gcc-12
CC: gcc-13
CXX: gcc-13
working-directory: ${{github.workspace}}
run: |
mkdir -p docs/_build/html
Expand Down
75 changes: 50 additions & 25 deletions .github/workflows/xmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,11 @@ on:
branches: ["*"]

jobs:
build-linux-gcc-13-x64:
linux-gcc-x64:
runs-on: ubuntu-latest
strategy:
matrix:
version: [13]
fail-fast: false
steps:
- uses: actions/checkout@v4
Expand All @@ -19,9 +21,17 @@ jobs:
sudo apt-get -y update
sudo apt-get -y install xmake

- name: Install Toolchains PPA
run: |
sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test
sudo apt-get -y update

- name: Install GCC
run: sudo apt-get -y install gcc-${{matrix.version}} g++-${{matrix.version}}

- name: Configure
working-directory: ${{github.workspace}}
run: xmake f -c -y --toolchain=gcc-13
run: xmake f -c -y --toolchain=gcc-${{matrix.version}} --hyperion_enable_tracy=y

- name: Build
env:
Expand All @@ -33,7 +43,7 @@ jobs:
env:
ACTIONS_STEP_DEBUG: true
working-directory: ${{github.workspace}}
run: xmake test
run: xmake test -vD

- name: Extract branch name
shell: bash
Expand All @@ -46,12 +56,14 @@ jobs:
run: |
xrepo add-repo -y hyperion "https://github.com/braxtons12/hyperion_packages.git"
xrepo update-repo -y
xrepo install -y --toolchain=gcc-13 "hyperion_mpl ${{ steps.extract_branch.outputs.branch }}"
xrepo install -y --toolchain=gcc-13 --configs="hyperion_enable_tracy=true" "hyperion_mpl ${{ steps.extract_branch.outputs.branch }}"
xrepo install -y --toolchain=gcc-${{matrix.version}} "hyperion_mpl ${{ steps.extract_branch.outputs.branch }}"
xrepo install -y --toolchain=gcc-${{matrix.version}} --configs="hyperion_enable_tracy=true" "hyperion_mpl ${{ steps.extract_branch.outputs.branch }}"

build-linux-clang-16-x64:
linux-clang-x64:
runs-on: ubuntu-latest
strategy:
matrix:
version: [16, 17, 18]
fail-fast: false
steps:
- uses: actions/checkout@v4
Expand All @@ -67,17 +79,17 @@ jobs:
run: |
wget https://apt.llvm.org/llvm.sh
chmod +x llvm.sh
sudo ./llvm.sh 16
sudo apt-get -y install clang-tidy-16
sudo ./llvm.sh ${{matrix.version}}
sudo apt-get -y install clang-tidy-${{matrix.version}}

- name: Replace clang-tidy
run: sudo cp /usr/bin/clang-tidy-16 /usr/bin/clang-tidy -f
run: sudo cp /usr/bin/clang-tidy-${{matrix.version}} /usr/bin/clang-tidy -f

- name: Configure
working-directory: ${{github.workspace}}
run: |
rm -rf build .xmake
xmake f -c -y --toolchain=clang-16
xmake f -c -y --toolchain=clang-${{matrix.version}} --hyperion_enable_tracy=y

- name: Build
env:
Expand All @@ -91,7 +103,7 @@ jobs:
env:
ACTIONS_STEP_DEBUG: true
working-directory: ${{github.workspace}}
run: xmake test
run: xmake test -vD

- name: Extract branch name
shell: bash
Expand All @@ -104,10 +116,10 @@ jobs:
run: |
xrepo add-repo -y hyperion "https://github.com/braxtons12/hyperion_packages.git"
xrepo update-repo -y
xrepo install -y --toolchain=clang-16 "hyperion_mpl ${{ steps.extract_branch.outputs.branch }}"
xrepo install -y --toolchain=clang-16 --configs="hyperion_enable_tracy=true" "hyperion_mpl ${{ steps.extract_branch.outputs.branch }}"
xrepo install -y --toolchain=clang-${{matrix.version}} "hyperion_mpl ${{ steps.extract_branch.outputs.branch }}"
xrepo install -y --toolchain=clang-${{matrix.version}} --configs="hyperion_enable_tracy=true" "hyperion_mpl ${{ steps.extract_branch.outputs.branch }}"

build-windows-msvc-x64:
windows-msvc-x64:
runs-on: windows-latest
strategy:
fail-fast: false
Expand All @@ -129,11 +141,16 @@ jobs:
arch: x64

- name: Install XMake
run: scoop install xmake
run: |
scoop install xmake
xmake update -sfy master
Start-Sleep -Seconds 2
xmake update -fy master

- name: Configure
working-directory: ${{github.workspace}}
run: xmake f -c -y --toolchain=msvc
run: |
xmake f -c -y --toolchain=msvc --hyperion_enable_tracy=y

- name: Build
env:
Expand All @@ -145,7 +162,7 @@ jobs:
env:
ACTIONS_STEP_DEBUG: true
working-directory: ${{github.workspace}}
run: xmake test
run: xmake test -vD

- name: Extract branch name
shell: bash
Expand All @@ -161,9 +178,11 @@ jobs:
xrepo install -y --toolchain=msvc "hyperion_mpl ${{ steps.extract_branch.outputs.branch }}"
xrepo install -y --toolchain=msvc --configs="hyperion_enable_tracy=true" "hyperion_mpl ${{ steps.extract_branch.outputs.branch }}"

build-macos-xcode-x64:
runs-on: macos-latest
macos-clang-x64:
runs-on: macos-13
strategy:
matrix:
version: [16, 17, 18]
fail-fast: false
steps:
- uses: actions/checkout@v4
Expand All @@ -175,25 +194,30 @@ jobs:
brew install xmake

- name: Install LLVM
run: xrepo install -y llvm
run: |
brew install llvm@${{matrix.version}}
echo "PATH=$(brew --prefix llvm@${{matrix.version}})/bin:$PATH" >> $GITHUB_ENV
echo "CC=$(brew --prefix llvm@${{matrix.version}})/bin/clang" >> $GITHUB_ENV
echo "CXX=$(brew --prefix llvm@${{matrix.version}})/bin/clang++" >> $GITHUB_ENV
echo "LDFLAGS='-L$(brew --prefix llvm@${{matrix.version}})/lib/c++ -Wl,-rpath,$(brew --prefix llvm@${{matrix.version}})/lib/c++'" >> $GITHUB_ENV

- name: Configure
working-directory: ${{github.workspace}}
run: xmake f -c -y --toolchain=xcode
run: xmake f -c -y --toolchain=clang --hyperion_enable_tracy=y

- name: Build
env:
ACTIONS_STEP_DEBUG: true
working-directory: ${{github.workspace}}
run: |
xmake b -y
xmake b
xmake check clang.tidy

- name: Test
env:
ACTIONS_STEP_DEBUG: true
working-directory: ${{github.workspace}}
run: xmake test
run: xmake test -vD

- name: Extract branch name
shell: bash
Expand All @@ -206,5 +230,6 @@ jobs:
run: |
xrepo add-repo -y hyperion "https://github.com/braxtons12/hyperion_packages.git"
xrepo update-repo -y
xrepo install -y --toolchain=xcode "hyperion_mpl ${{ steps.extract_branch.outputs.branch }}"
xrepo install -y --toolchain=xcode --configs="hyperion_enable_tracy=true" "hyperion_mpl ${{ steps.extract_branch.outputs.branch }}"
xrepo install -y --toolchain=clang "hyperion_mpl ${{ steps.extract_branch.outputs.branch }}"
xrepo install -y --toolchain=clang --configs="hyperion_enable_tracy=true" "hyperion_mpl ${{ steps.extract_branch.outputs.branch }}"

2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ endif()
if(${HYPERION_USE_FETCH_CONTENT})
FetchContent_Declare(hyperion_platform
GIT_REPOSITORY "https://github.com/braxtons12/hyperion_platform"
GIT_TAG "v0.3.1"
GIT_TAG "v0.4.1"
)
FetchContent_MakeAvailable(hyperion_platform)
else()
Expand Down
Loading
Loading