forked from DrDonk/unlocker
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.cmd
62 lines (56 loc) · 1.53 KB
/
build.cmd
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
@echo off
echo Building release executables
if [%1]==[] (
echo Product version not found: x.y.z (e.g. 1.2.3)
exit /b 1
)
pushd .\commands\check
echo Building check
go-winres make --arch amd64 --product-version %1 --file-version %1
set GOOS=windows
set GOARCH=amd64
go build -o ..\..\build\windows\check.exe
set GOOS=linux
set GOARCH=amd64
go build -o ..\..\build\linux\check
del /q rsrc_windows_amd64.syso
popd
pushd .\commands\relock
echo Building relock
go-winres make --arch amd64 --product-version %1 --file-version %1
set GOOS=windows
set GOARCH=amd64
go build -o ..\..\build\windows\relock.exe
set GOOS=linux
set GOARCH=amd64
go build -o ..\..\build\linux\relock
del /q rsrc_windows_amd64.syso
popd
pushd .\commands\dumpsmc
echo Building dumpsmc
go-winres make --arch amd64 --product-version %1 --file-version %1
set GOOS=windows
set GOARCH=amd64
go build -o ..\..\build\windows\dumpsmc.exe
set GOOS=linux
set GOARCH=amd64
go build -o ..\..\build\linux\dumpsmc
del /q rsrc_windows_amd64.syso
popd
pushd .\commands\hostcaps
echo Building hostcaps
go-winres make --arch amd64 --product-version %1 --file-version %1
set GOOS=windows
set GOARCH=amd64
go build -o ..\..\build\windows\hostcaps.exe
set GOOS=linux
set GOARCH=amd64
go build -o ..\..\build\linux\hostcaps
del /q rsrc_windows_amd64.syso
popd
xcopy /R /Y LICENSE .\build\
xcopy /R /Y *.md .\build\
xcopy /R /Y cpuid\linux\cpuid .\build\linux\cpuid
xcopy /R /Y cpuid\windows\cpuid.exe .\build\windows\cpuid.exe
xcopy /E /F /I /R /Y ISO .\build\ISO
xcopy /E /F /I /R /Y ISO .\'dist\templates