/
libseccomp.spec
73 lines (60 loc) · 2.17 KB
/
libseccomp.spec
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
Name: libseccomp
Version: 2.4.2
Release: 1
Summary: An Enhanced Seccomp (mode 2) Helper Library
License: LGPLv2
URL: https://github.com/seccomp/libseccomp.git
Source: https://github.com/seccomp/libseccomp/releases/download/v%{version}/%{name}-%{version}.tar.gz
Patch0: 0001-tests-rely-on-__SNR_xxx-instead-of-__NR_xxx-for-sysc.patch
Patch1: 0002-tests-allow-sb2-to-accelerate-seq-on-SailfishOS.patch
BuildRequires: autoconf
BuildRequires: automake
BuildRequires: fdupes
BuildRequires: libtool
BuildRequires: pkgconfig
%description
The libseccomp library provides and easy to use, platform
independent, interface to the Linux Kernel's syscall filtering
mechanism: seccomp. The libseccomp API is designed to abstract away
the underlying BPF based syscall filter language and present a more
conventional function-call based filtering interface that should be
familiar to, and easily adopted by application developers.
%package devel
Summary: Development files for libseccomp, an enhanced Seccomp (mode 2) helper library
Requires: %name = %version
%description devel
The libseccomp library provides and easy to use, platform
independent, interface to the Linux Kernel's syscall filtering
mechanism: seccomp. The libseccomp API is designed to abstract away
the underlying BPF based syscall filter language and present a more
conventional function-call based filtering interface that should be
familiar to, and easily adopted by application developers.
This package contains the development files and debugging utilities
for libseccomp.
%prep
%autosetup -n %{name}-%{version}/upstream -p1
%build
%autogen
%configure --disable-static
make %{?jobs:-j%jobs}
%install
rm -rf %{buildroot}
%make_install
find "%{buildroot}/%{_libdir}" -type f -name "*.la" -delete;
rm -r %{buildroot}/%{_mandir}
%fdupes %{buildroot}/%{_prefix}
%check
make check
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%files
%defattr(-,root,root)
%_libdir/%name.so.2*
%license LICENSE
%files devel
%defattr(-,root,root)
%_includedir/seccomp.h
%_includedir/seccomp-syscalls.h
%_libdir/%name.so
%_libdir/pkgconfig/%name.pc
%_bindir/scmp_sys_resolver