Accepting request 330893 from home:XRevan86
OBS-URL: https://build.opensuse.org/request/show/330893 OBS-URL: https://build.opensuse.org/package/show/devel:tools/binwalk?expand=0&rev=6
This commit is contained in:
parent
6dccfcfdec
commit
d84165b56e
@ -1,3 +1,16 @@
|
||||
-------------------------------------------------------------------
|
||||
Mon Sep 14 10:56:52 UTC 2015 - sor.alexei@meowr.ru
|
||||
|
||||
- Use Python 3.x in new openSUSE releases.
|
||||
- Use built-in pyqtgraph.
|
||||
- Require "file" instead of python-magic as a shadow ABI-agnostic
|
||||
libmagic dependency.
|
||||
- Avoid depending on library specific ABI by depending on ssdeep
|
||||
instead of libfuzzy2.
|
||||
- Dependencies cleanup.
|
||||
- Add missing optional dependencies.
|
||||
- Spec cleanup.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Jul 1 13:57:37 UTC 2015 - aloisio@gmx.com
|
||||
|
||||
|
91
binwalk.spec
91
binwalk.spec
@ -23,63 +23,84 @@ Summary: Firmware Analysis Tool
|
||||
License: MIT
|
||||
Group: Development/Tools/Debuggers
|
||||
Url: https://github.com/devttys0/binwalk
|
||||
Source0: https://github.com/devttys0/binwalk/archive/v%{version}/binwalk-%{version}.tar.gz
|
||||
Source: https://github.com/devttys0/binwalk/archive/v%{version}.tar.gz#/binwalk-%{version}.tar.gz
|
||||
Source1: binwalk.1
|
||||
BuildRequires: file-devel
|
||||
BuildRequires: python-devel
|
||||
BuildRequires: python-magic
|
||||
%if 0%{?suse_version} >= 1230
|
||||
BuildRequires: libfuzzy-devel
|
||||
%endif
|
||||
# Required by help2man
|
||||
BuildRequires: python-curses
|
||||
BuildRequires: help2man
|
||||
Requires: python-curses
|
||||
Requires: python-magic
|
||||
Requires: python-pyqtgraph
|
||||
Requires: python-scipy
|
||||
# Depends on libmagic.
|
||||
Requires: file
|
||||
Recommends: bzip2
|
||||
Recommends: cabextract
|
||||
Recommends: cpio
|
||||
Recommends: gzip
|
||||
Recommends: p7zip
|
||||
Recommends: unrar
|
||||
Recommends: xz
|
||||
Recommends: zlib
|
||||
Suggests: java
|
||||
%if 0%{?suse_version} >= 1230
|
||||
Requires: libfuzzy2
|
||||
%endif
|
||||
# sle requires it...
|
||||
# Required by help2man.
|
||||
BuildRequires: python3-curses
|
||||
BuildRequires: python3-devel
|
||||
# Depends on libfuzzy.
|
||||
Requires: ssdeep
|
||||
%else
|
||||
# Required by help2man.
|
||||
BuildRequires: python-curses
|
||||
BuildRequires: python-devel
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
|
||||
%endif
|
||||
|
||||
%description
|
||||
Binwalk is a tool for searching a given binary image for embedded files and executable code.
|
||||
Specifically, it is designed for identifying files and code embedded inside of firmware images.
|
||||
Binwalk uses the libmagic library, so it is compatible with magic signatures created for the Unix file utility.
|
||||
Binwalk also includes a custom magic signature file which contains improved signatures for files that are commonly
|
||||
found in firmware images such as compressed/archived files, firmware headers, Linux kernels, bootloaders, filesystems, etc.
|
||||
Binwalk is a tool for searching a given binary image for embedded
|
||||
files and executable code. Specifically, it is designed for
|
||||
identifying files and code embedded inside of firmware images.
|
||||
Binwalk uses the libmagic library, so it is compatible with magic
|
||||
signatures created for the Unix file utility. Binwalk also includes
|
||||
a custom magic signature file which contains improved signatures
|
||||
for files that are commonly found in firmware images such as
|
||||
compressed/archived files, firmware headers, Linux kernels,
|
||||
bootloaders, filesystems, etc.
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
|
||||
%build
|
||||
%configure \
|
||||
%if 0%{?suse_version} >= 1230
|
||||
%configure --disable-bundles
|
||||
--with-python=python3 \
|
||||
--disable-libfuzzy \
|
||||
%else
|
||||
%configure --disable-libmagic --disable-pyqtgraph
|
||||
--with-python=python2 \
|
||||
%endif
|
||||
--disable-libmagic
|
||||
|
||||
make %{?_smp_mflags}
|
||||
%{__python} setup.py build
|
||||
%if 0%{?suse_version} >= 1140
|
||||
%{__python} setup.py install --prefix=%{_prefix} --root=$(pwd)/h2m
|
||||
echo |PYTHONPATH=./h2m/%{_prefix}/%{python_sitelib} help2man -N --version-string=%{version} ./h2m/%{_prefix}/bin/binwalk > binwalk.1
|
||||
rm -rf h2m
|
||||
%if 0%{?suse_version} >= 1230
|
||||
python3 setup.py install --root="$PWD/h2m" --prefix=%{_prefix}
|
||||
export PYTHONPATH=./h2m%{python3_sitelib}
|
||||
help2man -N --version-string=%{version} ./h2m%{_bindir}/binwalk > binwalk.1
|
||||
%else
|
||||
sed -e 's/VERSION_STRING/%{version}/g' %{S:1} > binwalk.1
|
||||
sed -e 's/VERSION_STRING/%{version}/g' %{SOURCE1} > binwalk.1
|
||||
%endif
|
||||
|
||||
%install
|
||||
%{__python} setup.py install --prefix=%{_prefix} --root=%{buildroot}
|
||||
install -Dm0644 binwalk.1 %{buildroot}%{_mandir}/man1/binwalk.1
|
||||
%if 0%{?suse_version} >= 1230
|
||||
python3 setup.py install --root=%{buildroot} --prefix=%{_prefix}
|
||||
%else
|
||||
python2 setup.py install --root=%{buildroot} --prefix=%{_prefix}
|
||||
%endif
|
||||
install -Dm 0644 binwalk.1 %{buildroot}%{_mandir}/man1/binwalk.1
|
||||
|
||||
%files
|
||||
%defattr(-,root,root)
|
||||
%{_bindir}/%{name}
|
||||
%{python_sitelib}/%{name}/
|
||||
%{python_sitelib}/binwalk-*-py%{py_ver}.egg-info
|
||||
%{_mandir}/man1/binwalk.1*
|
||||
%if 0%{?suse_version} >= 1230
|
||||
%{python3_sitelib}/binwalk/
|
||||
%{python3_sitelib}/binwalk-*
|
||||
%else
|
||||
%{python_sitelib}/binwalk/
|
||||
%{python_sitelib}/binwalk-*
|
||||
%endif
|
||||
%{_mandir}/man1/binwalk.1%{?ext_man}
|
||||
|
||||
%changelog
|
||||
|
Loading…
Reference in New Issue
Block a user