From 6fe0006d56450448dfa167c03b65973242db8501acd6437e0d074cbc9daacbf5 Mon Sep 17 00:00:00 2001 From: Alexei Sorokin Date: Fri, 10 Aug 2018 13:06:53 +0000 Subject: [PATCH] Accepting request 628625 from home:scarabeus_iv:branches:devel:tools - Use only python3 variant - Drop argparse dependency - Use %license macro OBS-URL: https://build.opensuse.org/request/show/628625 OBS-URL: https://build.opensuse.org/package/show/devel:tools/binwalk?expand=0&rev=14 --- binwalk.changes | 7 +++++++ binwalk.spec | 54 +++++++++++++++---------------------------------- 2 files changed, 23 insertions(+), 38 deletions(-) diff --git a/binwalk.changes b/binwalk.changes index b9465dc..187142f 100644 --- a/binwalk.changes +++ b/binwalk.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Fri Aug 10 13:00:35 UTC 2018 - tchvatal@suse.com + +- Use only python3 variant +- Drop argparse dependency +- Use %license macro + ------------------------------------------------------------------- Mon Jul 2 19:48:09 UTC 2018 - kstreitova@suse.com diff --git a/binwalk.spec b/binwalk.spec index 6d77545..c85a20a 100644 --- a/binwalk.spec +++ b/binwalk.spec @@ -22,37 +22,30 @@ Release: 0 Summary: Firmware Analysis Tool License: MIT Group: Development/Tools/Debuggers -Url: https://github.com/devttys0/binwalk +URL: https://github.com/devttys0/binwalk Source: https://github.com/devttys0/%{name}/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz +BuildRequires: fdupes +BuildRequires: python-rpm-macros +BuildRequires: python3-curses +BuildRequires: python3-setuptools # Depends on libmagic. Requires: file +Requires: python3-curses +# Depends on libfuzzy. +Requires: ssdeep Recommends: bzip2 Recommends: cabextract Recommends: cpio Recommends: gzip -%if 0%{?suse_version} > 1500 -Recommends: p7zip-full -%else -Recommends: p7zip -%endif Recommends: unrar Recommends: xz Recommends: zlib Suggests: java -BuildRequires: fdupes -%if 0%{?suse_version} >= 1230 -BuildRequires: python3-devel -Requires: python3-curses -# Depends on libfuzzy. -Requires: ssdeep -%else -BuildRequires: python-devel -Requires: python-argparse -Requires: python-curses -BuildRoot: %{_tmppath}/%{name}-%{version}-build -%endif -%if 0%{?suse_version} > 1110 BuildArch: noarch +%if 0%{?suse_version} > 1500 +Recommends: p7zip-full +%else +Recommends: p7zip %endif %description @@ -70,32 +63,17 @@ bootloaders, filesystems, etc. %setup -q %build -%if 0%{?suse_version} >= 1230 -python3 setup.py build -%else -python setup.py build -%endif +%python3_build %install -%if 0%{?suse_version} >= 1230 -python3 setup.py install --root=%{buildroot} --prefix=%{_prefix} -%fdupes %{buildroot}%{python3_sitelib} -%else -python2 setup.py install --root=%{buildroot} --prefix=%{_prefix} -%fdupes %{buildroot}%{python_sitelib} -%endif +%python3_install chmod 644 API.md %files -%defattr(-,root,root) -%doc API.md LICENSE +%license LICENSE +%doc API.md %{_bindir}/%{name} -%if 0%{?suse_version} >= 1230 %{python3_sitelib}/%{name}/ %{python3_sitelib}/%{name}-* -%else -%{python_sitelib}/%{name}/ -%{python_sitelib}/%{name}-* -%endif %changelog