-
Notifications
You must be signed in to change notification settings - Fork 1
112 lines (97 loc) · 3.35 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
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
name: build
on:
workflow_dispatch:
jobs:
build:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
permissions:
contents: write
steps:
- uses: actions/checkout@v4
# - uses: actions/checkout@v4
# with:
# repository: ogdf/ogdf
# path: ogdf
- uses: actions/checkout@v4
with:
repository: f-kretschmer/tmap
path: tmap
- name: setup msys2
uses: msys2/setup-msys2@v2
if: ${{ matrix.os == 'windows-latest' }}
with:
update: true
install: >-
base-devel
mingw-w64-x86_64-toolchain
mingw-w64-x86_64-cmake
git zip wget unzip
- name: get OGDF + TMAP binaries
if: ${{ matrix.os == 'ubuntu-latest' || matrix.os == 'macos-latest' }}
run: |
wget https://github.com/f-kretschmer/tmap/releases/download/0.1/binaries-${{ runner.os }}.zip
unzip -j binaries-${{ runner.os }}.zip -d binaries
mkdir tmap/out
mv binaries/*tmap* tmap/out/ # TMAP library
mv binaries/* tmap/ogdf-conda/src/ # OGDF+COIN libraries
- name: get OGDF + TMAP binaries (windows)
if: ${{ matrix.os == 'windows-latest' }}
shell: msys2 {0}
run: |
wget https://github.com/f-kretschmer/tmap/releases/download/0.1/binaries-${{ runner.os }}.zip
unzip -j binaries-${{ runner.os }}.zip -d binaries
mkdir tmap/out
mv binaries/*tmap* tmap/out/ # TMAP library
mv binaries/* tmap/ogdf-conda/src/ # OGDF+COIN libraries
- name: create missing OGDF header file by running cmake
if: ${{ matrix.os == 'ubuntu-latest' || matrix.os == 'macos-latest' }}
run: |
cd tmap/ogdf-conda/src
cmake -DBUILD_SHARED_LIBS=ON .
- name: create missing OGDF header file by running cmake (windows)
if: ${{ matrix.os == 'windows-latest' }}
shell: msys2 {0}
run: |
cd tmap/ogdf-conda/src
cmake -DBUILD_SHARED_LIBS=ON -G "Visual Studio 17 2022" -A x64 -T ClangCL .
- name: build test
if: ${{ matrix.os == 'ubuntu-latest' || matrix.os == 'macos-latest' }}
run: |
mkdir build
cd build
cmake ..
make
- name: build test (windows)
if: ${{ matrix.os == 'windows-latest' }}
shell: msys2 {0}
run: |
mkdir build
cd build
cmake -G "MSYS Makefiles" ..
make
- name: test
run: |
cd build
LD_LIBRARY_PATH=../tmap/ogdf-conda/src ./LayoutFromEdgeList_test
ldd *.so ||:
ldd *.dylib ||:
- name: make zip of binaries
if: ${{ matrix.os == 'ubuntu-latest' || matrix.os == 'macos-latest' }}
run: |
zip -j tmapogdfwrapper-${{ runner.os }}.zip build/*Layout*
- name: make zip of binaries
if: ${{ matrix.os == 'windows-latest' }}
shell: msys2 {0}
run: |
zip -j tmapogdfwrapper-${{ runner.os }}.zip build/*Layout*
- uses: softprops/action-gh-release@v1
with:
files: "*.zip"
tag_name: "0.1"
- name: Debug with tmate on failure
if: ${{ failure()}}
uses: mxschmitt/action-tmate@v3