From dd56025b4a7baa1a566ec298e0fd1a50b39e50f2dbd3a232fc632ab98b134410 Mon Sep 17 00:00:00 2001 From: Dirk Mueller Date: Tue, 6 Sep 2011 06:29:59 +0000 Subject: [PATCH] Accepting request 79901 from home:bmanojlovic Firmware Analysis Tool OBS-URL: https://build.opensuse.org/request/show/79901 OBS-URL: https://build.opensuse.org/package/show/devel:tools/binwalk?expand=0&rev=1 --- .gitattributes | 23 +++++++++++++ .gitignore | 1 + binwalk-0.3.8.tar.bz2 | 3 ++ binwalk.changes | 5 +++ binwalk.spec | 77 +++++++++++++++++++++++++++++++++++++++++++ 5 files changed, 109 insertions(+) create mode 100644 .gitattributes create mode 100644 .gitignore create mode 100644 binwalk-0.3.8.tar.bz2 create mode 100644 binwalk.changes create mode 100644 binwalk.spec diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -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 diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..57affb6 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.osc diff --git a/binwalk-0.3.8.tar.bz2 b/binwalk-0.3.8.tar.bz2 new file mode 100644 index 0000000..8e01a53 --- /dev/null +++ b/binwalk-0.3.8.tar.bz2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a6e9b0053ccdf28eb69eb299676142e0382cd2fcf5a38dfcc3e328bb24d16894 +size 673490 diff --git a/binwalk.changes b/binwalk.changes new file mode 100644 index 0000000..d022801 --- /dev/null +++ b/binwalk.changes @@ -0,0 +1,5 @@ +------------------------------------------------------------------- +Tue Aug 23 12:39:24 UTC 2011 - boris@steki.net + +- Initial packaging of 0.3.8 version + diff --git a/binwalk.spec b/binwalk.spec new file mode 100644 index 0000000..ac9134e --- /dev/null +++ b/binwalk.spec @@ -0,0 +1,77 @@ +# +# spec file for package +# +# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany. +# +# 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 http://bugs.opensuse.org/ +# + +# norootforbuild + +Name: binwalk +Version: 0.3.8 +Release: 0 +License: MIT +Summary: Firmware Analysis Tool +Url: http://code.google.com/p/binwalk/ +Group: Development/Tools/Debuggers +# Real source http://binwalk.googlecode.com/files/{name}-{version}.tar.gz +Source: %{name}-%{version}.tar.bz2 +BuildRequires: libcurl-devel +BuildRequires: zlib-devel +BuildRequires: help2man +BuildRoot: %{_tmppath}/%{name}-%{version}-build + +%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. + +%prep +%setup -q + +%build +cd src +%configure +make %{?_smp_mflags} + +# used for older versions of help2man - read SLE... +%if 0%{?sles_version} +cp binwalk binwalk.bin; echo '#!/bin/sh' > binwalk.sh;echo './binwalk.bin $* 2>&1' >> binwalk.sh; chmod 755 binwalk.sh; help2man -N --help-option="-h" --version-option="-h" ./binwalk.sh |sed -e 's/binwalk.bin/binwalk/g' |gzip -9 - > binwalk.1.gz +%else +help2man --no-discard-stderr --help-option="-h" --version-option="-h" ./binwalk |gzip -9 - > binwalk.1.gz +%endif + +%install +cd src +make install DESTDIR=%{buildroot} +install -p -D -m 0644 binwalk.1.gz %{buildroot}/%{_mandir}/man1/binwalk.1.gz +# I really do not know why it likes this... +rm %{buildroot}/%{_sysconfdir}/binwalk/magic.o +%clean +%{?buildroot:%__rm -rf "%{buildroot}"} + + +%files +%defattr(-,root,root) +%doc docs/README +%dir %{_sysconfdir}/binwalk/ +%config %{_sysconfdir}/binwalk/magic.binarch +%config %{_sysconfdir}/binwalk/magic.bincast +%config %{_sysconfdir}/binwalk/magic.binwalk +%{_bindir}/binwalk +%{_mandir}/man1/binwalk.1.gz + +%changelog +