]> git.pld-linux.org Git - packages/setools.git/blame - setools.spec
- added format-truncation patch from git (fixes build with -Werror=format-truncation)
[packages/setools.git] / setools.spec
CommitLineData
4df63b55
JB
1#
2# Conditional build:
deffcb0e
JB
3%bcond_without python2 # Python 2.x modules
4%bcond_without python3 # Python 3.x modules
4df63b55
JB
5#
6Summary: Policy analysis tools for SELinux
7Summary(pl.UTF-8): Narzędzia do analizy polityk SELinuksa
db420033 8Name: setools
deffcb0e
JB
9Version: 4.1.1
10Release: 1
4df63b55
JB
11License: GPL v2+ (tools), LGPL v2.1+ (libraries)
12Group: Applications/System
deffcb0e
JB
13#Source0Download: https://github.com/TresysTechnology/setools/releases
14Source0: https://github.com/TresysTechnology/setools/archive/%{version}/%{name}-%{version}.tar.gz
15# Source0-md5: 54cf5c0ca2aa4ef7c6ac153981af34cd
68222393
JB
16# https://github.com/TresysTechnology/setools/issues/174
17# https://github.com/bigon/setools/commit/e41adf01647c695b80b112b337e76021bb9f30c3.patch
18Patch0: %{name}-format-truncation.patch
deffcb0e 19URL: https://github.com/TresysTechnology/setools4/wiki
fde4ef77 20BuildRequires: bison
2f15a047 21BuildRequires: flex
deffcb0e
JB
22BuildRequires: libsepol-devel >= 2.7
23BuildRequires: libsepol-static >= 2.7
24%if %{with python2}
25BuildRequires: python-devel >= 1:2.7
26BuildRequires: python-setuptools
27%endif
28%if %{with python3}
29BuildRequires: python3-devel >= 1:3.3
30BuildRequires: python3-setuptools
31%endif
32BuildRequires: rpmbuild(macros) >= 1.714
33BuildRequires: swig-python >= 2.0.12
4df63b55 34Suggests: policy-sources
deffcb0e
JB
35%if %{with python2}
36Requires: python-setools = %{version}-%{release}
37%else
38Requires: python3-setools = %{version}-%{release}
39%endif
db420033
JB
40BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
41
42%description
4df63b55
JB
43SETools is a collection of graphical tools, command-line tools, and
44libraries designed to facilitate SELinux policy analysis.
45
46The base package includes the following console tools:
47- seaudit-report: audit log analysis tool
48- sechecker: SELinux policy checking tool
49- secmds command line tools: seinfo, sesearch, findcon, replcon, and
50 indexcon
51- sediff: semantic policy difference tool
db420033 52
63b63c72 53%description -l pl.UTF-8
4df63b55
JB
54SETools to zbiór narzędzi graficznych, narzędzi linii poleceń oraz
55bibliotek mających na celu ułatwienie analizy polityk SELinuksa.
56
57Pakiet podstawowy zawiera narzędzia terminalowe:
58- seaudit-report - narzędzie do analizy logu audytowego
59- sechecker - narzędzie do sprawdzania polityk SELinuksa
60- narzędzia linii poleceń secmds: seinfo, sesearch, findcon, replcon
61 oraz indexcon
62- sediff - narzędzie do znajdywania różnic semantycznych polityk
63
64%package gui
65Summary: Policy analysis graphical tools for SELinux
66Summary(pl.UTF-8): Graficzne narzędzia do analizy polityk SELinuksa
67License: GPL v2+
68Group: Applications/System
69Requires: %{name} = %{version}-%{release}
deffcb0e
JB
70%if %{with python2}
71Requires: python-setoolsgui = %{version}-%{release}
72%else
73Requires: python3-setoolsgui = %{version}-%{release}
74%endif
4df63b55
JB
75
76%description gui
77SETools is a collection of graphical tools, command-line tools, and
78libraries designed to facilitate SELinux policy analysis.
79
80This package includes the following graphical tools:
81- apol: policy analysis tool
4df63b55
JB
82
83%description gui -l pl.UTF-8
84SETools to zbiór narzędzi graficznych, narzędzi linii poleceń oraz
85bibliotek mających na celu ułatwienie analizy polityk SELinuksa.
86
87Ten pakiet zawiera narzędzia graficzne:
88- apol - narzędzie do analizy polityk
deffcb0e
JB
89
90%package -n python-setools
91Summary: Python 2 bindings for SELinux policy analysis libraries
92Summary(pl.UTF-8): Wiązania Pythona 2 do bibliotek analizy polityk SELinuksa
93License: LGPL v2.1+ (core modules), GPL v2+ (seinfo and sesearch)
94Group: Libraries/Python
95Requires: python-enum34
96Requires: python-modules >= 1:2.7
97Requires: python-networkx >= 1.8
98Suggests: python-selinux
99
100%description -n python-setools
4df63b55
JB
101SETools is a collection of graphical tools, command-line tools, and
102libraries designed to facilitate SELinux policy analysis.
103
deffcb0e
JB
104This package includes Python bindings for SELinux policy analysis
105libraries.
4df63b55 106
deffcb0e 107%description -n python-setools -l pl.UTF-8
4df63b55
JB
108SETools to zbiór narzędzi graficznych, narzędzi linii poleceń oraz
109bibliotek mających na celu ułatwienie analizy polityk SELinuksa.
110
deffcb0e
JB
111Ten pakiet zawiera wiązania Pythona do bibliotek analizy polityk
112SELinuksa.
4df63b55 113
deffcb0e
JB
114%package -n python-setoolsgui
115Summary: SETools GUI modules for Python 2
116Summary(pl.UTF-8): Moduły graficznego interfejsu użytkownika SETools dla Pythona 2
117Group: Libraries/Python
118Requires: python-setools = %{version}-%{release}
119Requires: python-PyQt5 >= 5
4df63b55 120
deffcb0e
JB
121%description -n python-setoolsgui
122SETools GUI modules for Python 2.
4df63b55 123
deffcb0e
JB
124%description -n python-setoolsgui -l pl.UTF-8
125Moduły graficznego interfejsu użytkownika SETools dla Pythona 2.
4df63b55 126
deffcb0e
JB
127%package -n python3-setools
128Summary: Python 3 bindings for SELinux policy analysis libraries
129Summary(pl.UTF-8): Wiązania Pythona 3 do bibliotek analizy polityk SELinuksa
4df63b55 130Group: Libraries/Python
deffcb0e
JB
131%if "%{py3_ver}" < "3.4"
132Requires: python3-enum34
133%endif
134Requires: python3-modules >= 1:3.3
135Requires: python3-networkx >= 1.8
136Suggests: python3-selinux
4df63b55 137
deffcb0e 138%description -n python3-setools
4df63b55
JB
139SETools is a collection of graphical tools, command-line tools, and
140libraries designed to facilitate SELinux policy analysis.
141
deffcb0e
JB
142This package includes Python bindings for SELinux policy analysis
143libraries.
4df63b55 144
deffcb0e 145%description -n python3-setools -l pl.UTF-8
4df63b55
JB
146SETools to zbiór narzędzi graficznych, narzędzi linii poleceń oraz
147bibliotek mających na celu ułatwienie analizy polityk SELinuksa.
148
deffcb0e
JB
149Ten pakiet zawiera wiązania Pythona do bibliotek analizy polityk
150SELinuksa.
4df63b55 151
deffcb0e
JB
152%package -n python3-setoolsgui
153Summary: SETools GUI modules for Python 3
154Summary(pl.UTF-8): Moduły graficznego interfejsu użytkownika SETools dla Pythona 3
155Group: Libraries/Python
156Requires: python3-setools = %{version}-%{release}
157Requires: python3-PyQt5 >= 5
4df63b55 158
deffcb0e
JB
159%description -n python3-setoolsgui
160SETools GUI modules for Python 3.
4df63b55 161
deffcb0e
JB
162%description -n python3-setoolsgui -l pl.UTF-8
163Moduły graficznego interfejsu użytkownika SETools dla Pythona 3.
4d18f116 164
db420033 165%prep
28988f53 166%setup -q
68222393 167%patch0 -p1
db420033
JB
168
169%build
68222393
JB
170export SEPOL=%{_libdir}/libsepol.a
171
deffcb0e
JB
172%if %{with python2}
173%py_build
174%endif
175
176%if %{with python3}
177%py3_build
178%endif
db420033
JB
179
180%install
181rm -rf $RPM_BUILD_ROOT
deffcb0e 182
68222393
JB
183export SEPOL=%{_libdir}/libsepol.a
184
deffcb0e
JB
185%if %{with python3}
186%py3_install
4df63b55
JB
187%endif
188
deffcb0e
JB
189%if %{with python2}
190%py_install
191
192%py_postclean
4df63b55 193%endif
db420033
JB
194
195%clean
196rm -rf $RPM_BUILD_ROOT
197
db420033
JB
198%files
199%defattr(644,root,root,755)
4df63b55 200%attr(755,root,root) %{_bindir}/sediff
deffcb0e 201%attr(755,root,root) %{_bindir}/sedta
4df63b55 202%attr(755,root,root) %{_bindir}/seinfo
deffcb0e 203%attr(755,root,root) %{_bindir}/seinfoflow
4df63b55 204%attr(755,root,root) %{_bindir}/sesearch
4df63b55 205%{_mandir}/man1/sediff.1*
deffcb0e 206%{_mandir}/man1/sedta.1*
4df63b55 207%{_mandir}/man1/seinfo.1*
deffcb0e 208%{_mandir}/man1/seinfoflow.1*
4df63b55 209%{_mandir}/man1/sesearch.1*
4df63b55
JB
210
211%files gui
212%defattr(644,root,root,755)
213%attr(755,root,root) %{_bindir}/apol
4df63b55 214%{_mandir}/man1/apol.1*
4df63b55 215
deffcb0e 216%if %{with python2}
4df63b55
JB
217%files -n python-setools
218%defattr(644,root,root,755)
deffcb0e 219%doc COPYING ChangeLog KNOWN-BUGS README.md
4df63b55 220%dir %{py_sitedir}/setools
deffcb0e
JB
221%{py_sitedir}/setools/diff
222%dir %{py_sitedir}/setools/policyrep
223%attr(755,root,root) %{py_sitedir}/setools/policyrep/_qpol.so
224%{py_sitedir}/setools/policyrep/*.py[co]
225%{py_sitedir}/setools/*.py[co]
226%{py_sitedir}/setools/perm_map
227%{py_sitedir}/setools-%{version}-py*.egg-info
228
229%files -n python-setoolsgui
230%defattr(644,root,root,755)
231%{py_sitedir}/setoolsgui
4df63b55
JB
232%endif
233
deffcb0e
JB
234%if %{with python3}
235%files -n python3-setools
4df63b55 236%defattr(644,root,root,755)
deffcb0e
JB
237%doc COPYING ChangeLog KNOWN-BUGS README.md
238%dir %{py3_sitedir}/setools
239%{py3_sitedir}/setools/diff
240%dir %{py3_sitedir}/setools/policyrep
241%attr(755,root,root) %{py3_sitedir}/setools/policyrep/_qpol.cpython-*.so
242%{py3_sitedir}/setools/policyrep/*.py
243%{py3_sitedir}/setools/policyrep/__pycache__
244%{py3_sitedir}/setools/*.py
245%{py3_sitedir}/setools/perm_map
246%{py3_sitedir}/setools/__pycache__
247%{py3_sitedir}/setools-%{version}-py*.egg-info
248
249%files -n python3-setoolsgui
250%defattr(644,root,root,755)
251%{py3_sitedir}/setoolsgui
252%endif
This page took 0.100467 seconds and 4 git commands to generate.