]> git.pld-linux.org Git - packages/criu.git/blame_incremental - criu.spec
- release 2 (libbpf 1.0.x)
[packages/criu.git] / criu.spec
... / ...
CommitLineData
1# TODO
2# - package static libs
3# /usr/lib/compel/fds.lib.a
4# /usr/lib/compel/scripts/compel-pack.lds.S
5# /usr/lib/compel/std.lib.a
6# /usr/lib64/libcompel.a
7# /usr/lib64/libcriu.a
8#
9# Conditional build:
10%bcond_with tests # build and run tests (requires root)
11
12Summary: Checkpoint/restore functionality for Linux in userspace
13Summary(pl.UTF-8): Funkcja checkpoint/restore w przestrzeni użytkownika dla Linuksa
14Name: criu
15Version: 3.17.1
16Release: 2
17License: GPL v2 (tools), LGPL v2.1 (library)
18Group: Applications/System
19Source0: https://github.com/checkpoint-restore/criu/archive/v%{version}/%{name}-%{version}.tar.gz
20# Source0-md5: f3a5e3c3809177fbd4f543b68b563f5a
21Patch0: %{name}-python.patch
22Patch1: tests.patch
23Patch2: glibc2.36.patch
24URL: http://criu.org/
25BuildRequires: asciidoc
26BuildRequires: gnutls-devel
27BuildRequires: libbpf-devel
28BuildRequires: libbsd-devel
29BuildRequires: libcap-devel
30BuildRequires: libnet-devel
31BuildRequires: libnl-devel >= 1:3.2
32BuildRequires: libselinux-devel
33BuildRequires: nftables-devel
34BuildRequires: pkgconfig
35BuildRequires: protobuf
36BuildRequires: protobuf-c-devel
37BuildRequires: protobuf-devel
38BuildRequires: python3
39BuildRequires: python3-modules
40BuildRequires: rpm-pythonprov
41BuildRequires: rpmbuild(macros) >= 2.007
42BuildRequires: sed >= 4.0
43Requires: %{name}-libs = %{version}-%{release}
44Requires: iproute2 >= 3.5
45Requires: uname(release) >= 3.11
46ExclusiveArch: %{x8664} %{armv7} %{armv8} aarch64 ppc64
47BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
48
49%define _libexecdir %{_prefix}/lib
50
51%description
52Checkpoint/Restore In Userspace, or CRIU, is a software tool for Linux
53operating system. Using this tool, you can freeze a running
54application (or part of it) and checkpoint it to a hard drive as a
55collection of files. You can then use the files to restore and run the
56application from the point it was frozen at. The distinctive feature
57of the CRIU project is that it is mainly implemented in user space.
58
59%description -l en.UTF-8
60Checkpoint/Restore In Userspace, or CRIU (pronounced kree-oo, IPA:
61/krɪʊ/, Russian: криу), is a software tool for Linux operating system.
62Using this tool, you can freeze a running application (or part of it)
63and checkpoint it to a hard drive as a collection of files. You can
64then use the files to restore and run the application from the point
65it was frozen at. The distinctive feature of the CRIU project is that
66it is mainly implemented in user space.
67
68%description -l pl.UTF-8
69CRIU (Checkpoint/Restore In Userspace) to narzędzie programowe dla
70systemu operacyjnego Linux. Przy jego użyciu można zamrozić działającą
71aplikację (lub jej część) i zapisać migawkę na twardym dysku jako
72zestaw plików. Następnie można użyć tych plików do odtworzenia i
73uruchomienia aplikacji od miejsca, w którym została zamrożona.
74Wyróżnikiem projektu CRIU jest to, że został zaimplementowany głównie
75w przestrzeni użytkownika.
76
77%package libs
78Summary: CRIU shared library
79Summary(pl.UTF-8): Biblioteka współdzielona CRIU
80License: LGPL v2.1
81Group: Libraries
82
83%description libs
84CRIU shared library.
85
86%description libs -l pl.UTF-8
87Biblioteka współdzielona CRIU.
88
89%package devel
90Summary: Header files for CRIU library
91Summary(pl.UTF-8): Pliki nagłówkowe biblioteki CRIU
92License: LGPL v2.1
93Group: Development/Libraries
94Requires: %{name}-libs = %{version}-%{release}
95Requires: protobuf-c-devel
96
97%description devel
98Header files for CRIU library.
99
100%description devel -l pl.UTF-8
101Pliki nagłówkowe biblioteki CRIU.
102
103%package -n python3-pycriu
104Summary: Python interface to CRIU
105Summary(pl.UTF-8): Pythonowy interfejs do CRIU
106Group: Libraries/Python
107Requires: %{name}-libs = %{version}-%{release}
108Obsoletes: python-pycriu < 3.16
109
110%description -n python3-pycriu
111Python interface to CRIU. This package contains also crit utility.
112
113%description -n python3-pycriu -l pl.UTF-8
114Pythonowy interfejs do CRIU. Ten pakiet zawiera także narzędzie crit.
115
116%prep
117%setup -q
118%patch0 -p1
119%patch1 -p1
120%patch2 -p1
121
122%{__sed} -i -e 's#-O2 -g#$(OPT)#g' Makefile
123
124%{__sed} -i -e '1 s,#!.*env python.*,#!%{__python3},' scripts/criu-ns
125
126%{__ln_s} scripts/crit-setup.py setup.py
127
128%build
129%define _make_opts \\\
130 DEB_HOST_MULTIARCH= \\\
131 CC="%{__cc}" \\\
132 OPT="%{rpmcppflags} %{rpmcflags}" \\\
133 PREFIX=%{_prefix} \\\
134 LIBDIR=%{_libdir} \\\
135 LOGROTATEDIR=%{_sysconfdir}/logrotate.d \\\
136 LIBEXECDIR=%{_libexecdir} \\\
137 MANDIR=%{_mandir} \\\
138 WERROR=0 \\\
139 SUBARCH=%{_target_cpu} \\\
140 CONFIG_AMDGPU=n \\\
141 V=1
142%{__make}
143
144%py3_build
145
146%if %{with tests}
147%{__make} test
148%endif
149
150%install
151rm -rf $RPM_BUILD_ROOT
152%{__make} install \
153 DESTDIR=$RPM_BUILD_ROOT
154
155%py3_install
156
157install -p contrib/docker_cr.sh $RPM_BUILD_ROOT%{_libexecdir}/%{name}/scripts
158
159# optional scripts, do not autogenerate bash dep
160chmod -x $RPM_BUILD_ROOT%{_libexecdir}/%{name}/scripts/*.sh
161
162%clean
163rm -rf $RPM_BUILD_ROOT
164
165%post libs -p /sbin/ldconfig
166%postun libs -p /sbin/ldconfig
167
168%files
169%defattr(644,root,root,755)
170%doc CREDITS README.md
171%attr(755,root,root) %{_bindir}/compel
172%attr(755,root,root) %{_sbindir}/criu
173%attr(755,root,root) %{_sbindir}/criu-ns
174%{_mandir}/man1/compel.1*
175%{_mandir}/man1/crit.1*
176%{_mandir}/man1/criu-ns.1*
177%{_mandir}/man8/criu.8*
178%dir %{_libexecdir}/%{name}
179%dir %{_libexecdir}/%{name}/scripts
180%attr(755,root,root) %{_libexecdir}/%{name}/scripts/systemd-autofs-restart.sh
181%attr(755,root,root) %{_libexecdir}/%{name}/scripts/docker_cr.sh
182
183%files libs
184%defattr(644,root,root,755)
185%attr(755,root,root) %{_libdir}/libcompel.so.*.*
186%attr(755,root,root) %ghost %{_libdir}/libcompel.so.1
187%attr(755,root,root) %{_libdir}/libcriu.so.*.*
188%attr(755,root,root) %ghost %{_libdir}/libcriu.so.2
189
190%files devel
191%defattr(644,root,root,755)
192%attr(755,root,root) %{_libdir}/libcompel.so
193%attr(755,root,root) %{_libdir}/libcriu.so
194%{_includedir}/compel
195%{_includedir}/criu
196%{_pkgconfigdir}/criu.pc
197
198%files -n python3-pycriu
199%defattr(644,root,root,755)
200%attr(755,root,root) %{_bindir}/crit
201%{py3_sitescriptdir}/pycriu
202%{py3_sitescriptdir}/crit-0.0.1-py*.egg-info
This page took 0.081396 seconds and 5 git commands to generate.