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