From nobody Tue Feb 7 20:13:16 2023 X-Original-To: dev-commits-ports-all@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 4PBDpP1qwVz3nfpN; Tue, 7 Feb 2023 20:13:17 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4PBDpP1JmLz3DsX; Tue, 7 Feb 2023 20:13:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1675800797; 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=ixh4pCb8uDqBDlcvWKw2Y84uG1bhzfco5ZJiddh8398=; b=a0Kr2DtrUwoSsEVBprQ5zYrIClttw564iUmKJx4uvJQYEOUdCXB156YLXwhzIZNfqRMtBW DtLZQKyzc81/6M33FPpMWITp9aWawEG2EKq3vNFsqsmcVpQm8ulZj/SrlV5UhNXfIarZJN XATnWuNOXyXQxnzDspgqamuIaNQzihiZWcQoJLKLNWgi8lauXBpmIta+/dd9RJnnwY3mO9 rT70hUYzbMBeioE/9b7nDWqAFygoQhOk76eVz8U8+gujzgLPMTeC+AEbBdVMEfVlvMBR7+ lhbPNy/tmJ0mg4cnrJaOFC4cFTa59epm0YWgjmtx82PGL+nsMe2KhKkcgdH7PA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1675800797; 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=ixh4pCb8uDqBDlcvWKw2Y84uG1bhzfco5ZJiddh8398=; b=B9b0PzzoLvlj+qQYDc6C1h/z2EW4VyeJfV22QXrzs01zagb/T3T3iyO8EwLGd6PEPueYki BTXqhWK807a2cYbpKvuj4FV1gQjcrbbnTCTnXLt4VcfPffsuZ64kbm9zDMLHZZ5LP8w2vf wr15G3ZGfWNgPi09JXUiqllDHbniYYf7/9keE2QlbVUN25a0+g9G1eB64Zqkh+TQKwU76+ 2wUvPNBHNpk8kIOHWbCdGYq1MpajELKvgW0DHCngdzcQM+lMfJlFWtdvfCjpdkWgOi/F7j HVmut+EHInXmCfFfkCrZpFC42l1Ul+e4ICdPccc3m2Wds1+S0bdtQvVVYfwgZg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1675800797; a=rsa-sha256; cv=none; b=a3xhnXlKfYpI+NePhX8IlwtTQjDNzvxXeHVfYKjcZlZQL+OQW/74IlSqVecadaE1T3HAcz HR9Wc0X4dZu9vdHohlBE8jKK6wITR/cewUzAtn1bhwCNp9d06dVyXGZ531iqzX8y1XXg2F /6OKOfyoqiw8oPVabc9KH/ElxoYaRUwYsMtwmwHjxYumytw7UpuY1YD9ISKh2WbQLSXWJ5 b0jfUHvonkcwM64nvhvrLMlF3S5nW8cpT3E3k69NbZ/zriYOOanzoBX05d7rXWBYMdGeGq xyWhAk2UoAD+6VlBeFsliciGKQ9LDlyBLJT3/ANWI8HXBuKpX6yfAh2BShesiQ== 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 4PBDpP0QBFzVxt; Tue, 7 Feb 2023 20:13:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 317KDGZM036565; Tue, 7 Feb 2023 20:13:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 317KDG1d036564; Tue, 7 Feb 2023 20:13:16 GMT (envelope-from git) Date: Tue, 7 Feb 2023 20:13:16 GMT Message-Id: <202302072013.317KDG1d036564@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Sofian Brabez Subject: git: 8254b3a476e6 - main - sysutils/archey4: update to 4.14.0.0 List-Id: Commit messages for all branches of the ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-all@freebsd.org X-BeenThere: dev-commits-ports-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: sbz X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 8254b3a476e6714d8e901681e40d2631f7e4b7c5 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by sbz: URL: https://cgit.FreeBSD.org/ports/commit/?id=8254b3a476e6714d8e901681e40d2631f7e4b7c5 commit 8254b3a476e6714d8e901681e40d2631f7e4b7c5 Author: Sofian Brabez AuthorDate: 2023-02-06 23:43:03 +0000 Commit: Sofian Brabez CommitDate: 2023-02-07 20:12:07 +0000 sysutils/archey4: update to 4.14.0.0 --- sysutils/archey4/Makefile | 4 +- sysutils/archey4/distinfo | 6 +-- sysutils/archey4/files/patch-archey_entries_cpu.py | 36 ----------------- .../archey4/files/patch-archey_entries_model.py | 33 ---------------- sysutils/archey4/files/patch-archey_entries_ram.py | 46 ---------------------- 5 files changed, 5 insertions(+), 120 deletions(-) diff --git a/sysutils/archey4/Makefile b/sysutils/archey4/Makefile index 21bcf84d0fa0..4919b295e69c 100644 --- a/sysutils/archey4/Makefile +++ b/sysutils/archey4/Makefile @@ -1,5 +1,5 @@ PORTNAME= archey4 -PORTVERSION= 4.13.4 +PORTVERSION= 4.14.0.0 CATEGORIES= sysutils python MASTER_SITES= PYPI @@ -13,7 +13,7 @@ LICENSE_FILE= ${WRKSRC}/LICENSE RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}distro>=1.3:sysutils/py-distro@${PY_FLAVOR} \ ${PYTHON_PKGNAMEPREFIX}netifaces>=0.10:net/py-netifaces@${PY_FLAVOR} -USES= python:3.6+ +USES= python:3.7+ USE_PYTHON= autoplist distutils do-test: diff --git a/sysutils/archey4/distinfo b/sysutils/archey4/distinfo index 3e077074fbc6..ebcc4392fd85 100644 --- a/sysutils/archey4/distinfo +++ b/sysutils/archey4/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1652740178 -SHA256 (archey4-4.13.4.tar.gz) = 9813ed0a1d5131756375e4113e6b158723d299353dab3d51b6ac0420af402e2c -SIZE (archey4-4.13.4.tar.gz) = 95995 +TIMESTAMP = 1667652994 +SHA256 (archey4-4.14.0.0.tar.gz) = 4df716fcaee12017a99b6fefe5e474175a74dfbaa4a4ebe2a4f99afe2d5b2719 +SIZE (archey4-4.14.0.0.tar.gz) = 101196 diff --git a/sysutils/archey4/files/patch-archey_entries_cpu.py b/sysutils/archey4/files/patch-archey_entries_cpu.py deleted file mode 100644 index 52671cf3091b..000000000000 --- a/sysutils/archey4/files/patch-archey_entries_cpu.py +++ /dev/null @@ -1,36 +0,0 @@ ---- archey/entries/cpu.py.orig 2022-05-17 20:52:34 UTC -+++ archey/entries/cpu.py -@@ -47,7 +47,7 @@ class CPU(Entry): - else: - # Darwin or any other BSD-based system. - self.value = self._parse_system_profiler() or \ -- self._parse_sysctl_machdep() -+ self._parse_sysctl_machdep() or self._parse_sysctl_cpu_model() - - if not self.value: - # This test case has been built for some ARM architectures (see #29). -@@ -157,6 +157,24 @@ class CPU(Entry): - [ - 'sysctl', '-n', - 'machdep.cpu.brand_string', 'machdep.cpu.core_count' -+ ], -+ stderr=DEVNULL, universal_newlines=True -+ ) -+ except (FileNotFoundError, CalledProcessError): -+ return [] -+ -+ # `sysctl_output` should exactly contains two lines. -+ model_name, nb_cores = sysctl_output.splitlines() -+ return [{model_name: int(nb_cores)}] -+ -+ @staticmethod -+ def _parse_sysctl_cpu_model() -> List[Dict[str, int]]: -+ # Runs `sysctl` to fetch some `hw.model and hw.ncpu` keys. -+ try: -+ sysctl_output = check_output( -+ [ -+ 'sysctl', '-n', -+ 'hw.model', 'hw.ncpu' - ], - stderr=DEVNULL, universal_newlines=True - ) diff --git a/sysutils/archey4/files/patch-archey_entries_model.py b/sysutils/archey4/files/patch-archey_entries_model.py deleted file mode 100644 index 7486d199dd22..000000000000 --- a/sysutils/archey4/files/patch-archey_entries_model.py +++ /dev/null @@ -1,33 +0,0 @@ ---- archey/entries/model.py.orig 2022-05-17 21:03:36 UTC -+++ archey/entries/model.py -@@ -23,7 +23,8 @@ class Model(Entry): - or self._fetch_dmi_info() \ - or self._fetch_sysctl_hw() \ - or self._fetch_raspberry_pi_revision() \ -- or self._fetch_android_device_model() -+ or self._fetch_android_device_model() \ -+ or self._fetch_freebsd_model() - - def _fetch_virtual_env_info(self) -> Optional[str]: - """ -@@ -179,3 +180,20 @@ class Model(Entry): - return None - - return f'{brand} ({model})' -+ -+ @staticmethod -+ def _fetch_freebsd_model() -> Optional[str]: -+ """Retrieve `vendor` and `product` properties on FreeBSD """ -+ try: -+ vendor = check_output( -+ ['kenv', 'smbios.bios.vendor'], -+ universal_newlines=True -+ ).rstrip() -+ product = check_output( -+ ['kenv', 'smbios.system.product'], -+ universal_newlines=True -+ ).rstrip() -+ except FileNotFoundError: -+ return None -+ -+ return f'{vendor} ({product})' diff --git a/sysutils/archey4/files/patch-archey_entries_ram.py b/sysutils/archey4/files/patch-archey_entries_ram.py deleted file mode 100644 index 9beb5f7857d7..000000000000 --- a/sysutils/archey4/files/patch-archey_entries_ram.py +++ /dev/null @@ -1,46 +0,0 @@ ---- archey/entries/ram.py.orig 2022-02-08 18:10:31 UTC -+++ archey/entries/ram.py -@@ -1,5 +1,6 @@ - """RAM usage detection class""" - -+import os - import platform - import re - -@@ -38,6 +39,9 @@ class RAM(Entry): - if platform.system() == 'Linux': - with suppress(IndexError, FileNotFoundError): - return self._run_free_dash_m() -+ elif platform.system() == 'FreeBSD': -+ with suppress(FileNotFoundError): -+ return self._run_sysctl_mem() - else: - # Darwin or any other BSD-based system. - with suppress(FileNotFoundError): -@@ -122,6 +126,26 @@ class RAM(Entry): - ) * page_size - - return (used / 1024**2), (total / 1024**2) -+ -+ @staticmethod -+ def _run_sysctl_mem() -> Tuple[float, float]: -+ """ -+ Return used and total memory on FreeBSD -+ """ -+ output = check_output( -+ ['sysctl', '-n', 'vm.stats.vm.v_page_count', -+ 'vm.stats.vm.v_free_count', -+ 'vm.stats.vm.v_inactive_count'], -+ universal_newlines=True -+ ) -+ total, free, inactive = [float(x) for x in output.splitlines()] -+ -+ page_size = os.sysconf(os.sysconf_names['SC_PAGESIZE']) -+ -+ mem_total = total * (page_size >> 10) -+ mem_used = (total - free - inactive) * (page_size >> 10) -+ -+ return (mem_used / 1024), (mem_total / 1024) - - - def output(self, output):