-
Notifications
You must be signed in to change notification settings - Fork 34
49 lines (40 loc) · 1.48 KB
/
docs.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
# Simple workflow for building documentation for PR testing
name: Build documentation
# On a pull request this will build the html documentation
# and create an artifact. It does this by using the cmake
# build target doc_html. Note that this requires installing a little
# more than is technically required for building the documentation in
# order to satisfy our current cmake configurations e.g. spirv-tools
on:
pull_request:
paths:
- doc/**
- .github/workflows/docs.yml
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
permissions: {}
jobs:
# Build job
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: 3.9
- name: Install apt package
run: |
sudo apt-get update
sudo apt-get install -y doxygen virtualenv
- name: Install prerequisites
run: python -m pip install -r doc/requirements.txt
- name: Build Documentation
working-directory: ${{github.workspace}}
run: |
cmake -DCA_ENABLE_API=cl -DCMAKE_BUILD_TYPE=Debug -DCA_RUNTIME_COMPILER_ENABLED=OFF -DCA_CL_ENABLE_OFFLINE_KERNEL_TESTS=OFF -DOCL_EXTENSION_cl_khr_il_program=OFF -Bbuild_doc
cmake --build build_doc --target doc_html
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: ${{github.workspace}}/build_doc/doc/html