python38-psutil/python38-psutil.spec

64 lines
1.9 KiB
RPMSpec
Raw Permalink Normal View History

2020-05-31 19:16:37 +03:00
%global __provides_exclude ^(python3egg|python3dist)
%global __requires_exclude ^(python3egg|python3dist)
2020-05-31 19:16:34 +03:00
%global srcname psutil
%global sum A process and system utilities module for Python
# Filter Python modules from Provides
2020-05-31 19:16:37 +03:00
%global __provides_exclude_from ^(%{python2_sitearch}|%{python38_sitearch})/.*\\.so$
2020-05-31 19:16:34 +03:00
Name: python-%{srcname}
Version: 5.6.7
2020-05-31 19:16:37 +03:00
Release: 1
2020-05-31 19:16:34 +03:00
Summary: %{sum}
2020-05-31 19:16:37 +03:00
Group: Development/Python
2020-05-31 19:16:34 +03:00
License: BSD
URL: https://github.com/giampaolo/psutil
Source0: https://github.com/giampaolo/psutil/archive/release-%{version}.tar.gz#/%{srcname}-%{version}.tar.gz
BuildRequires: gcc
2020-05-31 19:16:37 +03:00
BuildRequires: python38-devel
2020-05-31 19:16:34 +03:00
%description
psutil is a module providing an interface for retrieving information on all
running processes and system utilization (CPU, memory, disks, network, users) in
a portable way by using Python, implementing many functionalities offered by
command line tools such as: ps, top, df, kill, free, lsof, free, netstat,
ifconfig, nice, ionice, iostat, iotop, uptime, pidof, tty, who, taskset, pmap.
2020-05-31 19:16:37 +03:00
%package -n python38-psutil
2020-05-31 19:16:34 +03:00
Summary: %{sum}
2020-05-31 19:16:37 +03:00
Group: Development/Python
2020-05-31 19:16:34 +03:00
2020-05-31 19:16:37 +03:00
%description -n python38-psutil
2020-05-31 19:16:34 +03:00
psutil is a module providing an interface for retrieving information on all
running processes and system utilization (CPU, memory, disks, network, users) in
a portable way by using Python 3, implementing many functionalities offered by
command line tools such as: ps, top, df, kill, free, lsof, free, netstat,
ifconfig, nice, ionice, iostat, iotop, uptime, pidof, tty, who, taskset, pmap.
%prep
%autosetup -p0 -n %{srcname}-release-%{version}
# Remove shebangs
find psutil -name \*.py | while read file; do
sed -i.orig -e '1{/^#!/d}' $file && \
touch -r $file.orig $file && \
rm $file.orig
done
%build
2020-05-31 19:16:37 +03:00
%py38_build
2020-05-31 19:16:34 +03:00
%install
2020-05-31 19:16:37 +03:00
%py38_install
2020-05-31 19:16:34 +03:00
2020-05-31 19:16:37 +03:00
%files -n python38-%{srcname}
2020-05-31 19:16:34 +03:00
%license LICENSE
%doc CREDITS HISTORY.rst README.rst
2020-05-31 19:16:37 +03:00
%{python38_sitearch}/%{srcname}/
%{python38_sitearch}/*.egg-info