added cross-platform

This commit is contained in:
2023-12-03 15:31:50 +03:00
parent c4b8e2dd7a
commit 0afbb32788
7 changed files with 103 additions and 42 deletions

View File

@@ -1,3 +1,10 @@
#define _CRT_SECURE_NO_WARNINGS
using namespace std;
#if __cplusplus >= 201703L
#include <filesystem>
#endif
#include "CompilationSupervisor.h"
#include "RunSupervisor.h"
#include "Global.h"
@@ -10,8 +17,14 @@ int main(int argc, char ** argv)
//--
freeKernels = maxKernels;
busyKernels= 0;
//--
chdir(packageWorkspace.getCharArray());
//--
#if __cplusplus >= 201703L
std::filesystem::current_path(packageWorkspace.getCharArray());
#else
chdir(packageWorkspace.getCharArray());
#endif
userWorkspace.println();
packageWorkspace.println();
printf("%d\n", maxKernels);