Skip to content

Commit

Permalink
Build host-only libshortfin in CI
Browse files Browse the repository at this point in the history
  • Loading branch information
marbre committed Aug 22, 2024
1 parent d6818b1 commit aa2c186
Showing 1 changed file with 20 additions and 6 deletions.
26 changes: 20 additions & 6 deletions .github/workflows/ci_linux_x64-libshortfin.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ permissions:

env:
IREE_REPO_DIR: ${{ github.workspace }}/iree
BUILD_DIR: ${{ github.workspace }}/libshortfin/build
LIBSHORTFIN_DIR: ${{ github.workspace }}/libshortfin/

jobs:
build-and-test:
Expand Down Expand Up @@ -86,10 +86,10 @@ jobs:
# TODO: Switch to `pip install -r requirements.txt -e libshortfin/`.
run: pip install nanobind typing_extensions

- name: Build libshortfin
- name: Build libshortfin (full)
run: |
mkdir ${{ env.BUILD_DIR }}
cd ${{ env.BUILD_DIR }}
mkdir ${{ env.LIBSHORTFIN_DIR }}/build
cd ${{ env.LIBSHORTFIN_DIR }}/build
cmake -GNinja \
-DCMAKE_C_COMPILER=clang-18 \
-DCMAKE_CXX_COMPILER=clang++-18 \
Expand All @@ -99,7 +99,21 @@ jobs:
..
cmake --build . --target all

- name: Test libshortfin
- name: Test libshortfin (full)
run: |
cd ${{ env.BUILD_DIR }}
cd ${{ env.LIBSHORTFIN_DIR }}/build
cmake --build . --target test

- name: Build libshortfin (host-only)
run: |
mkdir ${{ env.LIBSHORTFIN_DIR }}/build-host-only
cd ${{ env.LIBSHORTFIN_DIR }}/build-host-only
cmake -GNinja \
-DCMAKE_C_COMPILER=clang-18 \
-DCMAKE_CXX_COMPILER=clang++-18 \
-DCMAKE_LINKER_TYPE=LLD \
-DCMAKE_PREFIX_PATH=${{ env.IREE_REPO_DIR }}/build/lib/cmake/IREE \
-DSHORTFIN_BUILD_PYTHON_BINDINGS=ON \
-DSHORTFIN_HAVE_AMDGPU=OFF \
..
cmake --build . --target all

0 comments on commit aa2c186

Please sign in to comment.