summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMitya Selivanov <automainint@guattari.tech>2024-06-06 14:04:36 +0200
committerMitya Selivanov <automainint@guattari.tech>2024-06-06 14:04:36 +0200
commitb1f0925221d467bfa5f53e9b70de1332f77642a6 (patch)
treeb6193428f44d94355c7718cc72e5a10c0dff99d5
parente2ebfba98e34dfa8f6a989770fc522be79388cef (diff)
downloadkit-b1f0925221d467bfa5f53e9b70de1332f77642a6.zip
[build] Cleanup
-rwxr-xr-xbuild.c39
1 files changed, 20 insertions, 19 deletions
diff --git a/build.c b/build.c
index 1e6e61a..225a207 100755
--- a/build.c
+++ b/build.c
@@ -565,26 +565,23 @@ i32 main(i32 argc, c8 **argv) {
#if defined(_WIN32) && !defined(__CYGWIN__)
STARTUPINFO si = { .cb = sizeof(STARTUPINFO) };
PROCESS_INFORMATION pi = { 0 };
-#endif
- if (OS == WINDOWS) {
-#if defined(_WIN32) && !defined(__CYGWIN__)
- CreateProcessA(
- NULL,
- fmt("\"." DLM "%s" DLM "test_interprocess\" reader", destination),
- NULL,
- NULL,
- 0,
- 0,
- NULL,
- NULL,
- &si,
- &pi
- );
- Sleep(0);
+ CreateProcessA(
+ NULL,
+ fmt("\"." DLM "%s" DLM "test_interprocess\" reader", destination),
+ NULL,
+ NULL,
+ 0,
+ 0,
+ NULL,
+ NULL,
+ &si,
+ &pi
+ );
+ Sleep(0);
+#else
+ system(fmt("\"." DLM "%s" DLM "test_interprocess\" reader &", destination));
#endif
- } else
- system(fmt("\"." DLM "%s" DLM "test_interprocess\" reader &", destination));
code = system(fmt("\"." DLM "%s" DLM "test_interprocess\" writer", destination));
@@ -602,6 +599,10 @@ i32 main(i32 argc, c8 **argv) {
CloseHandle(pi.hThread);
#endif
- printf("\nAll done.\n");
+ if (status == 0)
+ printf("\nAll done - OK.\n");
+ else
+ printf("\nAll done - FAILURE.\n");
+
return status;
}