1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 01:17:36 +00:00
serenity/Ports/ninja/patches/nproc.patch
Nico Weber 7f73f0300c Ports: Add ninja
- 1.8.2 for now, newer versions need high-res timestamp file APIs
  which serenity doesn't have yet
- pselect() instead of ppoll() for now, same reason (depends on #2609)
- no good default for -j yet (see nproc.patch)
- `-l` probably doesn't work yet (see loadavg.patch), but I've never
  used that anyways
- some minor include patches that I've also sent upstream

Other than that, this seems to work reasonably well. It currently
produces some spam on stdout from probably the shell.
2020-06-22 16:10:06 +02:00

13 lines
358 B
Diff

diff --git a/src/util.cc b/src/util.cc
index ae94d34..72cf501 100644
--- a/src/util.cc
+++ b/src/util.cc
@@ -476,7 +476,7 @@ int GetProcessorCount() {
GetNativeSystemInfo(&info);
return info.dwNumberOfProcessors;
#else
- return sysconf(_SC_NPROCESSORS_ONLN);
+ return 1; // FIXME: serenity way of saying sysconf(_SC_NPROCESSORS_ONLN);
#endif
}