forked from bergzand/libcose
-
Notifications
You must be signed in to change notification settings - Fork 0
75 lines (66 loc) · 2.19 KB
/
build.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
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
name: build
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
container:
- silkeh/clang:12
- silkeh/clang:13
- gcc:10
- gcc:11
crypto:
- sodium
- monocypher
- tinycrypt
- mbedtls
- c25519
include:
- crypto: sodium
crypto_script: true
- crypto: monocypher
crypto_script: >-
git clone https://github.com/LoupVaillant/Monocypher.git ../Monocypher &&
bash -c "cd ../Monocypher && make -j USE_ED25519=1"
- crypto: tinycrypt
crypto_script: >-
git clone https://github.com/intel/tinycrypt ../tinycrypt &&
bash -c 'cd ../tinycrypt && make -j all'
- crypto: mbedtls
crypto_script: true
- crypto: c25519
crypto_script: >-
apt install -y unzip &&
wget https://www.dlbeer.co.nz/downloads/c25519-2017-10-05.zip -O ../c25519.zip &&
bash -c 'cd .. && unzip c25519.zip'
- container: silkeh/clang:12
CC: clang
- container: silkeh/clang:13
CC: clang
- container: gcc:10
CC: gcc
- container: gcc:11
CC: gcc
container: ${{ matrix.container }}
env:
CRYPTO: ${{ matrix.crypto }}
CC: ${{ matrix.CC }}
MBEDTLS_LIB: /usr/lib/x86_64-linux-gnu/libmbedcrypto.so
MONOCYPHER_LOCAL: 1
steps:
- uses: actions/checkout@v2
- name: install packages
run: apt update && apt install -y build-essential pkg-config libcunit1-dev wget libsodium-dev libmbedtls-dev ca-certificates meson ninja-build
- name: clone nanocbor
run: git clone https://github.com/bergzand/nanocbor/ ../nanocbor
- name: build nanocbor
run: cd ../nanocbor && mkdir bin && meson . build && ninja -C build && mv build/libnanocbor.so bin/libnanocbor.so
- name: ${{ matrix.crypto }} setup script
run: ${{ matrix.crypto_script }}
- name: build & test libcose with ${{ matrix.crypto }}
run: make clean test