-
Notifications
You must be signed in to change notification settings - Fork 64
132 lines (107 loc) · 4.59 KB
/
CheckBuild.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
126
127
128
129
130
131
#
# Original works by ddub07 <github.com>
# 03/01/2023 - GampyG28 <github.com> major overhaul, renamed and updated.
# 04/16/2023 - GampyG28 <github.com> Added Assembly Kernels and Loaders
# 07/16/2023 - GampyG28 <github.com> Removed C Kernel builds
#
name: CheckBuild
on: [ pull_request, push ]
jobs:
Kernels:
runs-on: ubuntu-20.04
steps:
- name: Checkout Code
uses: actions/[email protected]
- name: Update Package Repository
run: sudo apt-get update
- name: Install GNU m68k Compiler and Make tool
run: sudo apt-get install -y gcc-m68k-linux-gnu make
- name: Create temporary artifact storage
run: mkdir TemporaryArtifactStorage
- name: Build Assembly Kernels and Loaders
run: |
cd Kernels
#
# Each group is required to have 3 elements in the following order
# 1: PCM Moniker (P01 (includes P59), P04, P08, etc...)
# 2: Kernel Base Address
# 3: Loader Base Address or NOLOADER if a loader is not used.
#
for p in "P01 FF8000 NOLOADER" "P04 FF8000 FF9890" "P04_256k FF8000 NOLOADER" "P08 FFAC00 NOLOADER" "P10 FFB800 NOLOADER" "P12 FF2000 NOLOADER" "E54 FF8F50 NOLOADER" "BlackBox FFC300 NOLOADER"; do
pcm="${p%% *}";
p="${p#* }"
address="${p%% *}"
p="${p#* }"
loader="${p%% *}"
echo "Building Kernel : ${pcm}"
make -f makefile-assembly PREFIX=/usr/bin/m68k-linux-gnu- pcm=${pcm} address=${address}
echo " Copy-Item Kernel-${pcm}.bin to TemporaryArtifactStorage"
cp Kernel-${pcm}.bin ../TemporaryArtifactStorage/
echo " Cleanup after Kernel-${pcm}"
echo
make -f makefile-assembly clean
#
# Build the Loader if requested
#
if [ ${loader} != NOLOADER ]; then
echo "Building Loader : ${pcm}"
make -f makefile-assembly PREFIX=/usr/bin/m68k-linux-gnu- pcm=${pcm} address=${loader} name=Loader
echo " Copy-Item Loader-${pcm}.bin to TemporaryArtifactStorage"
cp Loader-${pcm}.bin ../TemporaryArtifactStorage/
echo " Cleanup after Loader-${pcm}"
echo
make -f makefile-assembly clean
fi
done
- name: Upload artifacts
uses: actions/[email protected]
with:
name: Kernels_${{github.sha}}
path: TemporaryArtifactStorage
PCMHammer:
needs: Kernels
runs-on: windows-2019
steps:
- name: Checkout Code
uses: actions/[email protected]
- name: Setup MSBuild Path
uses: microsoft/[email protected]
- name: Setup NuGet
uses: NuGet/[email protected]
- name: Restore NuGet Packages
run: nuget restore Apps/PcmApps.sln
- name: Download Kernels artifact
uses: actions/[email protected]
with:
name: Kernels_${{github.sha}}
path: TemporaryArtifactStorage
- name: Remove Stale Kernels artifact
uses: geekyeggo/delete-artifact@v2
with:
name: Kernels_${{github.sha}}
- name: Build Applications
run: msbuild Apps/PcmApps.sln
- name: Add PCM Hammer to temporary artifact storage
run: |
Copy-Item -Path "Apps/PcmHammer/bin/Debug/PcmHammer.*" -Destination TemporaryArtifactStorage
Copy-Item -Path "Apps/PcmHammer/bin/Debug/*.dll" -Destination TemporaryArtifactStorage
Copy-Item -Path "Apps/PcmHammer/bin/Debug/*.pdb" -Destination TemporaryArtifactStorage
- name: Add PCM Logger to temporary artifact storage
run: |
Copy-Item -Path "Apps/PcmLogger/bin/Debug/PcmLogger.*" -Destination TemporaryArtifactStorage
Copy-Item -Path "Apps/PcmLogger/bin/Debug/*.dll" -Destination TemporaryArtifactStorage
Copy-Item -Path "Apps/PcmLogger/bin/Debug/*.pdb" -Destination TemporaryArtifactStorage
Copy-Item -Path "Apps/PcmLogger/*.LogProfile" -Destination TemporaryArtifactStorage
Copy-Item -Path "Apps/PcmLogger/Parameters.*.xml" -Destination TemporaryArtifactStorage
- name: Add VPW Explorer to temporary artifact storage
run: |
Copy-Item -Path "Apps/VpwExplorer/bin/Debug/VpwExplorer.*" -Destination TemporaryArtifactStorage
Copy-Item -Path "Apps/VpwExplorer/bin/Debug/*.dll" -Destination TemporaryArtifactStorage
Copy-Item -Path "Apps/VpwExplorer/bin/Debug/*.pdb" -Destination TemporaryArtifactStorage
- name: Is it all there ??
run: ls -l TemporaryArtifactStorage/
- name: Upload artifacts
uses: actions/[email protected]
with:
name: PCMHacks_${{github.sha}}
path: TemporaryArtifactStorage