mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-08-21 17:12:18 +00:00
mmake: -j$(nproc), passthrough o//
Now `mmake o/ape/ape.elf` works.
This commit is contained in:
parent
2b315626f3
commit
b08b92248b
2 changed files with 24 additions and 3 deletions
18
tool/zsh/nproc
Normal file
18
tool/zsh/nproc
Normal file
|
@ -0,0 +1,18 @@
|
|||
[[ -x $(whence -p nproc) ]] && {
|
||||
command nproc && {
|
||||
unfunction nproc
|
||||
return
|
||||
}
|
||||
}
|
||||
[[ -x $(which sysctl) ]] && {
|
||||
nproc() {
|
||||
sysctl -n hw.ncpu
|
||||
}
|
||||
nproc && return
|
||||
}
|
||||
# TODO other platforms
|
||||
echo nproc: no implementation found >&2
|
||||
nproc() {
|
||||
echo 2
|
||||
}
|
||||
nproc
|
Loading…
Add table
Add a link
Reference in a new issue