@@ -41,34 +41,34 @@ if not exist build\boot mkdir build\boot
41
41
@ rem Build the bootstrap interpreter
42
42
for %%f in (src\core\*.c) do (
43
43
%JANET_COMPILE% /DJANET_BOOTSTRAP /Fobuild\boot\%%~nf .obj %%f
44
- @ if not errorlevel 0 goto :BUILDFAIL
44
+ @ if errorlevel 1 goto :BUILDFAIL
45
45
)
46
46
for %%f in (src\boot\*.c) do (
47
47
%JANET_COMPILE% /DJANET_BOOTSTRAP /Fobuild\boot\%%~nf .obj %%f
48
- @ if not errorlevel 0 goto :BUILDFAIL
48
+ @ if errorlevel 1 goto :BUILDFAIL
49
49
)
50
50
%JANET_LINK% /out:build\janet_boot.exe build\boot\*.obj
51
- @ if not errorlevel 0 goto :BUILDFAIL
51
+ @ if errorlevel 1 goto :BUILDFAIL
52
52
build\janet_boot . > build\c\janet.c
53
- @ if not errorlevel 0 goto :BUILDFAIL
53
+ @ if errorlevel 1 goto :BUILDFAIL
54
54
55
55
@ rem Build the sources
56
56
%JANET_COMPILE% /Fobuild\janet.obj build\c\janet.c
57
- @ if not errorlevel 0 goto :BUILDFAIL
57
+ @ if errorlevel 1 goto :BUILDFAIL
58
58
%JANET_COMPILE% /Fobuild\shell.obj src\mainclient\shell.c
59
- @ if not errorlevel 0 goto :BUILDFAIL
59
+ @ if errorlevel 1 goto :BUILDFAIL
60
60
61
61
@ rem Build the resources
62
62
rc /nologo /fobuild\janet_win.res janet_win.rc
63
- @ if not errorlevel 0 goto :BUILDFAIL
63
+ @ if errorlevel 1 goto :BUILDFAIL
64
64
65
65
@ rem Link everything to main client
66
66
%JANET_LINK% /out:janet.exe build\janet.obj build\shell.obj build\janet_win.res
67
- @ if not errorlevel 0 goto :BUILDFAIL
67
+ @ if errorlevel 1 goto :BUILDFAIL
68
68
69
69
@ rem Build static library (libjanet.lib)
70
70
%JANET_LINK_STATIC% /out:build\libjanet.lib build\janet.obj
71
- @ if not errorlevel 0 goto :BUILDFAIL
71
+ @ if errorlevel 1 goto :BUILDFAIL
72
72
73
73
echo === Successfully built janet.exe for Windows ===
74
74
echo === Run 'build_win test' to run tests. ==
@@ -102,7 +102,7 @@ exit /b 0
102
102
:TEST
103
103
for %%f in (test/suite*.janet) do (
104
104
janet.exe test\%%f
105
- @ if not errorlevel 0 goto TESTFAIL
105
+ @ if errorlevel 1 goto TESTFAIL
106
106
)
107
107
exit /b 0
108
108
0 commit comments