mirror of
https://git.freebsd.org/ports.git
synced 2025-07-18 17:59:20 -04:00
sysutils/parallel: Fix --number-of-cores
- Bump PORTREVISION for package change PR: 268011 Reported by: jwb
This commit is contained in:
parent
e5c47d34d0
commit
aa469725eb
2 changed files with 19 additions and 0 deletions
|
@ -1,5 +1,6 @@
|
|||
PORTNAME= parallel
|
||||
PORTVERSION= 20231122
|
||||
PORTREVISION= 1
|
||||
CATEGORIES= sysutils
|
||||
MASTER_SITES= GNU
|
||||
|
||||
|
|
18
sysutils/parallel/files/patch-src-parallel
Normal file
18
sysutils/parallel/files/patch-src-parallel
Normal file
|
@ -0,0 +1,18 @@
|
|||
--- src/parallel.orig 2023-11-23 00:27:43 UTC
|
||||
+++ src/parallel
|
||||
@@ -8704,13 +8704,9 @@ sub sct_freebsd($) {
|
||||
local $/ = "\n";
|
||||
my $cpu = shift;
|
||||
$cpu->{'cores'} ||=
|
||||
- (::qqx(qq{ sysctl -a dev.cpu | grep \%parent | awk '{ print \$2 }' | uniq | wc -l | awk '{ print \$1 }' })
|
||||
- or
|
||||
- ::qqx(qq{ sysctl hw.ncpu | awk '{ print \$2 }' }));
|
||||
+ ::qqx(qq{ sysctl kern.smp.cores | awk '{ print \$2 }' });
|
||||
$cpu->{'threads'} ||=
|
||||
- (::qqx(qq{ sysctl hw.ncpu | awk '{ print \$2 }' })
|
||||
- or
|
||||
- ::qqx(qq{ sysctl -a dev.cpu | grep \%parent | awk '{ print \$2 }' | uniq | wc -l | awk '{ print \$1 }' }));
|
||||
+ ::qqx(qq{ sysctl kern.smp.cpus | awk '{ print \$2 }' });
|
||||
return $cpu;
|
||||
}
|
||||
|
Loading…
Add table
Reference in a new issue