-
-
Notifications
You must be signed in to change notification settings - Fork 4
77 lines (64 loc) · 2.22 KB
/
build.yaml
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
name: Lint & Build
on:
push:
branches:
- main
pull_request:
branches:
- main
env:
NDK_VERSION: 25.2.9519653
jobs:
lint-build:
runs-on: ubuntu-22.04
steps:
- name: Clone Oculus OpenXR SDK
uses: actions/checkout@v2
with:
repository: zwin-project/oculus-openxr-mobile-sdk
path: ovr_openxr_mobile_sdk
- name: Install dependencies
run: |
sudo apt-get update
sudo apt-get install meson
- name: Clone grpc-dev
uses: actions/checkout@v2
with:
repository: zwin-project/grpc-dev
path: grpc-dev
submodules: recursive
ref: "v1.49.1"
- name: Build grpc-dev
working-directory: ./grpc-dev
run: |
echo "ndk_version := $NDK_VERSION" > local.mk
echo "ndk_dir := /usr/local/lib/android/sdk/ndk/$NDK_VERSION" >> local.mk
make android
- name: Checkout
uses: actions/checkout@v2
with:
path: main
submodules: recursive
- name: ClangFormat Check
working-directory: ./main
run: find . -regex "^\.\/app/src/main/cpp/.*\.\(h\|cpp\)" | xargs clang-format-14 --dry-run -Werror
- name: Gradle build
working-directory: ./main
run: |
echo "ovr_openxr_mobile_sdk.dir=$GITHUB_WORKSPACE/ovr_openxr_mobile_sdk" > local.properties
echo "ndk.version = $NDK_VERSION" >> local.properties
echo "protoc = $GITHUB_WORKSPACE/grpc-dev/native/Debug/bin/protoc" >> local.properties
echo "grpc_cpp_plugin = $GITHUB_WORKSPACE/grpc-dev/native/Debug/bin/grpc_cpp_plugin" >> local.properties
echo "grpc_sysroot = $GITHUB_WORKSPACE/grpc-dev/android/24/arm64-v8a/$NDK_VERSION/Debug" >> local.properties
echo "cmake.dir = $ANDROID_SDK_ROOT/cmake/3.22.1" >> local.properties
./gradlew build
- name: Upload results Artifact
uses: actions/upload-artifact@v2
if: success() || failure()
with:
name: results
path: |
**/build/reports/lint-results-*.html
**/build/reports/lint-results-*.xml
if-no-files-found: error
retention-days: 14