-
Notifications
You must be signed in to change notification settings - Fork 32
120 lines (117 loc) · 3.15 KB
/
cmake-cross-mingw.yml
File metadata and controls
120 lines (117 loc) · 3.15 KB
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
name: cmake-cross-mingw
on:
push:
branches: [
"master",
"devel",
"citest",
"citest-cmake",
"citest-cmake-cross-mingw" ]
tags:
- '**'
pull_request:
branches: [ "master", "devel" ]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
# build_type: [ x86_64, i686 ]
build_type: [ x86_64 ]
steps:
- uses: actions/checkout@v4
- name: install prereq.
run: |
sudo apt-get update
sudo apt-get install -y check gcc-mingw-w64-x86-64-win32
- name: cmake_shared_configure
run: |
CC=${{ matrix.build_type }}-w64-mingw32-gcc \
util/cmake_shared_configure \
-DADFLIB_ENABLE_TESTS=OFF
- name: cmake_shared_build
run: util/cmake_shared_build
# - name: cmake_shared_test
# run: util/cmake_shared_test
# - name: cmake_shared_install
# run: sudo bash util/cmake_shared_install
# - name: check installation
# run: find /usr/local -iname '*adf*'
# - name: update ldconfig
# run: sudo ldconfig
# - name: test command-line utils
# run: ./tests/examples/test_all_examples.sh /usr/local/bin
- name: check build output files
run: find build/
- name: prepare artifact
run: |
mkdir -vp bin
cp -v build/shared/src/libadf* bin/
cp -v build/shared/examples/*.exe bin/
mkdir -v include
cp -vR src/*.h include
- uses: actions/upload-artifact@v4
with:
# name: adflib-${{ env.ADFLIB_TAG }}-mingw
name: adflib-mingw-${{ matrix.build_type }}
path: |
AUTHORS
BUGS.md
ChangeLog
COPYING*
NOTES.md
README.md
TODO
bin
doc
include
test:
needs: build
runs-on: windows-latest
strategy:
matrix:
# build_type: [ x86_64, i686 ]
build_type: [ x86_64 ]
steps:
- uses: actions/checkout@v4
- name: install prereq.
run: |
choco install diffutils
cmp --version
- uses: actions/download-artifact@v4
with:
# name: adflib-${{ env.ADFLIB_TAG }}-mingw
name: adflib-mingw-${{ matrix.build_type }}
path: .
- name: list files extracted from the artifact
shell: bash
run: |
find bin/
find include/
- name: show properties of binaries
shell: bash
run: ldd bin/unadf
- name: configure tests
shell: bash
run: |
cat tests/config.sh.in_cmake | \
sed -e 's@\${PROJECT_BINARY_DIR}@./bin/@' \
-e 's@\${PROJECT_SOURCE_DIR}@./@' \
> tests/config.sh
cat tests/config.sh
- name: test command-line utils
shell: bash
run: |
tests/examples/test_examples_basic.sh bin/
tests/examples/test_all_examples.sh bin/
- name: test installed command-line utils (2)
shell: bash
run: |
./tests/examples2/run_all_tests.sh bin
- name: store logs from failed tests
if: failure()
uses: actions/upload-artifact@v4
with:
name: cmake_cross_mingw_${{ matrix.build_type }}_logs_failed_tests
path: |
cmake/shared/Testing/