]>
Commit | Line | Data |
---|---|---|
e4ca15c7 JB |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without static_libs # static libraries | |
4 | # | |
5 | Summary: Manage "libnvdimm" subsystem devices (Non-volatile Memory) | |
6 | Summary(pl.UTF-8): Zarządzanie urządzeniami podsystemu "libnvdimm" (pamięci nieulotnej) | |
7 | Name: ndctl | |
d339277c JB |
8 | Version: 71.1 |
9 | Release: 1 | |
e4ca15c7 JB |
10 | License: LGPL v2.1+ (libraries), GPL v2+ with CC0 and MIT parts (utilities) |
11 | Group: Applications/System | |
12 | #Source0Download: https://github.com/pmem/ndctl/releases | |
13 | Source0: https://github.com/pmem/ndctl/archive/v%{version}/%{name}-%{version}.tar.gz | |
d339277c | 14 | # Source0-md5: 473b701d5250392ac570ed271cacd778 |
605b7fc7 | 15 | Patch0: %{name}-bashcompdir.patch |
d339277c | 16 | URL: https://pmem.io/ndctl/ |
605b7fc7 | 17 | # TODO: asciidoctor |
e4ca15c7 JB |
18 | BuildRequires: asciidoc |
19 | BuildRequires: autoconf >= 2.60 | |
20 | BuildRequires: automake >= 1:1.11 | |
f7b498ea | 21 | BuildRequires: glibc-devel >= 6:2.28 |
e4ca15c7 | 22 | BuildRequires: json-c-devel |
b56c2d3b | 23 | BuildRequires: keyutils-devel |
e4ca15c7 | 24 | BuildRequires: kmod-devel |
e4ca15c7 | 25 | BuildRequires: libtool >= 2:2 |
d339277c | 26 | BuildRequires: libuuid-devel |
f7b498ea | 27 | BuildRequires: linux-libc-headers >= 7:4.15 |
e4ca15c7 JB |
28 | BuildRequires: pkgconfig |
29 | BuildRequires: rpmbuild(macros) >= 1.673 | |
b56c2d3b | 30 | BuildRequires: systemd-devel |
e4ca15c7 JB |
31 | BuildRequires: udev-devel |
32 | BuildRequires: xmlto | |
33 | Requires: %{name}-libs = %{version}-%{release} | |
34 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
35 | ||
36 | %description | |
37 | Utilities for managing the "libnvdimm" subsystem. The "libnvdimm" | |
38 | subsystem defines a kernel device model and control message interface | |
39 | for platform NVDIMM resources like those defined by the ACPI 6+ NFIT | |
40 | (NVDIMM Firmware Interface Table). | |
41 | ||
42 | %description -l pl.UTF-8 | |
43 | Narzędzia do zarządzania podsystemem "libnvdimm". Podsystem ten | |
44 | definiuje model urządzeń jądra i interfejs komunikatów sterujących dla | |
45 | specyficznych dla platformy zasobów NVDIMM, takich jak zdefiniowane w | |
46 | ACPI 6+ NFIT (NVDIMM Firmware Interface Table). | |
47 | ||
48 | %package -n bash-completion-ndctl | |
49 | Summary: Bash completion for ndctl command | |
50 | Summary(pl.UTF-8): Bashowe uzupełnianie parametrów polecenia ndctl | |
51 | Group: Applications/Shells | |
52 | Requires: %{name} = %{version}-%{release} | |
53 | Requires: bash-completion >= 2.0 | |
54 | ||
55 | %description -n bash-completion-ndctl | |
56 | Bash completion for ndctl command. | |
57 | ||
58 | %description -n bash-completion-ndctl -l pl.UTF-8 | |
59 | Bashowe uzupełnianie parametrów polecenia ndctl. | |
60 | ||
61 | %package libs | |
62 | Summary: Management library for "libnvdimm" subsystem devices (Non-volatile Memory) | |
63 | Summary(pl.UTF-8): Biblioteka zarządzająca do urządzeń podsystemu "libnvdimm" (pamięci nieulotnej) | |
64 | License: LGPL v2.1+ | |
65 | Group: Libraries | |
66 | Requires: daxctl-libs = %{version}-%{release} | |
67 | ||
68 | %description libs | |
69 | Management library for "libnvdimm" subsystem devices (Non-volatile | |
70 | Memory). | |
71 | ||
72 | %description libs -l pl.UTF-8 | |
73 | Biblioteka zarządzająca do urządzeń podsystemu "libnvdimm" | |
74 | (Non-volatile Memory - pamięci nieulotnej). | |
75 | ||
76 | %package devel | |
77 | Summary: Header files for ndctl library | |
78 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki ndctl | |
79 | License: LGPL v2.1+ | |
80 | Group: Development/Libraries | |
81 | Requires: %{name}-libs = %{version}-%{release} | |
82 | Requires: daxctl-devel = %{version}-%{release} | |
83 | ||
84 | %description devel | |
85 | Header files for ndctl library. | |
86 | ||
87 | %description devel -l pl.UTF-8 | |
88 | Pliki nagłówkowe biblioteki ndctl. | |
89 | ||
90 | %package static | |
91 | Summary: Static ndctl library | |
92 | Summary(pl.UTF-8): Statyczna biblioteka ndctl | |
93 | License: LGPL v2.1+ | |
94 | Group: Development/Libraries | |
95 | Requires: %{name}-devel = %{version}-%{release} | |
96 | ||
97 | %description static | |
98 | Static ndctl library. | |
99 | ||
100 | %description static -l pl.UTF-8 | |
101 | Statyczna biblioteka ndctl. | |
102 | ||
103 | %package -n daxctl | |
104 | Summary: Manage Device-DAX instances | |
105 | Summary(pl.UTF-8): Zarządzanie instancjami Device-DAX | |
106 | License: GPL v2+ with CC0 and MIT parts (utilities) | |
107 | Group: Applications/System | |
108 | Requires: daxctl-libs = %{version}-%{release} | |
109 | ||
110 | %description -n daxctl | |
111 | The daxctl utility provides enumeration and provisioning commands for | |
112 | the Linux kernel Device-DAX facility. This facility enables DAX | |
113 | mappings of performance/feature differentiated memory without need of | |
114 | a filesystem. | |
115 | ||
116 | %description -n daxctl -l pl.UTF-8 | |
117 | Narzędzie daxctl udostępnia polecenia do numerowania i zaopatrywania | |
118 | funkcji Device-DAX jądra Linuksa. Funkcja ta włącza odwzorowanie DAX | |
119 | pamięci o zróżnicowanej wydajności/funkcjonalności bez potrzeby | |
120 | systemu plików. | |
121 | ||
122 | %package -n daxctl-libs | |
123 | Summary: Management library for "Device DAX" devices | |
124 | Summary(pl.UTF-8): Biblioteka zarządzająca do urządzeń "Device DAX" | |
125 | License: LGPL v2.1+ | |
126 | Group: Libraries | |
127 | ||
128 | %description -n daxctl-libs | |
129 | Device DAX is a facility for establishing DAX mappings of | |
130 | performance/feature-differentiated memory. daxctl-libs provides an | |
131 | enumeration/control API for these devices. | |
132 | ||
133 | %description -n daxctl-libs -l pl.UTF-8 | |
134 | Device DAX to funkcja ustanawiająca odwzorowania DAX pamięci o | |
135 | zróżnicowanej wydajności/funkcjonalności. Biblioteka daxctl-libs | |
136 | dostarcza API do numerowania i kontroli tych urządzeń. | |
137 | ||
138 | %package -n daxctl-devel | |
139 | Summary: Header fiels for daxctl library | |
140 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki daxctl | |
141 | License: LGPL v2.1+ | |
142 | Group: Development/Libraries | |
143 | Requires: daxctl-libs = %{version}-%{release} | |
144 | Requires: libuuid-devel | |
145 | ||
146 | %description -n daxctl-devel | |
147 | Header fiels for daxctl library. | |
148 | ||
149 | %description -n daxctl-devel -l pl.UTF-8 | |
150 | Pliki nagłówkowe biblioteki daxctl. | |
151 | ||
152 | %package -n daxctl-static | |
153 | Summary: Static daxctl library | |
154 | Summary(pl.UTF-8): Statyczna biblioteka daxctl | |
155 | License: LGPL v2.1+ | |
156 | Group: Development/Libraries | |
157 | Requires: %{name}-devel = %{version}-%{release} | |
158 | ||
159 | %description -n daxctl-static | |
160 | Static daxctl library. | |
161 | ||
162 | %description -n daxctl-static -l pl.UTF-8 | |
163 | Statyczna biblioteka daxctl. | |
164 | ||
165 | %prep | |
166 | %setup -q | |
605b7fc7 | 167 | %patch0 -p1 |
e4ca15c7 JB |
168 | |
169 | echo '%{version}' >version | |
170 | ||
171 | %build | |
172 | ./git-version-gen | |
173 | %{__libtoolize} | |
174 | %{__aclocal} -I m4 | |
175 | %{__autoconf} | |
176 | %{__autoheader} | |
177 | %{__automake} | |
178 | %configure \ | |
605b7fc7 | 179 | --disable-asciidoctor \ |
e4ca15c7 JB |
180 | --disable-silent-rules \ |
181 | %{?with_static_libs:--enable-static} \ | |
605b7fc7 | 182 | --with-bash=%{bash_compdir} |
e4ca15c7 JB |
183 | %{__make} |
184 | ||
185 | %install | |
186 | rm -rf $RPM_BUILD_ROOT | |
187 | ||
188 | %{__make} install \ | |
189 | DESTDIR=$RPM_BUILD_ROOT | |
190 | ||
191 | # obsoleted by pkg-config | |
192 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/lib*.la | |
193 | ||
194 | %clean | |
195 | rm -rf $RPM_BUILD_ROOT | |
196 | ||
45d485e5 JB |
197 | %post libs -p /sbin/ldconfig |
198 | %postun libs -p /sbin/ldconfig | |
199 | ||
200 | %post -n daxctl-libs -p /sbin/ldconfig | |
201 | %postun -n daxctl-libs -p /sbin/ldconfig | |
e4ca15c7 JB |
202 | |
203 | %files | |
204 | %defattr(644,root,root,755) | |
e4ca15c7 | 205 | %attr(755,root,root) %{_bindir}/ndctl |
605b7fc7 JB |
206 | %dir %{_sysconfdir}/ndctl |
207 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/ndctl/monitor.conf | |
b56c2d3b JB |
208 | %dir %{_sysconfdir}/ndctl/keys |
209 | %config(noreplace) %verify(not md5 mtime size) /etc/modprobe.d/nvdimm-security.conf | |
605b7fc7 | 210 | %{systemdunitdir}/ndctl-monitor.service |
e4ca15c7 JB |
211 | %{_mandir}/man1/ndctl.1* |
212 | %{_mandir}/man1/ndctl-*.1* | |
213 | ||
214 | %files -n bash-completion-ndctl | |
215 | %defattr(644,root,root,755) | |
216 | %{bash_compdir}/ndctl | |
217 | ||
218 | %files libs | |
219 | %defattr(644,root,root,755) | |
220 | %attr(755,root,root) %{_libdir}/libndctl.so.*.*.* | |
221 | %attr(755,root,root) %ghost %{_libdir}/libndctl.so.6 | |
222 | ||
223 | %files devel | |
224 | %attr(755,root,root) %{_libdir}/libndctl.so | |
225 | %defattr(644,root,root,755) | |
226 | %{_includedir}/ndctl | |
227 | %{_pkgconfigdir}/libndctl.pc | |
228 | ||
229 | %if %{with static_libs} | |
230 | %files static | |
231 | %defattr(644,root,root,755) | |
232 | %{_libdir}/libndctl.a | |
233 | %endif | |
234 | ||
235 | %files -n daxctl | |
236 | %defattr(644,root,root,755) | |
e4ca15c7 | 237 | %attr(755,root,root) %{_bindir}/daxctl |
b56c2d3b | 238 | %{_datadir}/daxctl |
e4ca15c7 JB |
239 | %{_mandir}/man1/daxctl.1* |
240 | %{_mandir}/man1/daxctl-*.1* | |
241 | ||
242 | %files -n daxctl-libs | |
243 | %defattr(644,root,root,755) | |
d339277c | 244 | %doc README.md LICENSES/other/{CC0-1.0,MIT} |
e4ca15c7 JB |
245 | %attr(755,root,root) %{_libdir}/libdaxctl.so.*.*.* |
246 | %attr(755,root,root) %ghost %{_libdir}/libdaxctl.so.1 | |
247 | ||
248 | %files -n daxctl-devel | |
249 | %defattr(644,root,root,755) | |
250 | %attr(755,root,root) %{_libdir}/libdaxctl.so | |
251 | %{_includedir}/daxctl | |
252 | %{_pkgconfigdir}/libdaxctl.pc | |
253 | ||
254 | %if %{with static_libs} | |
255 | %files -n daxctl-static | |
256 | %defattr(644,root,root,755) | |
257 | %{_libdir}/libdaxctl.a | |
258 | %endif |