-
Notifications
You must be signed in to change notification settings - Fork 174
131 lines (113 loc) · 3.82 KB
/
build-macos.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
name: Build macOS
on:
push:
pull_request:
branches:
- master
jobs:
build-macos:
runs-on: macos-latest
steps:
- name: Downgrade Python version
uses: actions/setup-python@v4
id: cp39
with:
python-version: '3.9'
- name: Install Qt
uses: jurplel/install-qt-action@v3
with:
setup-python: false
version: '5.15.2'
target: 'desktop'
- name: Install Dependencies
run: brew install ninja doxygen graphviz protobuf@21 hdf5 pkg-config
- name: Install Cap’n Proto
run: |
mkdir "${{ runner.workspace }}/capnp"
cd "${{ runner.workspace }}/capnp"
curl -O https://capnproto.org/capnproto-c++-0.9.0.tar.gz
tar zxf capnproto-c++-0.9.0.tar.gz
cd capnproto-c++-0.9.0
./configure
make -j
sudo make install
- name: Checkout
uses: actions/checkout@v3
with:
submodules: 'true'
fetch-depth: 0
- name: Display Python version
run: python -c "import sys; print(sys.version)"
- name: Install Python requirements
run: |
sudo pip3 install -r "$GITHUB_WORKSPACE/doc/requirements.txt"
- name: CMake
run: |
mkdir "${{ runner.workspace }}/_build"
cd "${{ runner.workspace }}/_build"
cmake $GITHUB_WORKSPACE -G "Ninja" \
-DHAS_HDF5=ON \
-DHAS_QT5=ON \
-DHAS_CURL=ON \
-DHAS_CAPNPROTO=ON \
-DHAS_FTXUI=ON \
-DBUILD_DOCS=ON \
-DBUILD_APPS=ON \
-DBUILD_SAMPLES=ON \
-DBUILD_TIME=ON \
-DBUILD_PY_BINDING=ON \
-DBUILD_CSHARP_BINDING=OFF \
-DBUILD_ECAL_TESTS=ON \
-DECAL_INCLUDE_PY_SAMPLES=OFF \
-DECAL_INSTALL_SAMPLE_SOURCES=ON \
-DECAL_JOIN_MULTICAST_TWICE=OFF \
-DECAL_NPCAP_SUPPORT=OFF \
-DECAL_THIRDPARTY_BUILD_CMAKE_FUNCTIONS=ON \
-DECAL_THIRDPARTY_BUILD_PROTOBUF=OFF \
-DECAL_THIRDPARTY_BUILD_SPDLOG=ON \
-DECAL_THIRDPARTY_BUILD_TINYXML2=ON \
-DECAL_THIRDPARTY_BUILD_FINEFTP=ON \
-DECAL_THIRDPARTY_BUILD_CURL=OFF \
-DECAL_THIRDPARTY_BUILD_GTEST=ON \
-DECAL_THIRDPARTY_BUILD_HDF5=OFF \
-DECAL_THIRDPARTY_BUILD_RECYCLE=ON \
-DECAL_THIRDPARTY_BUILD_TCP_PUBSUB=ON \
-DECAL_THIRDPARTY_BUILD_QWT=ON \
-DECAL_THIRDPARTY_BUILD_YAML-CPP=ON \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_PREFIX_PATH=/usr/local/opt/protobuf@21 \
-DCMAKE_CXX_STANDARD=14 \
-DPython_FIND_STRATEGY=LOCATION \
-DPython_FIND_REGISTRY=NEVER
sudo mkdir /etc/ecal
sudo cp "$GITHUB_WORKSPACE/ecal/core/cfg/ecal.ini" /etc/ecal
shell: bash
- name: Build Release
run: cmake --build . --config Release
working-directory: ${{ runner.workspace }}/_build
- name: Build Python Wheel
run: cmake --build . --target create_python_wheel --config Release
working-directory: ${{ runner.workspace }}/_build
# - name: Build Documentation C
# run: cmake --build . --target documentation_c
# working-directory: ${{ runner.workspace }}/_build
# - name: Build Documentation C++
# run: cmake --build . --target documentation_cpp
# working-directory: ${{ runner.workspace }}/_build
# currently event test fails under macos ..
# - name: Run Tests
# run: ctest -V
# working-directory: ${{ runner.workspace }}/_build
- name: Pack
run: cpack -G DragNDrop
working-directory: ${{ runner.workspace }}/_build
- name: Upload DMG
uses: actions/upload-artifact@v3
with:
name: macos-dmg
path: ${{ runner.workspace }}/_build/_deploy/*.dmg
- name: Upload Python Wheel
uses: actions/upload-artifact@v3
with:
name: macos-python-wheel
path: ${{ runner.workspace }}/_build/_deploy/*.whl