|
6 | 6 |
|
7 | 7 | jobs: |
8 | 8 | POSIX-Build: |
9 | | - runs-on: ${{ matrix.config.os }} |
10 | | - name: ${{ matrix.config.name }} |
11 | | - strategy: |
12 | | - fail-fast: false |
13 | | - matrix: |
14 | | - config: |
15 | | - - { name: 'Linux', os: 'ubuntu-latest', setup: '.ci/setup-ubuntu.sh' } |
16 | | - - { name: 'macOS', os: 'macos-latest', setup: '.ci/setup-macos.sh' } |
17 | | - steps: |
18 | | - - name: Checkout |
19 | | - uses: actions/checkout@v4 |
20 | | - with: |
21 | | - path: target |
22 | | - - name: Install dependencies |
23 | | - run: | |
24 | | - bash "target/${{ matrix.config.setup }}" "sudo" |
25 | | - mkdir current_sagittarius |
26 | | - - name: Install current sagittarius |
27 | | - working-directory: current_sagittarius |
28 | | - run: | |
29 | | - bash ../target/.ci/build-current.sh 'yes' |
30 | | - - name: Pre-build |
31 | | - working-directory: target |
32 | | - run: | |
33 | | - ./dist.sh gen |
34 | | - cmake . |
35 | | - - name: Build |
36 | | - working-directory: target |
37 | | - run: make |
38 | | - - name: Test |
39 | | - working-directory: target |
40 | | - run: ctest --output-on-failure -j8 |
| 9 | + uses: ./.github/workflows/posix-build.yml |
41 | 10 |
|
42 | 11 | VMActions-Build: |
43 | 12 | needs: POSIX-Build |
44 | | - runs-on: ubuntu-latest |
45 | | - name: ${{ matrix.config.name }} - ${{ matrix.arch }} |
46 | | - strategy: |
47 | | - fail-fast: false |
48 | | - matrix: |
49 | | - arch: |
50 | | - - x86_64 |
51 | | - # - aarch64 |
52 | | - config: |
53 | | - - { name: 'freebsd', setup: '.ci/setup-freebsd.sh' } |
54 | | - - { name: 'openbsd', setup: '.ci/setup-openbsd.sh' } |
55 | | - steps: |
56 | | - - uses: actions/checkout@v4 |
57 | | - - name: Setup VM |
58 | | - uses: jenseng/dynamic-uses@v1 |
59 | | - with: |
60 | | - uses: vmactions/${{ matrix.config.name }}-vm@v1 |
61 | | - with: | |
62 | | - { |
63 | | - "arch": ${{ toJSON(matrix.arch) }}, |
64 | | - "sync": "nfs" |
65 | | - } |
66 | | - - name: Install dependencies / current |
67 | | - uses: ktakashi/dynamic-shell@v1 |
68 | | - with: |
69 | | - shell: "${{ matrix.config.name }} {0}" |
70 | | - run: | |
71 | | - cd $GITHUB_WORKSPACE; |
72 | | - sh "./${{ matrix.config.setup }}" |
73 | | - bash "./.ci/build-current.sh" |
74 | | - - name: Pre-build |
75 | | - uses: ktakashi/dynamic-shell@v1 |
76 | | - with: |
77 | | - shell: "${{ matrix.config.name }} {0}" |
78 | | - run: | |
79 | | - cd $GITHUB_WORKSPACE; |
80 | | - ./dist.sh gen |
81 | | - cmake . |
82 | | - - name: Build |
83 | | - uses: ktakashi/dynamic-shell@v1 |
84 | | - with: |
85 | | - shell: "${{ matrix.config.name }} {0}" |
86 | | - run: | |
87 | | - cd $GITHUB_WORKSPACE; |
88 | | - make |
89 | | - - name: Test |
90 | | - uses: ktakashi/dynamic-shell@v1 |
91 | | - with: |
92 | | - shell: "${{ matrix.config.name }} {0}" |
93 | | - run: | |
94 | | - cd $GITHUB_WORKSPACE; |
95 | | - ctest --output-on-failure -j2 |
96 | | - |
| 13 | + uses: ./.github/workflows/vmactions-build.yml |
| 14 | + |
97 | 15 | Windows-Build: |
98 | | - runs-on: ${{ matrix.images }} |
99 | | - name: ${{ matrix.images }} - ${{ matrix.arch }} |
100 | | - strategy: |
101 | | - fail-fast: false |
102 | | - matrix: |
103 | | - arch: [x64, x86] |
104 | | - images: [windows-2022, windows-2025] |
105 | | - steps: |
106 | | - - name: Checkout |
107 | | - uses: actions/checkout@v4 |
108 | | - with: |
109 | | - path: target |
110 | | - - name: Install current sagittarius |
111 | | - working-directory: target |
112 | | - run: | |
113 | | - .\.ci\install-current.ps1 |
114 | | - shell: powershell |
115 | | - - name: Setup MSVC |
116 | | - uses: TheMrMilchmann/setup-msvc-dev@v3 |
117 | | - with: |
118 | | - arch: ${{ matrix.arch }} |
119 | | - - name: Pre build |
120 | | - working-directory: target |
121 | | - run: dist.bat gen |
122 | | - shell: cmd |
123 | | - - name: CMake |
124 | | - working-directory: target |
125 | | - run: cmake . -G "Ninja" -DSKIP_TEST_VECTOR=ON |
126 | | - shell: cmd |
127 | | - - name: Build |
128 | | - working-directory: target |
129 | | - run: ninja |
130 | | - shell: cmd |
131 | | - - name: Test |
132 | | - working-directory: target |
133 | | - run: ctest --output-on-failure -LE json |
134 | | - shell: cmd |
| 16 | + uses: ./.github/workflows/windows-build.yml |
135 | 17 |
|
136 | 18 | Create-Artifact: |
137 | 19 | needs: [POSIX-Build, Windows-Build] |
|
147 | 29 | artifact-id: ${{ needs.Create-Artifact.outputs.artifact-id }} |
148 | 30 | tar-file: ${{ needs.Create-Artifact.outputs.tar-file }} |
149 | 31 | suffix: ${{ github.run_id }} |
150 | | - |
0 commit comments