From nobody Tue Nov 12 14:41:42 2024 X-Original-To: dev-commits-ports-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4XnpyZ6Syjz5ccq8; Tue, 12 Nov 2024 14:41:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4XnpyZ5zKzz4PCQ; Tue, 12 Nov 2024 14:41:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1731422502; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=im4BHFExDI6S80UjSZpi0+inB2aLe4JNw5prAKrH8Q0=; b=K2xT1AgsFV6L20jq06YK/vEcB+A0nVkREsfUxdpnJkcPv/4Bm0XVbuJ+X8cVEwDYkB+0ib +fBScyjKGc/ZEkeFPdCf3ZKH++lZ9N0nkP08OwjnlB8HzTzUPNryTdcyjF+pdABS7Hd8/w 10wpFwQ/qir6mkq1uscWZDPjl5bdbHeaibWQyUTY/t6Dt5wxqjXgmnJJVfxYTHV352oCrR LLlIe0McDzKetcWeKgzlVtSaXjrVZBSmSu00UGPaM5ulgnZj/K90Yw0TStBms0itY2rln4 9AayjJm6YENAq8gglC0tHyyezZPbV9hf4srJE35+N+L/7iRvcPhrfXTvg0CHEw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1731422502; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=im4BHFExDI6S80UjSZpi0+inB2aLe4JNw5prAKrH8Q0=; b=tL2yuDv59pxz46MXXc8PiM+b3kgYXCCjw01LPfvPH4QePfj1Mq3iKGbXuqpP4pYxh9y9tQ 4EhkOJFMD/6D3DGJGRtpdzZiOMyFQxzVOXdbPEIiNhWGuy6lroWbkZLTq5ZZobWn5saivB OB5+WpNJpSRRhnXaW+TLezGoCBTbHspW2c8j72NcZ6kY+6ZWs3/dEBHmq8Ui0iEdz0wQS0 B880eYRVMr8wCL/56n1i0IBJrBtrqSKibwgeFlrrdiWKPPOWf1BJ8Zwd0zRkorrGxwE8Km XoPNvvNfE6zfJ+IUqUAakY/WBycXEwoMRM3grBtCEZcczqhUuhM2h3fQdHSZHA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1731422502; a=rsa-sha256; cv=none; b=Ivqn+gec9B+4dkHuXkBznrmsjCRBgHkyfkyPywvFXFfx2jHeZ7+FtZRMTjZOD5PEzMUXBV 4Tq+fqSyyq1HRC8/gWyiQuPDIqggcZYrMDccCHAsb1YDcSkLBvl11imnyvKgaJF75kBxHW OW9oC9AvZYhSibds83x/WL7ZO+1OdnReyqNgTbdLzXDNr4TAGKdXaf16YRJ9KLRwp0nuau MuSX6kLg5oDJ92IAZ2dUeKb17ql3VjkpLQYhe/Mg43SJ48RING5MCQBel76RmB5qu8lovq lS7YTO1o9J+Nwpq/Ywv7nVvzqWO0EA1QKEMfRTvBUgS2qr41NOd74Au0rwXiPg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4XnpyZ5ZkPzDcd; Tue, 12 Nov 2024 14:41:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 4ACEfg7J032142; Tue, 12 Nov 2024 14:41:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4ACEfgHc032139; Tue, 12 Nov 2024 14:41:42 GMT (envelope-from git) Date: Tue, 12 Nov 2024 14:41:42 GMT Message-Id: <202411121441.4ACEfgHc032139@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Mikael Urankar Subject: git: 854533b69789 - main - net-mgmt/ocsinventory-agent: Fix cpu detection List-Id: Commits to the main branch of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-ports-main@freebsd.org Sender: owner-dev-commits-ports-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: mikael X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 854533b69789dd41fb97984079c73eaa32db2531 Auto-Submitted: auto-generated The branch main has been updated by mikael: URL: https://cgit.FreeBSD.org/ports/commit/?id=854533b69789dd41fb97984079c73eaa32db2531 commit 854533b69789dd41fb97984079c73eaa32db2531 Author: Mikael Urankar AuthorDate: 2024-11-12 14:37:27 +0000 Commit: Mikael Urankar CommitDate: 2024-11-12 14:41:39 +0000 net-mgmt/ocsinventory-agent: Fix cpu detection Fix typo, NBSOCKETS isn't defined Reported by: Carlos Fernando Assis Paniago Tested by: Carlos Fernando Assis Paniago --- net-mgmt/ocsinventory-agent/Makefile | 1 + .../patch-lib_Ocsinventory_Agent_Backend_OS_BSD_CPU.pm | 13 +++++++++++++ 2 files changed, 14 insertions(+) diff --git a/net-mgmt/ocsinventory-agent/Makefile b/net-mgmt/ocsinventory-agent/Makefile index 9c8c0509bdf0..0572ca8f9a90 100644 --- a/net-mgmt/ocsinventory-agent/Makefile +++ b/net-mgmt/ocsinventory-agent/Makefile @@ -1,6 +1,7 @@ PORTNAME= ocsinventory PORTVERSION= 2.10.4 DISTVERSIONPREFIX= v +PORTREVISION= 1 PORTEPOCH= 1 CATEGORIES= net-mgmt PKGNAMESUFFIX= -agent diff --git a/net-mgmt/ocsinventory-agent/files/patch-lib_Ocsinventory_Agent_Backend_OS_BSD_CPU.pm b/net-mgmt/ocsinventory-agent/files/patch-lib_Ocsinventory_Agent_Backend_OS_BSD_CPU.pm new file mode 100644 index 000000000000..75d5c0457489 --- /dev/null +++ b/net-mgmt/ocsinventory-agent/files/patch-lib_Ocsinventory_Agent_Backend_OS_BSD_CPU.pm @@ -0,0 +1,13 @@ +--- lib/Ocsinventory/Agent/Backend/OS/BSD/CPU.pm.orig 2024-11-12 14:35:48 UTC ++++ lib/Ocsinventory/Agent/Backend/OS/BSD/CPU.pm +@@ -64,8 +64,8 @@ sub run { + if ($cpu->{NBSOCKET} and $cpu->{CORES} and $cpu->{THREADS} ){ + if ($cpu->{THREADS} >= $cpu->{CORES}) { + $cpu->{THREADS}=$cpu->{THREADS}/$cpu->{CORES}; +- } elsif ($cpu->{THREADS} >= $cpu->{NBSOCKETS}) { +- $cpu->{THREADS}=$cpu->{THREADS}/$cpu->{NBSOCKETS}; ++ } elsif ($cpu->{THREADS} >= $cpu->{NBSOCKET}) { ++ $cpu->{THREADS}=$cpu->{THREADS}/$cpu->{NBSOCKET}; + } + } +