-
Notifications
You must be signed in to change notification settings - Fork 1
126 lines (123 loc) · 3.67 KB
/
main.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
name: build and run tests
on:
workflow_dispatch
jobs:
build-release-linux-i686-amd64:
name: GLPK master linux/amd64
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v2
- name: Install depedencies
run: sudo apt-get install -y
gcc-8-i686-linux-gnu
g++-8-i686-linux-gnu
# see what's available in /usr/bin
- name: see what's available
run: ls -l /usr/bin
# build project amd64
- name: build amd64
run: |
CFLAGS="-pipe -O3 -DWITH_SPLAYTREE -DNDEBUG -flto" ./configure --disable-shared
make
cp examples/glpsol glpsol-linux-amd64
# run tests
- name: run examples amd64
run: |
cd examples
./test-all.sh
cd ..
# upload artifact, glpsol binary
- name: Upload glpk-linux-amd64 binary
uses: actions/upload-artifact@v1
with:
name: download glpsol-linux-amd64
path: glpsol-linux-amd64
# build project i686
- name: build i686
run: |
make clean
CC=i686-linux-gnu-gcc-8 CFLAGS="-pipe -O3 -DWITH_SPLAYTREE -DNDEBUG -flto" ./configure --disable-shared
make
cp examples/glpsol glpsol-linux-i686
# run tests
- name: run examples i686
run: |
cd examples
./test-all.sh
cd ..
# upload artifact, glpsol binary
- name: Upload glpk-linux-i686 binary
uses: actions/upload-artifact@v1
with:
name: download glpsol-linux-i686
path: glpsol-linux-i686
build-release-osx-amd64:
name: GLPK master osx/amd64
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
# see what's available in /usr/bin
- name: see what's available
run: ls -l /usr/bin
# build project amd64
- name: build amd64
run: |
CFLAGS="-pipe -O3 -DWITH_SPLAYTREE -DNDEBUG" ./configure --disable-shared
make
cp examples/glpsol glpsol-osx-amd64
# run tests
- name: run examples amd64
run: |
cd examples
./test-all.sh
cd ..
# upload artifact, glpsol binary
- name: Upload glpsol-osx-amd64 binary
uses: actions/upload-artifact@v1
with:
name: download glpsol-osx-amd64
path: glpsol-osx-amd64
build-release-windows-i686-amd64:
name: GLPK master windows/amd64
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install depedencies
run: sudo apt-get install -y
mingw-w64
libz-mingw-w64-dev
wine64
# see what's available in /usr/bin
- name: see what's available
run: ls -l /usr/bin
# build project amd64
- name: build amd64
run: |
CFLAGS="-pipe -O3 -DWITH_SPLAYTREE -DNDEBUG -flto -D__WOE__" ./configure --disable-shared --host=x86_64-w64-mingw32
make
cp examples/glpsol.exe glpsol-windows-amd64.exe
# run tests
- name: run test_exs amd64
run: |
cd examples
GLPSOL_CMD='wine64 ./glpsol.exe' ./test-all.sh
cd ..
# upload artifact, glpsol binary
- name: Upload glpsol-windows-amd64 binary
uses: actions/upload-artifact@v1
with:
name: download glpsol-windows-amd64.exe
path: glpsol-windows-amd64.exe
# build project i686
- name: build i686
run: |
make clean
CFLAGS="-m32 -pipe -O3 -DWITH_SPLAYTREE -DNDEBUG -flto -D__WOE__" ./configure --disable-shared --host=i686-w64-mingw32
make
cp examples/glpsol.exe glpsol-windows-i686.exe
# upload artifact, glpsol binary
- name: Upload glpsol-windows-i686 binary
uses: actions/upload-artifact@v1
with:
name: download glpsol-windows-i686.exe
path: glpsol-windows-i686.exe