]>
Commit | Line | Data |
---|---|---|
632ee324 | 1 | Summary: Service Availability Forum's Hardware Platform Interface (HPI) implementation |
2a4655e0 | 2 | Summary(pl.UTF-8): Implementacja HPI (Hardware Platform Interface) Service Availability Forum |
ec5858d3 | 3 | Name: openhpi |
b1922010 | 4 | Version: 2.10.1 |
1b8447c3 | 5 | Release: 4 |
ec5858d3 AM |
6 | License: BSD |
7 | Group: Libraries | |
a4050f56 | 8 | Source0: http://dl.sourceforge.net/openhpi/%{name}-%{version}.tar.gz |
b1922010 | 9 | # Source0-md5: b8b771b310046bb14db8113fd1720431 |
5c81f3d1 | 10 | Patch0: %{name}-types.patch |
278c7ca6 JB |
11 | Patch1: %{name}-sh.patch |
12 | Patch2: %{name}-align.patch | |
1b30ae9e | 13 | Patch3: %{name}-proto.patch |
b1922010 JB |
14 | Patch4: %{name}-configure.patch |
15 | Patch5: %{name}-rtas.patch | |
16 | Patch6: %{name}-c++.patch | |
ec5858d3 | 17 | URL: http://openhpi.sourceforge.net/ |
ebe90188 | 18 | BuildRequires: OpenIPMI-devel >= 1.4.20 |
fa178c24 | 19 | BuildRequires: autoconf >= 2.57 |
ebe90188 | 20 | BuildRequires: automake >= 1:1.8 |
70911efe | 21 | BuildRequires: docbook-dtd41-sgml |
a4050f56 | 22 | BuildRequires: docbook-utils |
fa178c24 JB |
23 | BuildRequires: fam-devel |
24 | BuildRequires: gcc >= 5:3.2.0 | |
278c7ca6 | 25 | BuildRequires: glib2-devel >= 1:2.2.0 |
ec5858d3 | 26 | BuildRequires: libltdl-devel |
b1922010 JB |
27 | %ifarch ppc ppc64 |
28 | BuildRequires: librtas-devel | |
29 | %endif | |
a4050f56 | 30 | BuildRequires: libstdc++-devel |
632ee324 | 31 | BuildRequires: libtool |
ec5858d3 | 32 | BuildRequires: libuuid-devel |
a4050f56 | 33 | BuildRequires: net-snmp-devel |
278c7ca6 | 34 | BuildRequires: openssl-devel |
632ee324 | 35 | BuildRequires: pkgconfig |
ebe90188 | 36 | BuildRequires: sysfsutils-devel >= 1.3.0-3 |
278c7ca6 | 37 | Requires: glib2 >= 1:2.2.0 |
ec5858d3 AM |
38 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
39 | ||
9f9ae340 JB |
40 | %define specflags -fno-strict-aliasing |
41 | ||
ec5858d3 AM |
42 | %description |
43 | OpenHPI is an open source project created with the intent of providing | |
632ee324 JB |
44 | an implementation of the Service Availability Forum's Hardware |
45 | Platform Interface (HPI). HPI provides a universal interface for | |
46 | creating resource system models, typically for chassis and rack based | |
47 | servers, but extendable for other problem domains such as clustering, | |
48 | virtualization and simulation. | |
49 | ||
7f481fde | 50 | %description -l pl.UTF-8 |
8912af1d | 51 | OpenHPI to otwarty projekt stworzony z zamiarem dostarczenia |
632ee324 | 52 | implementacji HPI (Hardware Platform Interface - interfejsu platformy |
7f481fde JR |
53 | sprzętowej) Service Availability Forum. HPI udostępnia uniwersalny |
54 | interfejs do tworzenia modeli systemów zasobów, zwykle dla serwerów | |
55 | w ramach i szafach, ale rozszerzalny dla innego rodzaju problemów, | |
632ee324 | 56 | takich jak klastrowanie, wirtualizacja czy symulacja. |
ec5858d3 AM |
57 | |
58 | %package devel | |
632ee324 | 59 | Summary: Development part of OpenHPI Toolkit library |
2a4655e0 | 60 | Summary(pl.UTF-8): Programistyczna część biblioteki OpenHPI |
ec5858d3 | 61 | Group: Development/Libraries |
fa178c24 | 62 | Requires: %{name} = %{version}-%{release} |
278c7ca6 | 63 | Requires: glib2-devel >= 1:2.2.0 |
a4050f56 | 64 | Requires: libltdl-devel |
b1922010 JB |
65 | # for libosahpi |
66 | Requires: libstdc++-devel | |
67 | Requires: libuuid-devel | |
ec5858d3 AM |
68 | |
69 | %description devel | |
70 | Development part of OpenHPI library. | |
71 | ||
7f481fde JR |
72 | %description devel -l pl.UTF-8 |
73 | Programistyczna część biblioteki OpenHPI. | |
632ee324 | 74 | |
ec5858d3 | 75 | %package static |
632ee324 | 76 | Summary: Static OpenHPI library |
2a4655e0 | 77 | Summary(pl.UTF-8): Statyczna biblioteka OpenHPI |
ec5858d3 | 78 | Group: Development/Libraries |
fa178c24 | 79 | Requires: %{name}-devel = %{version}-%{release} |
ec5858d3 AM |
80 | |
81 | %description static | |
82 | Static OpenHPI Toolkit libraries. | |
83 | ||
7f481fde | 84 | %description static -l pl.UTF-8 |
632ee324 JB |
85 | Statyczna biblioteka OpenHPI. |
86 | ||
a4050f56 JB |
87 | %package plugin-ipmi |
88 | Summary: ipmi plugin for OpenHPI | |
2a4655e0 | 89 | Summary(pl.UTF-8): Wtyczka ipmi dla OpenHPI |
a4050f56 | 90 | Group: Libraries |
fa178c24 | 91 | Requires: %{name} = %{version}-%{release} |
ebe90188 | 92 | Requires: OpenIPMI >= 1.4.20 |
a4050f56 JB |
93 | |
94 | %description plugin-ipmi | |
95 | ipmi plugin for OpenHPI. | |
96 | ||
7f481fde | 97 | %description plugin-ipmi -l pl.UTF-8 |
a4050f56 JB |
98 | Wtyczka ipmi dla OpenHPI. |
99 | ||
100 | %package plugin-ipmidirect | |
101 | Summary: ipmidirect plugin for OpenHPI | |
2a4655e0 | 102 | Summary(pl.UTF-8): Wtyczka ipmidirect dla OpenHPI |
a4050f56 | 103 | Group: Libraries |
fa178c24 | 104 | Requires: %{name} = %{version}-%{release} |
a4050f56 JB |
105 | |
106 | %description plugin-ipmidirect | |
107 | ipmidirect plugin for OpenHPI. | |
108 | ||
7f481fde | 109 | %description plugin-ipmidirect -l pl.UTF-8 |
a4050f56 JB |
110 | Wtyczka ipmidirect dla OpenHPI. |
111 | ||
b1922010 JB |
112 | %package plugin-rtas |
113 | Summary: RTAS plugin for OpenHPI | |
114 | Summary(pl.UTF-8): Wtyczka RTAS dla OpenHPI | |
a4050f56 | 115 | Group: Libraries |
fa178c24 | 116 | Requires: %{name} = %{version}-%{release} |
9e626baf | 117 | Requires: lsvpd |
a4050f56 | 118 | |
b1922010 JB |
119 | %description plugin-rtas |
120 | RTAS plugin for OpenHPI. | |
a4050f56 | 121 | |
b1922010 JB |
122 | %description plugin-rtas -l pl.UTF-8 |
123 | Wtyczka RTAS dla OpenHPI. | |
a4050f56 | 124 | |
fa178c24 JB |
125 | %package plugin-simulator |
126 | Summary: simulator plugin for OpenHPI | |
2a4655e0 | 127 | Summary(pl.UTF-8): Wtyczka simulator dla OpenHPI |
fa178c24 JB |
128 | Group: Libraries |
129 | Requires: %{name} = %{version}-%{release} | |
130 | ||
131 | %description plugin-simulator | |
132 | simulator plugin for OpenHPI. | |
133 | ||
7f481fde | 134 | %description plugin-simulator -l pl.UTF-8 |
fa178c24 JB |
135 | Wtyczka simulator dla OpenHPI. |
136 | ||
b1922010 JB |
137 | %package plugin-snmp |
138 | Summary: SNMP plugins for OpenHPI | |
139 | Summary(pl.UTF-8): Wtyczki SNMP dla OpenHPI | |
140 | Group: Libraries | |
141 | Requires: %{name} = %{version}-%{release} | |
142 | ||
143 | %description plugin-snmp | |
144 | SNMP plugins for OpenHPI: snmp_bc. | |
145 | ||
146 | %description plugin-snmp -l pl.UTF-8 | |
147 | Wtyczki SNMP dla OpenHPI: snmp_bc. | |
148 | ||
a4050f56 JB |
149 | %package plugin-sysfs |
150 | Summary: sysfs plugin for OpenHPI | |
2a4655e0 | 151 | Summary(pl.UTF-8): Wtyczka sysfs dla OpenHPI |
a4050f56 | 152 | Group: Libraries |
fa178c24 | 153 | Requires: %{name} = %{version}-%{release} |
a4050f56 JB |
154 | |
155 | %description plugin-sysfs | |
156 | sysfs plugin for OpenHPI. | |
157 | ||
7f481fde | 158 | %description plugin-sysfs -l pl.UTF-8 |
a4050f56 JB |
159 | Wtyczka sysfs dla OpenHPI. |
160 | ||
ec5858d3 AM |
161 | %prep |
162 | %setup -q | |
a4050f56 | 163 | %patch0 -p1 |
25db1b44 JB |
164 | %patch1 -p1 |
165 | %patch2 -p1 | |
1b582e3e | 166 | %patch3 -p1 |
9f9ae340 | 167 | %patch4 -p1 |
a4c3f6f2 | 168 | %patch5 -p1 |
b1922010 | 169 | %patch6 -p1 |
a4050f56 JB |
170 | |
171 | # speed up build, lower disk space usage | |
f56124d6 ER |
172 | for f in $(find -name Makefile.am | xargs grep -l 'AM_CFLAGS.* -g '); do |
173 | %{__sed} -i -e 's/^\(AM_CFLAGS.* \)-g /\1 /' $f | |
a4050f56 | 174 | done |
ec5858d3 | 175 | |
f56124d6 ER |
176 | %ifarch alpha sparc |
177 | # event.c: In function `process_hpi_event': | |
178 | # event.c:236: warning: cast increases required alignment of target type | |
179 | # event.c: In function `oh_process_events': | |
180 | # event.c:410: warning: cast increases required alignment of target type | |
181 | # make[1]: *** [event.lo] Error 1 | |
182 | # for this code: | |
183 | # sid = g_array_index(sessions, SaHpiSessionIdT, i); | |
184 | # where: | |
185 | # typedef SaHpiUint32T SaHpiSessionIdT; | |
186 | # and: | |
187 | # #define g_array_index(a,t,i) (((t*) (a)->data) [(i)]) | |
188 | %{__sed} -i -e 's/-Werror//' configure.ac | |
189 | %endif | |
190 | ||
ec5858d3 AM |
191 | %build |
192 | %{__libtoolize} | |
193 | %{__aclocal} | |
194 | %{__autoconf} | |
ade50cb2 | 195 | %{__autoheader} |
ec5858d3 AM |
196 | %{__automake} |
197 | %configure \ | |
b1922010 | 198 | --enable-cpp_wrappers \ |
278c7ca6 | 199 | --enable-daemon \ |
e2b4cbbf | 200 | --enable-dummy \ |
b1922010 JB |
201 | %ifarch ppc ppc64 |
202 | --enable-rtas \ | |
203 | %endif | |
278c7ca6 | 204 | --enable-simulator |
0f87b8dd | 205 | |
ec5858d3 AM |
206 | %{__make} |
207 | ||
a4050f56 JB |
208 | %{__make} -C docs/hld openhpi-manual/book1.html |
209 | ||
ec5858d3 AM |
210 | %install |
211 | rm -rf $RPM_BUILD_ROOT | |
212 | ||
213 | %{__make} install \ | |
214 | DESTDIR=$RPM_BUILD_ROOT | |
215 | ||
a4050f56 JB |
216 | # remove useless static plugins (but *.la are used by lt_dlopen) |
217 | rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}/*.a | |
218 | ||
ec5858d3 AM |
219 | %clean |
220 | rm -rf $RPM_BUILD_ROOT | |
221 | ||
222 | %post -p /sbin/ldconfig | |
223 | %postun -p /sbin/ldconfig | |
224 | ||
225 | %files | |
226 | %defattr(644,root,root,755) | |
278c7ca6 | 227 | %doc COPYING README docs/hld/openhpi-manual |
b1922010 | 228 | %attr(755,root,root) %{_bindir}/hpi* |
ebe90188 | 229 | %attr(755,root,root) %{_sbindir}/openhpid |
b1922010 JB |
230 | %attr(755,root,root) %{_libdir}/libohtcpconnx.so.*.*.* |
231 | %attr(755,root,root) %{_libdir}/libohudpconnx.so.*.*.* | |
232 | %attr(755,root,root) %{_libdir}/libopenhpi*.so.*.*.* | |
233 | %attr(755,root,root) %{_libdir}/libosahpi.so.*.*.* | |
234 | %attr(755,root,root) %ghost %{_libdir}/libohtcpconnx.so.2 | |
235 | %attr(755,root,root) %ghost %{_libdir}/libohudpconnx.so.2 | |
236 | %attr(755,root,root) %ghost %{_libdir}/libopenhpi*.so.2 | |
237 | %attr(755,root,root) %ghost %{_libdir}/libosahpi.so.2 | |
632ee324 | 238 | %dir %{_libdir}/%{name} |
a4050f56 JB |
239 | %attr(755,root,root) %{_libdir}/%{name}/libwatchdog.so* |
240 | %{_libdir}/%{name}/libwatchdog.la | |
241 | %dir %{_sysconfdir}/openhpi | |
278c7ca6 JB |
242 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/openhpi/openhpi.conf |
243 | #%attr(754,root,root) /etc/rc.d/init.d/openhpid | |
244 | %dir %{_localstatedir}/lib/%{name} | |
278c7ca6 | 245 | %{_mandir}/man7/openhpi.7* |
b1922010 | 246 | %{_mandir}/man8/openhpid.8* |
ec5858d3 AM |
247 | |
248 | %files devel | |
249 | %defattr(644,root,root,755) | |
b1922010 JB |
250 | %attr(755,root,root) %{_libdir}/libohtcpconnx.so |
251 | %attr(755,root,root) %{_libdir}/libohudpconnx.so | |
252 | %attr(755,root,root) %{_libdir}/libopenhpi*.so | |
253 | %attr(755,root,root) %{_libdir}/libosahpi.so | |
254 | %{_libdir}/libohtcpconnx.la | |
255 | %{_libdir}/libohudpconnx.la | |
256 | %{_libdir}/libopenhpi*.la | |
257 | %{_libdir}/libosahpi.la | |
258 | %dir %{_includedir}/openhpi | |
259 | %{_includedir}/openhpi/*.h | |
260 | %{_includedir}/openhpi/oSaHpi*.hpp | |
261 | %{_pkgconfigdir}/openhpi.pc | |
262 | %{_pkgconfigdir}/openhpiutils.pc | |
ec5858d3 AM |
263 | |
264 | %files static | |
265 | %defattr(644,root,root,755) | |
b1922010 JB |
266 | %{_libdir}/libohtcpconnx.a |
267 | %{_libdir}/libohudpconnx.a | |
268 | %{_libdir}/libopenhpi*.a | |
269 | %{_libdir}/libosahpi.a | |
a4050f56 | 270 | |
a4050f56 JB |
271 | %files plugin-ipmi |
272 | %defattr(644,root,root,755) | |
273 | %attr(755,root,root) %{_libdir}/%{name}/libipmi.so* | |
274 | %{_libdir}/%{name}/libipmi.la | |
a4050f56 JB |
275 | |
276 | %files plugin-ipmidirect | |
277 | %defattr(644,root,root,755) | |
278 | %attr(755,root,root) %{_libdir}/%{name}/libipmidirect.so* | |
279 | %{_libdir}/%{name}/libipmidirect.la | |
280 | ||
b1922010 JB |
281 | %ifarch ppc ppc64 |
282 | %files plugin-rtas | |
283 | %defattr(644,root,root,755) | |
284 | %attr(755,root,root) %{_libdir}/%{name}/librtas2hpi.so* | |
285 | %{_libdir}/%{name}/librtas2hpi.la | |
286 | %endif | |
287 | ||
fa178c24 JB |
288 | %files plugin-simulator |
289 | %defattr(644,root,root,755) | |
290 | %attr(755,root,root) %{_libdir}/%{name}/libsimulator.so* | |
291 | %{_libdir}/%{name}/libsimulator.la | |
292 | ||
a4050f56 JB |
293 | %files plugin-snmp |
294 | %defattr(644,root,root,755) | |
295 | %attr(755,root,root) %{_libdir}/%{name}/libsnmp_bc.so* | |
296 | %{_libdir}/%{name}/libsnmp_bc.la | |
a4050f56 JB |
297 | |
298 | %files plugin-sysfs | |
299 | %defattr(644,root,root,755) | |
300 | %attr(755,root,root) %{_libdir}/%{name}/libsysfs2hpi.so* | |
301 | %{_libdir}/%{name}/libsysfs2hpi.la |