diff --git a/fedora/SPECS/ngxtop.spec b/fedora/SPECS/ngxtop.spec index 82c7c64..831e671 100644 --- a/fedora/SPECS/ngxtop.spec +++ b/fedora/SPECS/ngxtop.spec @@ -9,9 +9,10 @@ URL: https://github.com/lebinh/ngxtop Source0: ngxtop-%{version}.tgz %define debug_package %{nil} +%define pyvers 3 -BuildRequires: python3 -Requires: python3 +BuildRequires: python%{pyvers} python%{pyvers}-tabulate +Requires: python%{pyvers} python%{pyvers}-tabulate %description ngxtop tries to determine the correct location and format of nginx access log file by default, @@ -25,14 +26,16 @@ specify your log and format, even parse remote Apache common access log with eas %build -python3 setup.py build +#python%{pyvers} setup.py build +%py3_build %install -python3 setup.py install --root=%{buildroot} +#python%{pyvers} setup.py install --no-compile -O1 --skip-build --prefix=%{_prefix} --root=%{buildroot} +%py3_install %clean -[ "%{buildroot}" != "/" ] && [ -d "%{buildroot}" ] && rm -rf %{buildroot}/* -[ "%{_builddir}" != "/" ] && [ -d "%{_builddir}" ] && rm -rf %{_builddir}/* +[ "%{buildroot}" != "/" ] && [ -d "%{buildroot}" ] && rm -rf %{buildroot} +[ "%{_builddir}" != "/" ] && [ -d "%{_builddir}" ] && rm -rf %{_builddir} %files %doc README.rst LICENSE.txt