]> git.pld-linux.org Git - packages/ploop.git/blob - ploop.spec
1ed8850ca4f268dfd4c18b2d3729923a8e5b7058
[packages/ploop.git] / ploop.spec
1 Summary:        Tools for ploop devices and images
2 Summary(pl.UTF-8):      Narzędzia do urządzeń i obrazów ploop
3 Name:           ploop
4 Version:        8.0.14
5 Release:        1
6 License:        GPL v2+
7 Group:          Applications/System
8 #Source0Download: https://github.com/OpenVZ/ploop/releases
9 Source0:        https://github.com/OpenVZ/ploop/archive/v%{version}/%{name}-%{version}.tar.gz
10 # Source0-md5:  76bc12dd67ed9201d02bc156fbb6a17a
11 Patch0:         %{name}-types.patch
12 Patch1:         %{name}-python.patch
13 URL:            https://wiki.openvz.org/Ploop
14 BuildRequires:  libxml2-devel >= 2.0
15 BuildRequires:  python3-devel >= 1:3.2
16 BuildRequires:  rpmbuild(macros) >= 1.673
17 BuildRequires:  sed >= 4.0
18 Requires:       %{name}-libs = %{version}-%{release}
19 Requires:       /sbin/modprobe
20 Requires:       awk
21 Requires:       parted
22 Requires:       sed
23 Requires:       udev-core >= 1:182-6
24 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
25
26 %description
27 This package contains tools to work with ploop devices and images.
28
29 %description -l pl.UTF-8
30 Ten pakiet zawiera narzędzia do pracy z urządzeniami o obrazami ploop.
31
32 %package -n bash-completion-ploop
33 Summary:        Bash completion for ploop commands
34 Summary(pl.UTF-8):      Bashowe dopełnianie składni poleceń ploop
35 Group:          Applications/Shells
36 Requires:       %{name} = %{version}-%{release}
37 Requires:       bash-completion >= 2.0
38
39 %description -n bash-completion-ploop
40 Bash completion for ploop commands.
41
42 %description -n bash-completion-ploop -l pl.UTF-8
43 Bashowe dopełnianie składni poleceń ploop.
44
45 %package libs
46 Summary:        ploop library
47 Summary(pl.UTF-8):      Biblioteka ploop
48 Group:          Libraries
49 Obsoletes:      ploop-lib
50
51 %description libs
52 Parallels loopback (ploop) block device API library.
53
54 %description libs -l pl.UTF-8
55 Biblioteka do obsługi urządzeń blokowych ploop (Parallels loopback).
56
57 %package devel
58 Summary:        Header files for ploop library
59 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki ploop
60 Group:          Development/Libraries
61 Requires:       %{name}-libs = %{version}-%{release}
62
63 %description devel
64 Header files for ploop library.
65
66 %description devel -l pl.UTF-8
67 Pliki nagłówkowe biblioteki ploop.
68
69 %package static
70 Summary:        Static ploop library
71 Summary(pl.UTF-8):      Biblioteka statyczna ploop
72 Group:          Libraries
73 Requires:       %{name}-devel = %{version}-%{release}
74
75 %description static
76 Static ploop library.
77
78 %description static -l pl.UTF-8
79 Biblioteka statyczna ploop.
80
81 %package -n python3-libploop
82 Summary:        Python 3 interface to ploop library
83 Summary(pl.UTF-8):      Interfejs Pythona 3 do biblioteki ploop
84 Group:          Libraries/Python
85 Requires:       %{name} = %{version}-%{release}
86
87 %description -n python3-libploop
88 Python 3 interface to ploop library.
89
90 %description -n python3-libploop -l pl.UTF-8
91 Interfejs Pythona 3 do biblioteki ploop.
92
93 %prep
94 %setup -q
95 %patch0 -p1
96 %patch1 -p1
97
98 # honour %{_libexecdir} whatever it's set to
99 %{__sed} -i -e '/exe = / s,/usr/libexec,%{_libexecdir},' scripts/crypthelper
100 %{__sed} -i -e '/define CRYPT_BIN/ s,/usr/libexec,%{_libexecdir},' lib/crypt.c
101 # drop /usr/libexec/{tune,resize,dumpe}2fs from tools search
102 %{__sed} -i -e '/\/usr\/libexec\/.*2fs/d' lib/fsutils.c
103
104 %build
105 LDFLAGS="%{rpmldflags}" \
106 LDLIBS="-lpthread" \
107 %{__make} all \
108         V=1 \
109         DEBUG= \
110         CC="%{__cc}" \
111         CPPFLAGS="%{rpmcppflags}" \
112         RPM_OPT_FLAGS="%{rpmcflags}" \
113         LIBDIR=%{_libdir}
114
115 %install
116 rm -rf $RPM_BUILD_ROOT
117
118 %{__make} install \
119         V=1 \
120         INSTALL="install -p" \
121         COMPLETIONDIR=%{bash_compdir} \
122         LIBDIR=%{_libdir} \
123         LIBSCRIPTDIR=%{_libexecdir}/ploop \
124         DESTDIR=$RPM_BUILD_ROOT
125
126 %{__rm} $RPM_BUILD_ROOT%{_sbindir}/ploop-test
127 %{__rm} -r $RPM_BUILD_ROOT/usr/libexec/ploop-test
128
129 %py3_comp $RPM_BUILD_ROOT%{py3_sitedir}
130 %py3_ocomp $RPM_BUILD_ROOT%{py3_sitedir}
131
132 %clean
133 rm -rf $RPM_BUILD_ROOT
134
135 %post   libs -p /sbin/ldconfig
136 %postun libs -p /sbin/ldconfig
137
138 %files
139 %defattr(644,root,root,755)
140 %doc tools/README
141 %attr(755,root,root) /sbin/mount.ploop
142 %attr(755,root,root) /sbin/umount.ploop
143 %attr(755,root,root) %{_sbindir}/ploop
144 %attr(755,root,root) %{_sbindir}/ploop-balloon
145 %attr(755,root,root) %{_sbindir}/ploop-cbt
146 %attr(755,root,root) %{_sbindir}/ploop-volume
147 %dir %{_libexecdir}/ploop
148 %attr(755,root,root) %{_libexecdir}/ploop/crypthelper
149 /etc/modules-load.d/ploop.conf
150 %dir /var/lock/ploop
151 %{systemdtmpfilesdir}/ploop.conf
152 %{_mandir}/man8/ploop.8*
153
154 %files -n bash-completion-ploop
155 %defattr(644,root,root,755)
156 %{bash_compdir}/ploop
157
158 %files libs
159 %defattr(644,root,root,755)
160 %attr(755,root,root) %{_libdir}/libploop.so.*.*.*
161 %attr(755,root,root) %ghost %{_libdir}/libploop.so.8
162 %dir /var/lock/ploop
163
164 %files devel
165 %defattr(644,root,root,755)
166 %attr(755,root,root) %{_libdir}/libploop.so
167 %{_includedir}/ploop
168 %{_pkgconfigdir}/ploop.pc
169
170 %files static
171 %defattr(644,root,root,755)
172 %{_libdir}/libploop.a
173
174 %files -n python3-libploop
175 %defattr(644,root,root,755)
176 %dir %{py3_sitedir}/libploop
177 %attr(755,root,root) %{py3_sitedir}/libploop/libploopapi.cpython-*.so
178 %{py3_sitedir}/libploop/__init__.py
179 %{py3_sitedir}/libploop/__pycache__
180 %{py3_sitedir}/libploop-0.0.0-py*.egg-info
This page took 0.061996 seconds and 2 git commands to generate.