Sync from SUSE:SLFO:Main python-py-cpuinfo revision d8abeb329686844dc00e25b6bdac31a6

This commit is contained in:
Adrian Schröter 2024-05-03 22:00:19 +02:00
commit 68931ab707
4 changed files with 254 additions and 0 deletions

23
.gitattributes vendored Normal file
View File

@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

BIN
py-cpuinfo-9.0.0.tar.gz (Stored with Git LFS) Normal file

Binary file not shown.

141
python-py-cpuinfo.changes Normal file
View File

@ -0,0 +1,141 @@
-------------------------------------------------------------------
Fri Apr 21 12:30:13 UTC 2023 - Dirk Müller <dmueller@suse.com>
- add sle15_python_module_pythons (jsc#PED-68)
-------------------------------------------------------------------
Thu Apr 13 22:43:28 UTC 2023 - Matej Cepl <mcepl@suse.com>
- Make calling of %{sle15modernpython} optional.
-------------------------------------------------------------------
Fri Nov 11 09:43:10 UTC 2022 - Daniel Garcia <daniel.garcia@suse.com>
- Remove rpmlint errors:
* Use postun instead of preun for update-alternatives
* Remove shebang from py files
* More specific python_sitelib in %files
* Remove python_module macro definition
-------------------------------------------------------------------
Wed Nov 9 18:28:08 UTC 2022 - Yogalakshmi Arunachalam <yarunachalam@suse.com>
- Update to Release 9.0.0
* Fixed Bug #178: Changes to lscpu breaks parsing of cache info
* Fixed Bug #152: CPU stepping, model, and family values are blank if 0
* Fixed Bug #177: Officially drop support for Python 2
* Fixed Bug #171: Replace Python 3.11 deprecated unittest.makeSuite
* Fixed Bug #173: Fix lgtm.com alerts
* Fixed Bug #165: Support Wheel
* Fixed Bug #167: Add support for RISC-V
-------------------------------------------------------------------
Sun Jun 6 11:53:50 UTC 2021 - Dirk Müller <dmueller@suse.com>
- update to 8.0.0:
* Fixed Bug #161: Accept arm64 as an alias for aarch64
* Fixed Bug #160: Add MIPS architecture support
* Fixed Bug #74: Add option to trace code paths to file
* Fixed Bug #157: Remove multiple checks for sestatus
-------------------------------------------------------------------
Wed Sep 16 21:06:31 UTC 2020 - Dirk Mueller <dmueller@suse.com>
- update to 7.0.0:
* CPU flags vary between runs on Mac OS X
* Change 'byte code' to 'machine code'
* Overhead from generating machine code throws off CPUID HZ
* On non BeOS systems, calling sysinfo may open GUI program
* Invalid escape sequences warn when building in Python 3.8
* Remove extended_model and extended_family fields
* Remove empty and zeroed fields
* Missing data on Ryzen CPUs
* Rename fields to be more clear
* Add option to return --version
* Make test suite also check SELinux
* Make unit tests also test CPUID
* Add s390x support
-------------------------------------------------------------------
Wed May 22 13:40:11 UTC 2019 - Marketa Calabkova <mcalabkova@suse.com>
- update to version 5.0.0
* Fixed Bug #117: Remove PyInstaller hacks
* Fixed Bug #108: Client script runs multiple times without __main__
* Fixed Bug #113: Add option to return results in json
* Fixed Bug #110: Always tries to run wmic in get_system_info.py
v4.0.0
* Fixed Bug #80: Broken when using Pyinstaller
* Fixed Bug #77: Get L1, L2, and L3 cache info from lscpu
* Fixed Bug #79: Byte formats are inconsistent
* Fixed Bug #81: Byte formatter breaks on non strings
* Fixed Bug #95: Include if Python is 32 or 64 bit in get_system_info
* Fixed Bug #87: lscpu gets brand field twice
* Fixed Bug #96: Include Python version in output
* Fixed Bug #85: CPUID HZ measurement is scaled wrong
* Fixed Bug #100: Officially drop support for Python 2.6
* Fixed Bug #101: Made it only check the dmesg boot log on Linux
v3.3.0
* Fixed Bug #72: Fails to parse invalid CPUID result.
- removed remove-arch-check.patch -- testsuite runs
-------------------------------------------------------------------
Mon Feb 4 16:31:12 UTC 2019 - schwab@suse.de
- remove-arch-check.patch: disable arch check that breaks the testsuite
-------------------------------------------------------------------
Wed Dec 19 00:06:15 UTC 2018 - Jan Engelhardt <jengelh@inai.de>
- Use noun phrase in summary. Trim build process from description.
-------------------------------------------------------------------
Tue Dec 4 12:52:00 UTC 2018 - Matej Cepl <mcepl@suse.com>
- Remove superfluous devel dependency for noarch package
-------------------------------------------------------------------
Wed Apr 19 15:46:57 UTC 2017 - toddrme2178@gmail.com
- Update to 3.1.0
* Fixed Bug #63: Include py-cpuinfo version in output
* Fixed Bug #29: Missing AVX2 CPU flag on OS X
* Fixed Bug #41: Broken on Odroid XU3 armhf ARM 32bit
* Fixed Bug #61: Not working on RHEL7.3 ppc64le
* Fixed Bug #56: Not working on Red Flag Linux ppc64le
* Fixed Bug #55: Not working on Fedora 24 ppc64le
- Update to 3.0.0
* Change API to hide low level functions
* Fixed Bug #51: Combine data from all sources instead of picking one
* Fixed Bug #59: Not working on OS X 10.12 Sierra
* Fixed Bug #58: Change version number format
* Fixed Bug #60: Not working on ARM64 odroid-c2
- Update to 0.2.7
* Fixed Bug #53: CPUID breaks test suite when SE Linux is on (Fedora 25)
* Fixed Bug #54: CPUID breaks when it returns nothing (Fedora 26)
- Update to 0.2.6
* New release because pypi does not allow deleting broken uploads
- Update to 0.2.5
* New release because pypi does not allow deleting broken uploads
- Update to 0.2.4
* Fixed Bug #35: Add basic documentation
* Fixed Bug #36: Make test suite test real functions too
* Fixed Bug #38: get_cpu_info_from_cpuid breaks with Python3
* Fixed Bug #47: Include sysctl leaf7_features and extfeatures flags
- Implement single-spec version
-------------------------------------------------------------------
Tue Aug 16 15:46:46 UTC 2016 - toddrme2178@gmail.com
- Initial python 2 version.
-------------------------------------------------------------------
Tue Aug 16 15:42:24 UTC 2016 - toddrme2178@gmail.com
- Implement update-alternatives
-------------------------------------------------------------------
Tue Jul 5 03:04:57 UTC 2016 - arun@gmx.de
- initial version

87
python-py-cpuinfo.spec Normal file
View File

@ -0,0 +1,87 @@
#
# spec file for package python-py-cpuinfo
#
# Copyright (c) 2023 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%bcond_without tests
%{?sle15_python_module_pythons}
Name: python-py-cpuinfo
Version: 9.0.0
Release: 0
Summary: Python library and tool to get CPU info
License: MIT
Group: Development/Languages/Python
URL: https://github.com/workhorsy/py-cpuinfo
Source: https://files.pythonhosted.org/packages/source/p/py-cpuinfo/py-cpuinfo-%{version}.tar.gz
BuildRequires: %{python_module setuptools}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
Requires(post): update-alternatives
Requires(postun):update-alternatives
BuildArch: noarch
%python_subpackages
%description
Py-cpuinfo gets CPU info with pure Python. Py-cpuinfo should work
without any extra programs or libraries, beyond what your OS
provides. It supports Linux, OS X, Windows, BSD, Solaris,
Cygwin, Haiku, and BeagleBone, but only on x86 and some ARM CPUs.
These approaches are used for getting info:
1. Windows Registry (Windows)
2. /proc/cpuinfo (Linux)
3. sysctl (OS X)
4. dmesg (Unix/Linux)
5. isainfo and kstat (Solaris)
6. cpufreq-info (BeagleBone)
7. lscpu (Unix/Linux)
8. sysinfo (Haiku)
9. Querying the CPUID register (Intel X86 CPUs)
%prep
%setup -q -n py-cpuinfo-%{version}
# remove shebang
sed -i '1{ /^#!/d; }' cpuinfo/*.py
%build
%python_build
%install
%python_install
%python_expand %fdupes %{buildroot}%{$python_sitelib}
# Prepare for update-alternatives usage
%python_clone -a %{buildroot}%{_bindir}/cpuinfo
%if %{with tests}
%check
%python_exec test_suite.py
%endif
%post
%python_install_alternative cpuinfo
%postun
%python_uninstall_alternative cpuinfo
%files %{python_files}
%license LICENSE
%doc README.rst ChangeLog
%python_alternative %{_bindir}/cpuinfo
%{python_sitelib}/cpuinfo
%{python_sitelib}/py_cpuinfo-%{version}*-info
%changelog