Skip to content

Commit

Permalink
ci: Add a clang-ast workflow
Browse files Browse the repository at this point in the history
Signed-off-by: Andrew Clayton <[email protected]>
  • Loading branch information
ac000 committed Oct 25, 2024
1 parent ebd02c6 commit d51aad5
Showing 1 changed file with 50 additions and 0 deletions.
50 changes: 50 additions & 0 deletions .github/workflows/clang-ast.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
name: "Clang AST"

on:
push:
branches: master
paths:
- configure
- 'auto/**'
- 'src/**'
- 'test/**'
- '.github/workflows/clang-ast.yaml'
pull_request:
branches: master
paths:
- configure
- 'auto/**'
- 'src/**'
- 'test/**'
- '.github/workflows/clang-ast.yaml'

jobs:
clang-ast:
runs-on: ubuntu-latest

container:
image: debian:testing

steps:
- name: Install tools/deps
run: |
apt-get -y update
apt-get -y install git llvm-dev libclang-dev clang make \
libssl-dev libpcre2-dev
- uses: actions/checkout@v4

- name: Checkout and build clang-ast
run: |
git clone https://github.com/ac000/clang-ast -b unit-stdc++17
cd clang-ast
make
- name: Configure Unit
run: ./configure --cc=clang --openssl --debug

- name: Build Unit
run: |
make -j4 \
EXTRA_CFLAGS="-Xclang -load -Xclang clang-ast/ngx-ast.so -Xclang -plugin -Xclang ngx-ast" \
NXT_SHARED_LOCAL_LINK=: build/lib/libnxt.so

0 comments on commit d51aad5

Please sign in to comment.