]> git.pld-linux.org Git - packages/lxc.git/blame_incremental - lxc.spec
up to 1.0.0-beta2 - added autostart scripts
[packages/lxc.git] / lxc.spec
... / ...
CommitLineData
1#
2# Conditional build:
3%bcond_without seccomp # SecComp syscall filter
4%bcond_without apparmor # apparmor
5%bcond_without lua # Lua binding
6%bcond_without python # Python binding
7%bcond_with selinux # SELinux
8
9%define subver beta2
10%define rel 0.1
11Summary: Linux Containers userspace tools
12Summary(pl.UTF-8): Narzędzia do kontenerów linuksowych (LXC)
13Name: lxc
14Version: 1.0.0
15Release: 0.%{subver}.%{rel}
16License: LGPL v2.1+
17Group: Applications/System
18Source0: https://github.com/lxc/lxc/archive/%{name}-%{version}.%{subver}.tar.gz
19# Source0-md5: cdb6b00594ae3423c0745e4e24d807c7
20Source1: %{name}-pld.in.sh
21Patch1: %{name}-pld.patch
22Patch4: checkconfig-vserver-config.patch
23URL: http://linuxcontainers.org/
24BuildRequires: autoconf >= 2.50
25BuildRequires: automake
26BuildRequires: docbook-dtd30-sgml
27BuildRequires: docbook-utils
28BuildRequires: docbook2X
29BuildRequires: gnutls-devel
30%{?with_apparmor:BuildRequires: libapparmor-devel}
31BuildRequires: libcap-devel
32%{?with_seccomp:BuildRequires: libseccomp-devel}
33%{?with_lua:BuildRequires: lua51-devel >= 5.1}
34BuildRequires: pkgconfig
35%{?with_python:BuildRequires: python3-devel >= 3.2}
36BuildRequires: rpmbuild(macros) >= 1.612
37BuildRequires: sed >= 4.0
38Requires: rc-scripts >= 0.4.6
39Requires: which
40Suggests: net-tools
41Suggests: rsync
42BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
43
44%define configpath /var/lib/lxc
45
46%description
47Tools to create and manage containers. It contains a full featured
48container with the isolation / virtualization of the pids, the ipc,
49the utsname, the mount points, /proc, /sys, the network and it takes
50into account the control groups. It is very light, flexible, and
51provides a set of tools around the container like the monitoring with
52asynchronous events notification, or the freeze of the container. This
53package is useful to create Virtual Private Server, or to run isolated
54applications like bash or sshd.
55
56%description -l pl.UTF-8
57Narzędzia do tworzenia i zarządzania kontenerami. System ten obejmuje
58w pełni funkcjonalne kontenery z ilozacją/wirtualizacją pidów, ipc,
59utsname, punktów montowania, /proc, /sys, sieci oraz uwzględniające
60grupy kontrolne. Jest bardzo lekki, elastyczny i udostępnia narzędzia
61do czynności związanych z kontenerami, takich jak monitorowanie z
62asynchronicznym powiadamianiem o zdarzeniach czy zamrażanie. Ten
63pakiet jest przydatny do tworzenia wirtualnych serwerów prywatnych
64oraz uruchamiania izolowanych aplikacji, takich jak bash czy sshd.
65
66%package devel
67Summary: Header files for lxc library
68Summary(pl.UTF-8): Pliki nagłówkowe biblioteki lxc
69Group: Development/Libraries
70Requires: %{name} = %{version}-%{release}
71
72%description devel
73Header files for lxc library.
74
75%description devel -l pl.UTF-8
76Pliki nagłówkowe biblioteki lxc.
77
78%package -n lua-lxc
79Summary: Lua binding for LXC
80Summary(pl.UTF-8): Wiązanie Lua do LXC
81Group: Libraries
82Requires: %{name} = %{version}-%{release}
83Requires: lua51-libs >= 5.1
84
85%description -n lua-lxc
86Lua binding for LXC.
87
88%description -n lua-lxc -l pl.UTF-8
89Wiązanie Lua do LXC.
90
91%package -n python3-lxc
92Summary: Python (3.x) binding for LXC
93Summary(pl.UTF-8): Wiązanie Pythona (3.x) do LXC
94Group: Libraries
95Requires: %{name} = %{version}-%{release}
96Requires: python3-libs >= 3.2
97Requires: python3-modules
98
99%description -n python3-lxc
100Python (3.x) binding for LXC.
101
102%description -n python3-lxc -l pl.UTF-8
103Wiązanie Pythona (3.x) do LXC.
104
105%prep
106%setup -q -n %{name}-%{name}-%{version}%{?subver:.%{subver}}
107%patch1 -p1
108%patch4 -p1
109
110cp -p %{SOURCE1} templates/lxc-pld.in
111
112%build
113%{__aclocal} -I config
114%{__autoconf}
115%{__autoheader}
116%{__automake}
117%configure \
118 db2xman=docbook2X2man \
119 --disable-rpath \
120 --enable-doc \
121 --enable-examples \
122 %{__enable_disable apparmor} \
123 %{__enable_disable lua} %{?with_lua:--with-lua-pc=lua51} \
124 %{__enable_disable python} \
125 %{__enable_disable seccomp} \
126 %{__enable_disable selinux} \
127 --with-config-path=%{configpath} \
128 --with-init-script=sysv,systemd \
129 --with-distro=pld
130
131%{__make}
132%{__make} -C doc
133
134%install
135rm -rf $RPM_BUILD_ROOT
136install -d $RPM_BUILD_ROOT{%{configpath},/var/{cache,log}/lxc}
137%{__make} install \
138 SYSTEMD_UNIT_DIR=%{systemdunitdir} \
139 pcdatadir=%{_pkgconfigdir} \
140 DESTDIR=$RPM_BUILD_ROOT
141
142%{__make} -C doc install \
143 DESTDIR=$RPM_BUILD_ROOT
144
145%{__rm} -r $RPM_BUILD_ROOT%{_docdir}
146
147%if %{with python}
148%py3_comp $RPM_BUILD_ROOT%{py3_sitedir}/lxc
149%py3_ocomp $RPM_BUILD_ROOT%{py3_sitedir}/lxc
150%endif
151%if %{with lua}
152%{__sed} -i -e '1s,#!/usr/bin/env lua,#!/usr/bin/lua51,' $RPM_BUILD_ROOT%{_bindir}/lxc-top
153%endif
154
155%clean
156rm -rf $RPM_BUILD_ROOT
157
158%post -p /sbin/ldconfig
159%postun -p /sbin/ldconfig
160
161%files
162%defattr(644,root,root,755)
163%doc AUTHORS CONTRIBUTING MAINTAINERS README TODO doc/FAQ.txt doc/examples/*.conf
164%attr(755,root,root) %{_bindir}/lxc-attach
165%attr(755,root,root) %{_bindir}/lxc-autostart
166%attr(755,root,root) %{_bindir}/lxc-cgroup
167%attr(755,root,root) %{_bindir}/lxc-checkconfig
168%attr(755,root,root) %{_bindir}/lxc-checkpoint
169%attr(755,root,root) %{_bindir}/lxc-clone
170%attr(755,root,root) %{_bindir}/lxc-config
171%attr(755,root,root) %{_bindir}/lxc-console
172%attr(755,root,root) %{_bindir}/lxc-create
173%attr(755,root,root) %{_bindir}/lxc-destroy
174%attr(755,root,root) %{_bindir}/lxc-execute
175%attr(755,root,root) %{_bindir}/lxc-freeze
176%attr(755,root,root) %{_bindir}/lxc-info
177%attr(755,root,root) %{_bindir}/lxc-kill
178%attr(755,root,root) %{_bindir}/lxc-monitor
179%attr(755,root,root) %{_bindir}/lxc-monitord
180%attr(755,root,root) %{_bindir}/lxc-netstat
181%attr(755,root,root) %{_bindir}/lxc-ps
182%attr(755,root,root) %{_bindir}/lxc-restart
183%attr(755,root,root) %{_bindir}/lxc-snapshot
184%attr(755,root,root) %{_bindir}/lxc-start
185%attr(755,root,root) %{_bindir}/lxc-stop
186%attr(755,root,root) %{_bindir}/lxc-unfreeze
187%attr(755,root,root) %{_bindir}/lxc-unshare
188%attr(755,root,root) %{_bindir}/lxc-user-nic
189%attr(755,root,root) %{_bindir}/lxc-usernsexec
190%attr(755,root,root) %{_bindir}/lxc-version
191%attr(755,root,root) %{_bindir}/lxc-wait
192%attr(755,root,root) %{_libdir}/liblxc.so.*.*.*
193%attr(755,root,root) %ghost %{_libdir}/liblxc.so.1
194%attr(754,root,root) /etc/rc.d/init.d/lxc
195%{systemdunitdir}/lxc.service
196%dir %{_libdir}/lxc
197%dir %{_libdir}/lxc/rootfs
198%{_libdir}/lxc/rootfs/README
199%attr(755,root,root) %{_libdir}/lxc/lxc-devsetup
200%attr(755,root,root) %{_libdir}/lxc/lxc-init
201%dir %{_sysconfdir}/lxc
202%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/lxc/default.conf
203%dir %{_datadir}/%{name}
204%{_datadir}/%{name}/lxc.functions
205%dir %{_datadir}/%{name}/config
206%{_datadir}/%{name}/config/debian*.conf
207%{_datadir}/%{name}/config/oracle*.conf
208%{_datadir}/%{name}/config/plamo*.conf
209%{_datadir}/%{name}/config/ubuntu*.conf
210%dir %{_datadir}/%{name}/hooks
211%dir %{_datadir}/%{name}/templates
212%attr(755,root,root) %{_datadir}/%{name}/hooks/clonehostname
213%attr(755,root,root) %{_datadir}/%{name}/hooks/mount*
214%attr(755,root,root) %{_datadir}/%{name}/hooks/squid-deb-proxy-client
215%attr(755,root,root) %{_datadir}/%{name}/hooks/ubuntu-cloud-prep
216%attr(755,root,root) %{_datadir}/%{name}/templates/lxc-*
217%{_mandir}/man1/lxc-attach.1*
218%{_mandir}/man1/lxc-autostart.1*
219%{_mandir}/man1/lxc-cgroup.1*
220%{_mandir}/man1/lxc-checkconfig.1*
221%{_mandir}/man1/lxc-checkpoint.1*
222%{_mandir}/man1/lxc-clone.1*
223%{_mandir}/man1/lxc-console.1*
224%{_mandir}/man1/lxc-create.1*
225%{_mandir}/man1/lxc-destroy.1*
226%{_mandir}/man1/lxc-execute.1*
227%{_mandir}/man1/lxc-freeze.1*
228%{_mandir}/man1/lxc-info.1*
229%{_mandir}/man1/lxc-kill.1*
230%{_mandir}/man1/lxc-monitor.1*
231%{_mandir}/man1/lxc-netstat.1*
232%{_mandir}/man1/lxc-ps.1*
233%{_mandir}/man1/lxc-restart.1*
234%{_mandir}/man1/lxc-snapshot.1*
235%{_mandir}/man1/lxc-start.1*
236%{_mandir}/man1/lxc-stop.1*
237%{_mandir}/man1/lxc-unfreeze.1*
238%{_mandir}/man1/lxc-unshare.1*
239%{_mandir}/man1/lxc-user-nic.1*
240%{_mandir}/man1/lxc-version.1*
241%{_mandir}/man1/lxc-wait.1*
242%{_mandir}/man5/lxc-usernet.5*
243%{_mandir}/man5/lxc.conf.5*
244%{_mandir}/man7/lxc.7*
245%lang(ja) %{_mandir}/ja/man1/lxc*.1*
246%lang(ja) %{_mandir}/ja/man5/lxc-usernet.5*
247%lang(ja) %{_mandir}/ja/man5/lxc.conf.5*
248%lang(ja) %{_mandir}/ja/man7/lxc.7*
249%exclude %{_mandir}/ja/man1/lxc-device.1*
250%exclude %{_mandir}/ja/man1/lxc-ls.1*
251%exclude %{_mandir}/ja/man1/lxc-start-ephemeral.1*
252%exclude %{_mandir}/ja/man1/lxc-top.1*
253
254%if %{without python}
255# legacy version
256%attr(755,root,root) %{_bindir}/lxc-ls
257%{_mandir}/man1/lxc-ls.1*
258%endif
259
260%dir %{configpath}
261%dir %attr(750,root,root) /var/log/lxc
262%dir %attr(750,root,root) /var/cache/lxc
263
264%files devel
265%defattr(644,root,root,755)
266%attr(755,root,root) %{_libdir}/liblxc.so
267%{_includedir}/lxc
268%{_pkgconfigdir}/lxc.pc
269
270%if %{with lua}
271%files -n lua-lxc
272%defattr(644,root,root,755)
273%attr(755,root,root) %{_bindir}/lxc-top
274%dir %{_libdir}/lua/lxc
275%attr(755,root,root) %{_libdir}/lua/lxc/core.so
276%{_datadir}/lua/lxc.lua
277%{_mandir}/man1/lxc-top.1*
278%lang(ja) %{_mandir}/ja/man1/lxc-top.1*
279%endif
280
281%if %{with python}
282%files -n python3-lxc
283%defattr(644,root,root,755)
284%attr(755,root,root) %{_bindir}/lxc-device
285%attr(755,root,root) %{_bindir}/lxc-ls
286%attr(755,root,root) %{_bindir}/lxc-start-ephemeral
287%{py3_sitedir}/lxc
288%attr(755,root,root) %{py3_sitedir}/_lxc.cpython-*.so
289%{py3_sitedir}/_lxc-0.1-py*.egg-info
290%{_mandir}/man1/lxc-device.1*
291%{_mandir}/man1/lxc-ls.1*
292%{_mandir}/man1/lxc-start-ephemeral.1*
293%lang(ja) %{_mandir}/ja/man1/lxc-device.1*
294%lang(ja) %{_mandir}/ja/man1/lxc-ls.1*
295%lang(ja) %{_mandir}/ja/man1/lxc-start-ephemeral.1*
296%endif
This page took 0.02703 seconds and 4 git commands to generate.