]> git.pld-linux.org Git - packages/yara.git/blame - yara.spec
- release 5 (by relup.sh)
[packages/yara.git] / yara.spec
CommitLineData
c4326b53
ER
1# TODO
2# - http://yara.readthedocs.org/en/latest/gettingstarted.html#compiling-and-installing-yara
c4326b53
ER
3# --enable-cuckoo --enable-magic
4
250157b8
ER
5# Conditional build:
6%bcond_without static_libs # don't build static libraries
74363204 7%bcond_without python2 # CPython 2.x module
395990fa 8%bcond_without crypto # build without tests
250157b8 9
fefa098e 10Summary: The pattern matching swiss knife for malware researchers (and everyone else)
250157b8 11Name: yara
fefa098e 12Version: 3.4.0
aa189c74 13Release: 5
fefa098e 14License: Apache v2.0
250157b8 15Group: Libraries
fefa098e
ER
16Source0: https://github.com/plusvic/yara/archive/v%{version}/%{name}-%{version}.tar.gz
17# Source0-md5: b3f9d4e00c1da4d37af05b1f4488255f
225ba25c 18Patch0: cflags.patch
fefa098e
ER
19URL: http://plusvic.github.io/yara/
20BuildRequires: autoconf
21BuildRequires: automake
22BuildRequires: libtool
395990fa 23%{?with_crypto:BuildRequires: openssl-devel}
250157b8 24BuildRequires: pcre-devel
6316a46a 25BuildRequires: pkgconfig
b022ab29
ER
26BuildRequires: rpmbuild(macros) >= 1.219
27%if %{with python2}
28BuildRequires: python-devel
29BuildRequires: rpm-pythonprov
30%endif
250157b8
ER
31BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
32
33%description
fefa098e
ER
34YARA is a tool aimed at (but not limited to) helping malware
35researchers to identify and classify malware samples. With YARA you
36can create descriptions of malware families (or whatever you want to
37describe) based on textual or binary patterns. Each description, a.k.a
38rule, consists of a set of strings and a boolean expression which
39determine its logic.
250157b8
ER
40
41%package devel
42Summary: Header files for yara library
43Summary(pl.UTF-8): Pliki nagłówkowe biblioteki yara
44Group: Development/Libraries
45Requires: %{name} = %{version}-%{release}
ff681652 46Requires: pcre-devel
250157b8
ER
47
48%description devel
49Header files for yara library.
50
51%description devel -l pl.UTF-8
52Pliki nagłówkowe biblioteki yara.
53
54%package static
55Summary: Static yara library
56Summary(pl.UTF-8): Statyczna biblioteka yara
57Group: Development/Libraries
58Requires: %{name}-devel = %{version}-%{release}
59
60%description static
61Static yara library.
62
63%description static -l pl.UTF-8
64Statyczna biblioteka yara.
65
b022ab29
ER
66%package -n python-%{name}
67Summary: Python bindings to yara library
68Group: Development/Languages/Python
69Requires: python-modules
70
71%description -n python-%{name}
72This is a Python extension that gives you access to YARA's powerful
73features from your own Python scripts.
74
250157b8
ER
75%prep
76%setup -q
225ba25c 77%patch0 -p1
250157b8
ER
78
79%build
fefa098e
ER
80%{__aclocal} -I m4
81%{__libtoolize}
82%{__autoconf}
83%{__autoheader}
84%{__automake}
250157b8 85%configure \
395990fa 86 %{__with_without crypto} \
250157b8
ER
87 %{!?with_static_libs:--disable-static}
88%{__make}
89
74363204 90%if %{with python2}
b022ab29 91cd yara-python
74363204 92%py_build
b022ab29
ER
93%endif
94
250157b8
ER
95%install
96rm -rf $RPM_BUILD_ROOT
250157b8
ER
97%{__make} install \
98 DESTDIR=$RPM_BUILD_ROOT
99
b022ab29 100# obsoleted by pkg-config
74363204 101%{__rm} $RPM_BUILD_ROOT%{_libdir}/libyara.la
b022ab29
ER
102
103%if %{with python2}
104cd yara-python
74363204 105%py_install
b022ab29
ER
106
107%py_ocomp $RPM_BUILD_ROOT%{py_sitedir}
108%py_comp $RPM_BUILD_ROOT%{py_sitedir}
109%py_postclean
110%endif
250157b8
ER
111
112%clean
113rm -rf $RPM_BUILD_ROOT
114
115%post -p /sbin/ldconfig
116%postun -p /sbin/ldconfig
117
118%files
119%defattr(644,root,root,755)
fefa098e 120%doc README.md AUTHORS CONTRIBUTORS
250157b8 121%attr(755,root,root) %{_bindir}/yara
fefa098e 122%attr(755,root,root) %{_bindir}/yarac
250157b8 123%attr(755,root,root) %{_libdir}/libyara.so.*.*.*
fefa098e 124%attr(755,root,root) %ghost %{_libdir}/libyara.so.3
250157b8 125%{_mandir}/man1/yara.1*
fefa098e 126%{_mandir}/man1/yarac.1*
250157b8
ER
127
128%files devel
129%defattr(644,root,root,755)
130%{_includedir}/yara.h
fefa098e 131%{_includedir}/yara
250157b8 132%{_libdir}/libyara.so
fefa098e 133%{_pkgconfigdir}/yara.pc
250157b8
ER
134
135%if %{with static_libs}
136%files static
137%defattr(644,root,root,755)
138%{_libdir}/libyara.a
139%endif
b022ab29
ER
140
141%if %{with python2}
142%files -n python-%{name}
143%defattr(644,root,root,755)
144%doc yara-python/README
145%attr(755,root,root) %{py_sitedir}/yara.so
146%{py_sitedir}/yara_python-*.egg-info
147%endif
This page took 1.013836 seconds and 4 git commands to generate.