Skip to content

Commit 093785d

Browse files
keenanlangnmarks99
andauthored
Ci scripts (#14). Linux and MacOS only for now
* add scripts * set to most recent official release * add build script and sets * add boost libs (not sure if it will work for windows/mac) * mac should just be boost * windows needs to match msvc * add boost to path on windows * move to after prepare * attempt to bump ur_rtde to latest master Builds after adding include for thread_utility.hpp in Makefile but should be tested to confirm everything works. * try only linking boost_system and boost_thread for linux * forgot to add _Linux in ur_rtde build: * try boost_thread on all platforms * should be able to remove linking boost_system entirely now * comment out windows-2022 from ci build script --------- Co-authored-by: Nick Marks <nmarks@anl.gov>
1 parent 0cdde27 commit 093785d

16 files changed

Lines changed: 450 additions & 31 deletions

File tree

.ci

Submodule .ci added at 261f218

.github/workflows/TIRPC.sh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
#!/bin/bash
2+
set -e
3+
4+
echo "TIRPC=YES" >> ./configure/CONFIG_SITE.local
5+
echo "DRV_VXI11=YES" >> ./configure/CONFIG_SITE.local
Lines changed: 126 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,126 @@
1+
# .github/workflows/ci-scripts-build.yml for use with EPICS Base ci-scripts
2+
# (see: https://github.com/epics-base/ci-scripts)
3+
4+
# This is YAML - indentation levels are crucial
5+
6+
# Set the 'name:' properties to values that work for you (MYMODULE)
7+
8+
name: URROBOT
9+
10+
# Trigger on pushes and PRs to any branch
11+
on:
12+
push:
13+
paths-ignore:
14+
- 'docs/**'
15+
- 'documentation/**'
16+
- '**/*.html'
17+
- '**/*.md'
18+
branches:
19+
- master
20+
pull_request:
21+
22+
env:
23+
SETUP_PATH: .github/workflows:.ci
24+
# For sequencer and asyn
25+
APT: re2c libtirpc-dev libreadline-dev libboost-all-dev
26+
CHOCO: re2c boost-msvc-14.3
27+
BREW: re2c boost
28+
29+
jobs:
30+
build-base:
31+
name: ${{ matrix.name }}
32+
runs-on: ${{ matrix.os }}
33+
# Set environment variables from matrix parameters
34+
env:
35+
CMP: ${{ matrix.cmp }}
36+
BCFG: ${{ matrix.configuration }}
37+
WINE: ${{ matrix.wine }}
38+
RTEMS: ${{ matrix.rtems }}
39+
RTEMS_TARGET: ${{ matrix.rtems_target }}
40+
EXTRA: ${{ matrix.extra }}
41+
TEST: ${{ matrix.test }}
42+
SET: ${{ matrix.set }}
43+
strategy:
44+
fail-fast: false
45+
matrix:
46+
# Job names also name artifacts, character limitations apply
47+
include:
48+
- os: ubuntu-24.04
49+
cmp: gcc
50+
configuration: default
51+
set: linux-stable
52+
base: "7.0"
53+
name: "Linux stable 7.0"
54+
55+
- os: ubuntu-24.04
56+
cmp: gcc
57+
configuration: default
58+
set: linux-stable
59+
base: "3.15"
60+
name: "Linux stable 3.15"
61+
62+
- os: ubuntu-24.04
63+
cmp: gcc
64+
configuration: default
65+
set: linux-master
66+
base: "7.0"
67+
name: "Linux master 7.0"
68+
69+
- os: ubuntu-24.04
70+
cmp: gcc
71+
configuration: default
72+
set: linux-master
73+
base: "3.15"
74+
name: "Linux master 3.15"
75+
76+
- os: macos-latest
77+
cmp: clang
78+
configuration: default
79+
set: macos
80+
name: "MacOS master 7.0"
81+
82+
# - os: windows-2022
83+
# cmp: vs2022
84+
# configuration: static
85+
# set: windows
86+
# name: "Windows master 7.0"
87+
88+
steps:
89+
- uses: actions/checkout@v4
90+
with:
91+
submodules: true
92+
- name: Automatic core dumper analysis
93+
uses: mdavidsaver/ci-core-dumper@master
94+
- name: "apt-get install"
95+
run: |
96+
sudo apt-get update
97+
sudo apt-get -y install qemu-system-x86 g++-mingw-w64-x86-64 gdb
98+
if: runner.os == 'Linux'
99+
- name: "apt-get install ${{ matrix.cmp }}"
100+
run: |
101+
sudo apt-get -y install software-properties-common
102+
sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test
103+
sudo apt-get update
104+
sudo apt-get -y install ${{ matrix.cmp }}
105+
if: matrix.utoolchain
106+
- name: Prepare and compile dependencies
107+
run: python .ci/cue.py prepare
108+
- name: Configure Boost for Windows
109+
if: runner.os == 'Windows'
110+
shell: powershell
111+
run: |
112+
$boostDir = (Get-ChildItem C:\local\boost_* -Directory | Select-Object -First 1).FullName
113+
$boostDirUnix = $boostDir -replace '\\','/'
114+
Add-Content -Path configure/CONFIG_SITE.local -Value "USR_INCLUDES += -I$boostDirUnix"
115+
Add-Content -Path configure/CONFIG_SITE.local -Value "USR_LDFLAGS += -LIBPATH:$boostDirUnix/lib64-msvc-14.3"
116+
- name: Build main module
117+
run: python .ci/cue.py build
118+
- name: Run main module tests
119+
run: python .ci/cue.py -T 15M test
120+
- name: Upload tapfiles Artifact
121+
uses: actions/upload-artifact@v4
122+
with:
123+
name: tapfiles ${{ matrix.name }}
124+
path: '**/O.*/*.tap'
125+
- name: Collect and show test results
126+
run: python .ci/cue.py test-results

.github/workflows/linux-master.set

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
include master
2+
3+
ASYN_HOOK=.github/workflows/TIRPC.sh

.github/workflows/linux-stable.set

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
include stable
2+
3+
ASYN_HOOK=.github/workflows/TIRPC.sh

.github/workflows/macos.set

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
include master

.github/workflows/master.set

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
MODULES="asyn"
2+
3+
ASYN="master"

.github/workflows/stable.set

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
MODULES="asyn"
2+
3+
ASYN="R4-42"

.github/workflows/windows.set

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
include master

.gitmodules

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,6 @@
77
[submodule "urRobotApp/src/spdlog"]
88
path = urRobotApp/src/spdlog
99
url = https://github.com/gabime/spdlog.git
10+
[submodule ".ci"]
11+
path = .ci
12+
url = https://github.com/epics-base/ci-scripts

0 commit comments

Comments
 (0)