Skip to content

Commit 1be860a

Browse files
committed
build.yml
1 parent 55dcc25 commit 1be860a

File tree

1 file changed

+19
-218
lines changed

1 file changed

+19
-218
lines changed

.github/workflows/build.yml

Lines changed: 19 additions & 218 deletions
Original file line numberDiff line numberDiff line change
@@ -5,22 +5,28 @@ jobs:
55
build-linux:
66
strategy:
77
matrix:
8-
compiler: [gcc, clang]
9-
arch: [i386, amd64]
10-
config: [Debug, Release]
8+
compiler: [gcc]
9+
arch: [i386]
10+
config: [Debug]
11+
dllver: ['0x502']
12+
exclude:
13+
- dllver: 0x600
14+
compiler: clang
15+
- dllver: 0x600
16+
config: Release
1117
fail-fast: false
1218
runs-on: ubuntu-latest
1319
steps:
1420
- name: Get RosBE build specifics
1521
id: get_rosbe_spec
1622
run: |
1723
gcc -march=native -Q --help=target | grep "\-march= " | awk '{print $NF}'
18-
echo ::set-output name=march-sha::$(gcc -march=native -Q --help=target | sha1sum | awk '{print $1}')
19-
echo ::set-output name=git-sha::$(git ls-remote https://github.com/zefklop/RosBE.git | grep unix_amd64 | awk '{print $1}')
24+
echo march-sha=$(gcc -march=native -Q --help=target | sha1sum | awk '{print $1}') >> $GITHUB_OUTPUT
25+
echo git-sha=$(git ls-remote https://github.com/zefklop/RosBE.git | grep unix_amd64 | awk '{print $1}') >> $GITHUB_OUTPUT
2026
wget https://gist.githubusercontent.com/zefklop/b2d6a0b470c70183e93d5285a03f5899/raw/build_rosbe_ci.sh
2127
- name: Get RosBE
2228
id: get_rosbe
23-
uses: actions/cache@v2
29+
uses: actions/cache@v4
2430
with:
2531
path: RosBE-CI
2632
key: RosBE-CI-${{runner.os}}-${{steps.get_rosbe_spec.outputs.march-sha}}-${{steps.get_rosbe_spec.outputs.git-sha}}-${{hashfiles('./build_rosbe_ci.sh')}}
@@ -40,16 +46,16 @@ jobs:
4046
sudo ./llvm.sh $LLVM_VERSION
4147
echo "D_CLANG_VERSION=-DCLANG_VERSION=$LLVM_VERSION" >> $GITHUB_ENV
4248
- name: Source checkout
43-
uses: actions/checkout@v2
49+
uses: actions/checkout@v4
4450
with:
4551
path: src
4652
- name: Set up cache for ccache
47-
uses: actions/cache@v2
53+
uses: actions/cache@v4
4854
with:
4955
path: ccache
50-
key: ccache-${{matrix.compiler}}-${{matrix.arch}}-${{matrix.config}}-${{github.sha}}
56+
key: ccache-${{matrix.compiler}}-${{matrix.arch}}-${{matrix.config}}-${{matrix.dllver}}-${{github.sha}}
5157
restore-keys: |
52-
ccache-${{matrix.compiler}}-${{matrix.arch}}-
58+
ccache-${{matrix.compiler}}-${{matrix.arch}}-${{matrix.config}}-${{matrix.dllver}}-
5359
- name: Set ccache settings
5460
run: |
5561
echo "CCACHE_BASEDIR=${{github.workspace}}" >> $GITHUB_ENV
@@ -60,222 +66,17 @@ jobs:
6066
if: ${{ matrix.compiler == 'gcc' }}
6167
run: echo "CCACHE_COMPILERCHECK=string:${{steps.get_rosbe_spec.outputs.git-sha}}-${{hashfiles('./build_rosbe_ci.sh')}}" >> $GITHUB_ENV
6268
- name: Configure
63-
run: echo 'cmake -S ${{github.workspace}}/src -B ${{github.workspace}}/build -G Ninja -DCMAKE_TOOLCHAIN_FILE:FILEPATH=toolchain-${{matrix.compiler}}.cmake -DARCH:STRING=${{matrix.arch}} -DCMAKE_BUILD_TYPE=${{matrix.config}} -DENABLE_CCACHE=1 -DENABLE_ROSTESTS=1 -DENABLE_ROSAPPS=1 ${{env.D_CLANG_VERSION}}' | ${{github.workspace}}/RosBE-CI/RosBE.sh . 0 ${{matrix.arch}}
69+
run: echo 'cmake -S ${{github.workspace}}/src -B ${{github.workspace}}/build -G Ninja -DCMAKE_TOOLCHAIN_FILE:FILEPATH=toolchain-${{matrix.compiler}}.cmake -DARCH:STRING=${{matrix.arch}} -DCMAKE_BUILD_TYPE=${{matrix.config}} -DDLL_EXPORT_VERSION=${{matrix.dllver}} -DENABLE_CCACHE=1 ${{env.D_CLANG_VERSION}}' | ${{github.workspace}}/RosBE-CI/RosBE.sh . 0 ${{matrix.arch}}
6470
- name: Build
6571
run: echo 'cmake --build ${{github.workspace}}/build -- -k0' | ${{github.workspace}}/RosBE-CI/RosBE.sh . 0 ${{matrix.arch}}
6672
- name: Generate ISOs
6773
run: echo 'cmake --build ${{github.workspace}}/build --target bootcd --target livecd' | ${{github.workspace}}/RosBE-CI/RosBE.sh . 0 ${{matrix.arch}}
6874
- name: Print ccache statistics
6975
run: ccache -s
7076
- name: Upload ISOs
71-
uses: actions/upload-artifact@v2
77+
uses: actions/upload-artifact@v4
7278
with:
73-
name: reactos-${{matrix.compiler}}-${{matrix.arch}}-${{matrix.config}}-${{github.sha}}
79+
name: reactos-${{matrix.compiler}}-${{matrix.arch}}-${{matrix.config}}-${{matrix.dllver}}-${{github.sha}}
7480
path: |
7581
build/bootcd.iso
7682
build/livecd.iso
77-
78-
build-msvc:
79-
strategy:
80-
matrix:
81-
toolset: ['14.2', '14.1'] # VS 2019, 2017
82-
arch: [i386, amd64]
83-
config: [Debug, Release]
84-
include:
85-
- arch: i386 # Not compiling on amd64 prompt
86-
toolset: '14.0' # VS 2015
87-
fail-fast: false
88-
runs-on: windows-latest
89-
steps:
90-
- name: Install ninja
91-
run: choco install -y ninja
92-
- name: Install Flex & Bison
93-
run: |
94-
curl -O https://svn.reactos.org/storage/vperevertkin/flexbison.7z
95-
7z x flexbison.7z -O${{github.workspace}}\bin
96-
echo "${{github.workspace}}\bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
97-
echo "BISON_PKGDATADIR=${{github.workspace}}\bin\share\bison" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
98-
echo "M4=${{github.workspace}}\bin\m4.exe" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
99-
- name: Activate VS cmd (x86)
100-
if: ${{ matrix.arch == 'i386' }}
101-
uses: ilammy/msvc-dev-cmd@v1
102-
with:
103-
arch: amd64_x86
104-
toolset: ${{matrix.toolset}}
105-
- name: Activate VS cmd (amd64)
106-
if: ${{ matrix.arch == 'amd64' }}
107-
uses: ilammy/msvc-dev-cmd@v1
108-
with:
109-
arch: amd64
110-
toolset: ${{matrix.toolset}}
111-
- name: Source checkout
112-
uses: actions/checkout@v2
113-
with:
114-
path: src
115-
- name: Configure
116-
run: cmake -S src -B build -G Ninja -DCMAKE_TOOLCHAIN_FILE:FILEPATH=toolchain-msvc.cmake -DARCH:STRING=${{matrix.arch}} -DCMAKE_BUILD_TYPE=${{matrix.config}} -DENABLE_ROSTESTS=1 -DENABLE_ROSAPPS=1
117-
- name: Build
118-
run: cmake --build build -- -k0
119-
- name: Generate ISOs
120-
run: cmake --build build --target bootcd --target livecd
121-
- name: Upload ISOs
122-
uses: actions/upload-artifact@v2
123-
with:
124-
name: reactos-msvc${{matrix.toolset}}-${{matrix.arch}}-${{matrix.config}}-${{github.sha}}
125-
path: |
126-
build/bootcd.iso
127-
build/livecd.iso
128-
- name: Upload debug symbols
129-
if: ${{ matrix.config == 'Debug' }}
130-
uses: actions/upload-artifact@v2
131-
with:
132-
name: reactos-syms-msvc${{matrix.toolset}}-${{matrix.arch}}-${{matrix.config}}-${{github.sha}}
133-
path: build/msvc_pdb
134-
135-
build-msvc-arm:
136-
strategy:
137-
matrix:
138-
toolset: ['14.2', '14.1'] # VS 2019, 2017
139-
arch: [arm]
140-
config: [Debug, Release]
141-
fail-fast: false
142-
runs-on: windows-latest
143-
steps:
144-
- name: Install ninja
145-
run: choco install -y ninja
146-
- name: Install Flex & Bison
147-
run: |
148-
curl -O https://svn.reactos.org/storage/vperevertkin/flexbison.7z
149-
7z x flexbison.7z -O${{github.workspace}}\bin
150-
echo "${{github.workspace}}\bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
151-
echo "BISON_PKGDATADIR=${{github.workspace}}\bin\share\bison" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
152-
echo "M4=${{github.workspace}}\bin\m4.exe" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
153-
- name: Activate VS cmd (arm)
154-
uses: ilammy/msvc-dev-cmd@v1
155-
with:
156-
arch: x86_arm
157-
toolset: ${{matrix.toolset}}
158-
- name: Source checkout
159-
uses: actions/checkout@v2
160-
with:
161-
path: src
162-
- name: Configure
163-
run: cmake -S src -B build -G Ninja -DCMAKE_TOOLCHAIN_FILE:FILEPATH=toolchain-msvc.cmake -DARCH:STRING=${{matrix.arch}} -DCMAKE_BUILD_TYPE=${{matrix.config}} -DENABLE_ROSTESTS=1 -DENABLE_ROSAPPS=1
164-
- name: Build base module
165-
run: cmake --build build --target base/all
166-
- name: Build control panel applets
167-
run: cmake --build build --target dll/cpl/all
168-
- name: Build rosapps
169-
run: cmake --build build --target modules/rosapps/all
170-
- name: Upload compiled binaries
171-
uses: actions/upload-artifact@v2
172-
with:
173-
name: reactos-msvc${{matrix.toolset}}-${{matrix.arch}}-${{matrix.config}}-${{github.sha}}
174-
path: |
175-
build/base
176-
build/dll/cpl
177-
build/modules/rosapps
178-
!**/CMakeFiles
179-
!**/cmake_install.cmake
180-
!**/*.asm
181-
!**/*.bin
182-
!**/*.c
183-
!**/*.def
184-
!**/*.exp
185-
!**/*.h
186-
!**/*.lib
187-
!**/*.mc
188-
!**/*.obj
189-
!**/*.rc
190-
!**/*.tlb
191-
- name: Upload debug symbols
192-
if: ${{ matrix.config == 'Debug' }}
193-
uses: actions/upload-artifact@v2
194-
with:
195-
name: reactos-syms-msvc${{matrix.toolset}}-${{matrix.arch}}-${{matrix.config}}-${{github.sha}}
196-
path: build/msvc_pdb
197-
198-
build-clang-cl:
199-
strategy:
200-
matrix:
201-
arch: [i386, amd64]
202-
config: [Debug, Release]
203-
fail-fast: false
204-
runs-on: windows-latest
205-
steps:
206-
- name: Install ninja
207-
run: choco install -y ninja
208-
- name: Install LLVM
209-
run: |
210-
choco install -y llvm
211-
echo "LLVM_PATH=${env:PROGRAMFILES}\llvm\bin" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
212-
- name: Install Flex & Bison
213-
run: |
214-
curl -O https://svn.reactos.org/storage/vperevertkin/flexbison.7z
215-
7z x flexbison.7z -O${{github.workspace}}\bin
216-
echo "${{github.workspace}}\bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
217-
echo "BISON_PKGDATADIR=${{github.workspace}}\bin\share\bison" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
218-
echo "M4=${{github.workspace}}\bin\m4.exe" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
219-
- name: Activate VS cmd (x86)
220-
if: ${{ matrix.arch == 'i386' }}
221-
uses: ilammy/msvc-dev-cmd@v1
222-
with:
223-
arch: amd64_x86
224-
toolset: '14.1' # latest masm build known to make bootable builds
225-
- name: Activate VS cmd (amd64)
226-
if: ${{ matrix.arch == 'amd64' }}
227-
uses: ilammy/msvc-dev-cmd@v1
228-
with:
229-
arch: amd64
230-
toolset: '14.1' # latest masm build known to make bootable builds
231-
- name: Add LLVM to PATH
232-
run: echo "${env:LLVM_PATH}" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
233-
- name: Source checkout
234-
uses: actions/checkout@v2
235-
with:
236-
path: src
237-
- name: Configure
238-
run: cmake -S src -B build -G Ninja -DCMAKE_TOOLCHAIN_FILE:FILEPATH=toolchain-msvc.cmake -DARCH:STRING=${{matrix.arch}} -DCMAKE_BUILD_TYPE=${{matrix.config}} -DENABLE_ROSTESTS=1 -DENABLE_ROSAPPS=1 -DUSE_CLANG_CL:BOOL=TRUE
239-
- name: Build
240-
run: cmake --build build -- -k0
241-
- name: Generate ISOs
242-
run: cmake --build build --target bootcd --target livecd
243-
- name: Upload ISOs
244-
uses: actions/upload-artifact@v2
245-
with:
246-
name: reactos-clang-cl-${{matrix.arch}}-${{matrix.config}}-${{github.sha}}
247-
path: |
248-
build/bootcd.iso
249-
build/livecd.iso
250-
- name: Upload debug symbols
251-
if: ${{ matrix.config == 'Debug' }}
252-
uses: actions/upload-artifact@v2
253-
with:
254-
name: reactos-syms-clang-cl-${{matrix.arch}}-${{matrix.config}}-${{github.sha}}
255-
path: build/msvc_pdb
256-
257-
build-msbuild-i386:
258-
name: MSBuild (i386)
259-
runs-on: windows-latest
260-
steps:
261-
- name: Install Flex and Bison
262-
run: |
263-
curl -O https://svn.reactos.org/storage/vperevertkin/flexbison.7z
264-
7z x flexbison.7z -O${{github.workspace}}\bin
265-
echo "${{github.workspace}}\bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
266-
echo "BISON_PKGDATADIR=${{github.workspace}}\bin\share\bison" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
267-
echo "M4=${{github.workspace}}\bin\m4.exe" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
268-
- name: Add CL to PATH
269-
uses: ilammy/msvc-dev-cmd@v1
270-
with:
271-
arch: amd64_x86
272-
- uses: actions/checkout@v2
273-
with:
274-
path: src
275-
- name: Configure
276-
run: |
277-
mkdir build
278-
cd build
279-
cmake -G "Visual Studio 16 2019" -A Win32 -DCMAKE_TOOLCHAIN_FILE:FILEPATH=toolchain-msvc.cmake -DARCH:STRING=i386 -DENABLE_ROSTESTS=1 -DENABLE_ROSAPPS=1 ${{github.workspace}}\src
280-
- name: Build
281-
run: cmake --build ${{github.workspace}}\build --target bootcd --target livecd

0 commit comments

Comments
 (0)