File pev.spec of Package pev
#
# spec file for package pev
#
# Copyright (c) 2017, Martin Hauke <mardnh@gmx.de>
#
# 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/
#
Name: pev
Version: 0.81
Release: 1.1
Summary: Text-based tool to analyze PE files
License: GPL-2.0
Group: Productivity/Security
Url: http://pev.sourceforge.net/
Source: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz
BuildRequires: openssl-devel
BuildRequires: pcre-devel
Provides: libpe.so.1()(64bit)
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
pev is a tool to get information of PE32/PE32+ executables (EXE, DLL, OCX etc)
like headers, sections, resources and more.
%prep
%setup -q -n %{name}-%{version}
# FIXME: fix plugin path - should be fixed in the buildsystem
sed -i 's|/usr/local/lib/pev/plugins|%{_libdir}/pev/plugins|g' src/config.c
%build
make prefix=%{_prefix} libdir=%{_libdir} CFLAGS="%{optflags}" %{?_smp_mflags}
%install
%make_install prefix=%{_prefix} libdir=%{_libdir}
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%files
%defattr(-,root,root)
%doc LICENSE LICENSE.OpenSSL README.md
%{_bindir}/ofs2rva
%{_bindir}/pedis
%{_bindir}/pehash
%{_bindir}/pepack
%{_bindir}/peldd
%{_bindir}/peres
%{_bindir}/pescan
%{_bindir}/pesec
%{_bindir}/pestr
%{_bindir}/readpe
%{_bindir}/rva2ofs
%{_libdir}/libpe.so
%{_libdir}/libpe.so.1
%{_libdir}/libpe.so.1.0
%dir %{_libdir}/pev
%dir %{_libdir}/pev/plugins
%{_libdir}/pev/plugins/csv_plugin.so
%{_libdir}/pev/plugins/html_plugin.so
%{_libdir}/pev/plugins/json_plugin.so
%{_libdir}/pev/plugins/text_plugin.so
%{_libdir}/pev/plugins/xml_plugin.so
%dir %{_datadir}/pev
%{_datadir}/pev/userdb.txt
%{_mandir}/man1/*
%changelog
* Tue Jan 10 2017 mardnh@gmx.de
- initial package