-
Notifications
You must be signed in to change notification settings - Fork 0
155 lines (115 loc) · 5.75 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
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
name: 🚀 deploy
on:
workflow_dispatch:
push:
branches:
- main
pull_request:
schedule:
- cron: '0 12 * * 0'
jobs:
build_ubuntu:
strategy:
fail-fast: false
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v2
with:
submodules: true
fetch-depth: 0
- name: Install GCC, clang tidy, and build essentials
run: sudo apt update && sudo apt upgrade; sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test; sudo apt install -y build-essential g++-11 clang-tidy
- name: 📥 Install CMake & Conan
run: python3 -m pip install "conan>=2.0.13" cmake
- name: 📡 Add `libhal-trunk` conan remote
run: conan remote add libhal-trunk https://libhal.jfrog.io/artifactory/api/conan/trunk-conan
- name: Setting up conan profile
run: conan config install -sf profiles/baremetal https://github.com/libhal/conan-config.git; conan profile detect --force; conan config install -sf profiles/x86_64/linux/ -tf profiles https://github.com/libhal/conan-config.git;
- name: Get conan profiles
run: conan config install -sf conan/profiles/ -tf profiles https://github.com/libhal/libhal-armcortex.git; conan config install -sf conan/profiles/ -tf profiles https://github.com/libhal/libhal-lpc40.git
- name: Build drive
working-directory: drive
run: conan build . -pr lpc4078 -s build_type=MinSizeRel
- name: Build arm
working-directory: arm
run: conan build . -pr lpc4078 -s build_type=MinSizeRel
- name: Build arm-mimic
working-directory: arm_mimic
run: conan build . -pr lpc4078 -s build_type=MinSizeRel
- name: Build science
working-directory: science
run: conan build . -pr lpc4078 -s build_type=MinSizeRel
build_windows:
strategy:
fail-fast: false
runs-on: windows-2022
steps:
- uses: actions/checkout@v2
with:
submodules: true
fetch-depth: 0
- name: Installing choco
run: Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://community.chocolatey.org/install.ps1'))
- name: Installing python
run: choco install python
- name: Installing gcc
run: choco install mingw
- name: installing make
run: choco install make
- name: Installing conan and cmake
run: python3 -m pip install -U "conan>=2.0.13" cmake
- name: setting up conan
run: conan remote add libhal-trunk https://libhal.jfrog.io/artifactory/api/conan/trunk-conan; conan config install -sf profiles/baremetal https://github.com/libhal/conan-config.git; conan profile detect --force; conan config install -sf profiles/x86_64/windows/ -tf profiles https://github.com/libhal/conan-config.git
- name: Importing lpc profiles
run: conan config install -sf conan/profiles/ -tf profiles https://github.com/libhal/libhal-armcortex.git; conan config install -sf conan/profiles/ -tf profiles https://github.com/libhal/libhal-lpc40.git
- name: Build drive
working-directory: drive
run: conan build . -pr lpc4078 -s build_type=MinSizeRel
- name: Build arm
working-directory: arm
run: conan build . -pr lpc4078 -s build_type=MinSizeRel
- name: Build arm-mimic
working-directory: arm_mimic
run: conan build . -pr lpc4078 -s build_type=MinSizeRel
- name: Build science
working-directory: science
run: conan build . -pr lpc4078 -s build_type=MinSizeRel
build_mac_intel:
strategy:
fail-fast: false
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
with:
submodules: true
fetch-depth: 0
- name: Install Homebrew
run: /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
- name: Troubleshooting
run: rm '/usr/local/bin/2to3'
- name: Install latest version of Python 3.x and llvm
run: brew install [email protected]; brew install llvm
- name: Make clang-tidy available on the command line
run: sudo ln -s $(brew --prefix llvm)/bin/clang-tidy /usr/local/bin/
- name: 📥 Install CMake & Conan
run: python3 -m pip install "conan>=2.0.13" cmake
- name: 📡 Add `libhal-trunk` conan remote
run: conan remote add libhal-trunk https://libhal.jfrog.io/artifactory/api/conan/trunk-conan
- name: Setting up conan profile
run: conan config install -sf profiles/baremetal https://github.com/libhal/conan-config.git; conan profile detect --force; conan config install -sf profiles/x86_64/linux/ -tf profiles https://github.com/libhal/conan-config.git;
- name: Get conan profiles
run: conan config install -sf conan/profiles/ -tf profiles https://github.com/libhal/libhal-armcortex.git; conan config install -sf conan/profiles/ -tf profiles https://github.com/libhal/libhal-lpc40.git
- name: Intel default configuration
run: conan config install -sf profiles/x86_64/mac/ -tf profiles https://github.com/libhal/conan-config.git
- name: Build drive
working-directory: drive
run: conan build . -pr lpc4078 -s build_type=MinSizeRel
- name: Build arm
working-directory: arm
run: conan build . -pr lpc4078 -s build_type=MinSizeRel
- name: Build arm-mimic
working-directory: arm_mimic
run: conan build . -pr lpc4078 -s build_type=MinSizeRel
- name: Build science
working-directory: science
run: conan build . -pr lpc4078 -s build_type=MinSizeRel